From 21b09233076a75bed7cd31177a5f52af40f572f9 Mon Sep 17 00:00:00 2001 From: An-Cheng Huang Date: Fri, 1 Feb 2008 19:13:18 -0800 Subject: fix for bug 2528: collapse source/destination "address" and "network". --- .../service/nat/rule/node.tag/destination/address/node.def | 13 +++++++++++-- .../service/nat/rule/node.tag/destination/network/node.def | 3 --- .../service/nat/rule/node.tag/source/address/node.def | 13 +++++++++++-- .../service/nat/rule/node.tag/source/network/node.def | 3 --- 4 files changed, 22 insertions(+), 10 deletions(-) delete mode 100644 templates-cfg/service/nat/rule/node.tag/destination/network/node.def delete mode 100644 templates-cfg/service/nat/rule/node.tag/source/network/node.def (limited to 'templates-cfg/service') diff --git a/templates-cfg/service/nat/rule/node.tag/destination/address/node.def b/templates-cfg/service/nat/rule/node.tag/destination/address/node.def index 7244fda..48da82b 100644 --- a/templates-cfg/service/nat/rule/node.tag/destination/address/node.def +++ b/templates-cfg/service/nat/rule/node.tag/destination/address/node.def @@ -1,3 +1,12 @@ type: txt -help: Destination address -syntax:expression: exec "/opt/vyatta/sbin/vyatta-validate-type.pl ipv4_negate '$VAR(@)'" ; "invalid destination address \"$VAR(@)\"" +help: Destination address or subnet +syntax:expression: exec "/opt/vyatta/sbin/vyatta-validate-type.pl \ + -q ipv4_negate '$VAR(@)' \ + || /opt/vyatta/sbin/vyatta-validate-type.pl \ + -q ipv4net_negate '$VAR(@)'" \ + ; "invalid destination address \"$VAR(@)\"" +comp_help: Possible completions: + IP address to match + / Subnet to match + ! Match everything except the specified address + !/ Match everything except the specified subnet diff --git a/templates-cfg/service/nat/rule/node.tag/destination/network/node.def b/templates-cfg/service/nat/rule/node.tag/destination/network/node.def deleted file mode 100644 index 8a52eec..0000000 --- a/templates-cfg/service/nat/rule/node.tag/destination/network/node.def +++ /dev/null @@ -1,3 +0,0 @@ -type: txt -help: Destination network -syntax:expression: exec "/opt/vyatta/sbin/vyatta-validate-type.pl ipv4net_negate '$VAR(@)'" ; "invalid destination network \"$VAR(@)\"" diff --git a/templates-cfg/service/nat/rule/node.tag/source/address/node.def b/templates-cfg/service/nat/rule/node.tag/source/address/node.def index 6be2e29..a9dda73 100644 --- a/templates-cfg/service/nat/rule/node.tag/source/address/node.def +++ b/templates-cfg/service/nat/rule/node.tag/source/address/node.def @@ -1,3 +1,12 @@ type: txt -help: Source address -syntax:expression: exec "/opt/vyatta/sbin/vyatta-validate-type.pl ipv4_negate '$VAR(@)'" ; "invalid source address \"$VAR(@)\"" +help: Source address or subnet +syntax:expression: exec "/opt/vyatta/sbin/vyatta-validate-type.pl \ + -q ipv4_negate '$VAR(@)' \ + || /opt/vyatta/sbin/vyatta-validate-type.pl \ + -q ipv4net_negate '$VAR(@)'" \ + ; "invalid source address \"$VAR(@)\"" +comp_help: Possible completions: + IP address to match + / Subnet to match + ! Match everything except the specified address + !/ Match everything except the specified subnet diff --git a/templates-cfg/service/nat/rule/node.tag/source/network/node.def b/templates-cfg/service/nat/rule/node.tag/source/network/node.def deleted file mode 100644 index 2da1647..0000000 --- a/templates-cfg/service/nat/rule/node.tag/source/network/node.def +++ /dev/null @@ -1,3 +0,0 @@ -type: txt -help: Inside network -syntax:expression: exec "/opt/vyatta/sbin/vyatta-validate-type.pl ipv4net_negate '$VAR(@)'" ; "invalid source network \"$VAR(@)\"" -- cgit v1.2.3