Server IP : 195.201.23.43 / Your IP : 18.218.96.239 Web Server : Apache System : Linux webserver2.vercom.be 5.4.0-192-generic #212-Ubuntu SMP Fri Jul 5 09:47:39 UTC 2024 x86_64 User : kdecoratie ( 1041) PHP Version : 7.1.33-63+ubuntu20.04.1+deb.sury.org+1 Disable Function : pcntl_alarm,pcntl_fork,pcntl_waitpid,pcntl_wait,pcntl_wifexited,pcntl_wifstopped,pcntl_wifsignaled,pcntl_wifcontinued,pcntl_wexitstatus,pcntl_wtermsig,pcntl_wstopsig,pcntl_signal,pcntl_signal_get_handler,pcntl_signal_dispatch,pcntl_get_last_error,pcntl_strerror,pcntl_sigprocmask,pcntl_sigwaitinfo,pcntl_sigtimedwait,pcntl_exec,pcntl_getpriority,pcntl_setpriority,pcntl_async_signals, MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : ON Directory : /usr/share/webmin/firewall6/ |
Upload File : |
# firewall4-lib.pl # has to be included after firewall-lib from every cgi # ipv4 initialization if ($config{'save_file'}) { # Force use of a different save file, and webmin's functions $iptables_save_file = $config{'save_file'}; } else { if (-r "$module_root_directory/$gconfig{'os_type'}-lib.pl") { # Use the operating system's save file and functions do "$gconfig{'os_type'}-lib.pl"; } if (!$iptables_save_file) { # Use webmin's own save file $iptables_save_file = "$module_config_directory/iptables.save"; } } %access = &get_module_acl(); @known_tables = ( "filter", "mangle", "nat" ); @known_args = ('-p', '-m', '-s', '-d', '-i', '-o', '-f', '--dport', '--sport', '--tcp-flags', '--tcp-option', '--icmp-type', '--mac-source', '--limit', '--limit-burst', '--ports', '--uid-owner', '--gid-owner', '--pid-owner', '--sid-owner', '--state', '--ctstate', '--tos', '-j', '--to-ports', '--to-destination', '--to-source', '--reject-with', '--dports', '--sports', '--match-set', '--comment', '--physdev-is-bridged', '--physdev-is-in', '--physdev-is-out', '--physdev-in', '--physdev-out'); @ipvx_rtypes = ( "icmp-net-unreachable", "icmp-host-unreachable", "icmp-port-unreachable", "icmp-proto-unreachable", "icmp-net-prohibited", "icmp-host-prohibited", "echo-reply", "tcp-reset" ); $ipvx_todestpattern='^([0-9\.]+)(\-([0-9\.]+))?(:(\d+)(\-(\d+))?)?$'; # set IP Version &set_ipvx_version('ipv4'); # IP V4 only functions sub check_ipmask { foreach my $w (split(/[ \t\r\n,]+/, $_[0])) { my $ok = &to_ipaddress($w) || $w =~ /^([0-9\.]+)\/([0-9\.]+)$/ && &to_ipaddress("$1") && (&check_ipaddress("$2") || ($2 =~ /^\d+$/ && $2 <= 32)); return 0 if (!$ok); } return 1; } # check_ipvx_ipaddress(ipv4) # Validates an IPv4 address sub check_ipvx_ipaddress { return &check_ipaddress(@_); } 1;Private