diff options
author | Stig Thormodsrud <stig@uffda.(none)> | 2007-11-19 18:44:27 -0800 |
---|---|---|
committer | Stig Thormodsrud <stig@uffda.(none)> | 2007-11-19 18:44:27 -0800 |
commit | 8306b478bee23055c5b0c47991ca5f35225e885d (patch) | |
tree | aaa721162759c932f5a0ae59b7b86bfece94af53 /scripts | |
parent | 5318fb1b6189e564dd533ffc4857c8743b19deee (diff) | |
download | vyatta-cfg-quagga-8306b478bee23055c5b0c47991ca5f35225e885d.tar.gz vyatta-cfg-quagga-8306b478bee23055c5b0c47991ca5f35225e885d.zip |
Add syntax validation for as-path prepend.
Diffstat (limited to 'scripts')
-rwxr-xr-x | scripts/policy/vyatta-check-as-prepend.pl | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/scripts/policy/vyatta-check-as-prepend.pl b/scripts/policy/vyatta-check-as-prepend.pl new file mode 100755 index 00000000..0da3d8d6 --- /dev/null +++ b/scripts/policy/vyatta-check-as-prepend.pl @@ -0,0 +1,6 @@ +#!/usr/bin/perl +@as_list = split(' ',$ARGV[0]); +foreach $as (@as_list) { + if ($as =~ /[^\d\s]/ || $as < 1 || $as > 65535) { exit 1;} +} +exit 0; |