chiark / gitweb /
functions.m4, local.m4: Rename `forwards' to `via'.
authorMark Wooding <mdw@distorted.org.uk>
Sat, 26 Jan 2013 14:32:20 +0000 (14:32 +0000)
committerMark Wooding <mdw@distorted.org.uk>
Sat, 26 Jan 2013 14:32:20 +0000 (14:32 +0000)
In fact, it lists the networks to which this one might forward packets,
rather than the networks whose packets this one forwards.  Hopefully the
name change will reduce confusion.

functions.m4
local.m4

index ebc16613db51adcc5c172c4111b1f366fa0ed0fe..3cd570de2a1deb6a47a26df79accb32a8db229b5 100644 (file)
@@ -355,7 +355,7 @@ m4_divert(20)m4_dnl
 ###                    `defnetclass'.
 ### net_inet_NET       List of IPv4 address ranges in the network.
 ### net_inet6_NET      List of IPv6 address ranges in the network.
-### net_fwd_NET                List of other networks that this one forwards to.
+### net_via_NET                List of other networks that this one forwards via.
 ### net_hosts_NET      List of hosts known to be in the network.
 ### host_inet_HOST     IPv4 address of the named HOST.
 ### host_inet6_HOST    IPv6 address of the named HOST.
@@ -444,7 +444,7 @@ defnetclass () {
 
 ## defnet NET CLASS
 ##
-## Define a network.  Follow by calls to `addr', `forwards', etc. to define
+## Define a network.  Follow by calls to `addr', `via', etc. to define
 ## properties of the network.  Networks are processed in order, so if their
 ## addresses overlap then the more specific addresses should be defined
 ## earlier.
@@ -467,11 +467,11 @@ addr () {
   done
 }
 
-## forwards NET ...
+## via NET ...
 ##
 ## Declare that packets from this network are forwarded to the other NETs.
-forwards () {
-  eval "net_fwd_$net=\"$*\""
+via () {
+  eval "net_via_$net=\"$*\""
 }
 
 ## noxit NET ...
@@ -721,8 +721,8 @@ net_interfaces () {
     nextnets=""
     any=nil
     for net in $nets; do
-      eval fwd=\$net_fwd_$net
-      for n in $fwd; do
+      eval via=\$net_via_$net
+      for n in $via; do
        case $seen in *":$n:"*) continue ;; esac
        seen=$seen$n:
        eval noxit=\$net_noxit_$n
index ed99b0098c466044e88efc92668b57edd9f07ff9..44ce71c582186c2e97df5ec5314bc5d57571961f 100644 (file)
--- a/local.m4
+++ b/local.m4
@@ -127,21 +127,21 @@ m4_divert(26)m4_dnl
 ## House networks.
 defnet dmz trusted
        addr 62.49.204.144/28 2001:470:1f09:1b98::/64
-       forwards unsafe untrusted
+       via unsafe untrusted
 defnet unsafe trusted
        addr 172.29.199.0/25 2001:470:9740:1::/64
-       forwards househub
+       via househub
 defnet safe safe
        addr 172.29.199.192/27 2001:470:9740:4001::/64
-       forwards househub
+       via househub
 defnet untrusted untrusted
        addr 172.29.198.0/25 2001:470:9740:8001::/64
-       forwards househub
+       via househub
 
 defnet househub virtual
-       forwards housebdry dmz unsafe safe untrusted
+       via housebdry dmz unsafe safe untrusted
 defnet housebdry virtual
-       forwards househub hub
+       via househub hub
        noxit dmz
 
 ## House hosts.
@@ -190,18 +190,18 @@ defhost gibson
 ## Colocated networks.
 defnet jump trusted
        addr 212.13.198.64/28 2001:ba8:0:1d9::/64
-       forwards colohub
+       via colohub
 defnet colo trusted
        addr 172.29.199.176/28 2001:ba8:1d9:2::/64
-       forwards colohub
+       via colohub
 defnet colohub virtual
-       forwards colobdry jump colo iodine
+       via colobdry jump colo iodine
 defnet colobdry virtual
-       forwards colohub hub
+       via colohub hub
        noxit jump
 defnet iodine untrusted
        addr 172.29.198.128/28
-       forwards colohub
+       via colohub
 
 ## Colocated hosts.
 defhost fender
@@ -229,27 +229,27 @@ defhost jazz
 
 ## Other networks.
 defnet hub virtual
-       forwards housebdry colobdry
+       via housebdry colobdry
 defnet sgo noloop
        addr !172.29.198.0/23
        addr 10.0.0.0/8
        addr 172.16.0.0/12
        addr 192.168.0.0/16
-       forwards househub colohub
+       via househub colohub
 defnet vpn safe
        addr 172.29.199.128/27 2001:ba8:1d9:6000::/64
-       forwards househub colohub
+       via househub colohub
        host crybaby 1
        host terror 2
        host orange 3
 defnet anycast trusted
        addr 172.29.199.224/27 2001:ba8:1d9:0::/64
-       forwards dmz unsafe safe untrusted jump colo vpn
+       via dmz unsafe safe untrusted jump colo vpn
 defnet default untrusted
        addr 62.49.204.144/28 2001:470:1f09:1b98::/64
        addr 212.13.198.64/28 2001:ba8:0:1d9::/64
        addr 2001:ba8:1d9::/48 #temporary
-       forwards dmz unsafe untrusted jump colo
+       via dmz unsafe untrusted jump colo
 
 m4_divert(80)m4_dnl
 ###--------------------------------------------------------------------------