]> git.ipfire.org Git - people/pmueller/ipfire-2.x.git/blobdiff - config/cfgroot/general-functions.pl
Proxy Portrange beschraenkt Port darf nicht 444 222 81 oder 53 sein und muss zwischen...
[people/pmueller/ipfire-2.x.git] / config / cfgroot / general-functions.pl
index 4365de5ded603b1c77d9aaf6318d9fdc31586a02..78f925f7058c81b8f93220f49ebc2fad3ad47a1d 100644 (file)
@@ -203,6 +203,21 @@ sub validport
        return 0;
 }
 
+sub validproxyport
+{
+       $_ = $_[0];
+
+       if (!/^\d+$/) {
+               return 0; }
+       if (/^0./) {
+               return 0; }
+       if ($_ == 53 || $_ == 222 || $_ == 444 || $_ == 81 ) {
+               return 0; }
+       elsif ($_ >= 1 && $_ <= 65535) {
+               return 1; }
+       return 0;
+}
+
 sub validmac
 {
        my $checkmac = $_[0];