diff options
Diffstat (limited to 'etc')
-rw-r--r-- | etc/defaults/rc.conf | 2 | ||||
-rw-r--r-- | etc/network.subr | 11 | ||||
-rw-r--r-- | etc/rc.d/netoptions | 11 | ||||
-rw-r--r-- | etc/rc.d/network1 | 11 | ||||
-rw-r--r-- | etc/rc.d/network2 | 11 | ||||
-rw-r--r-- | etc/rc.d/network3 | 11 | ||||
-rw-r--r-- | etc/rc.d/routing | 11 | ||||
-rw-r--r-- | etc/rc.network | 11 |
8 files changed, 72 insertions, 7 deletions
diff --git a/etc/defaults/rc.conf b/etc/defaults/rc.conf index 5310643..f703c8e 100644 --- a/etc/defaults/rc.conf +++ b/etc/defaults/rc.conf @@ -86,6 +86,8 @@ tcp_drop_synfin="NO" # Set to YES to drop TCP packets with SYN+FIN icmp_drop_redirect="NO" # Set to YES to ignore ICMP REDIRECT packets icmp_log_redirect="NO" # Set to YES to log ICMP REDIRECT packets network_interfaces="auto" # List of network interfaces (or "auto"). +cloned_interfaces="" # List of cloned network interfaces to create. +#cloned_interfaces="gif0 gif1 gif2 gif3" # Pre-cloning GENERIC config. ifconfig_lo0="inet 127.0.0.1" # default loopback device configuration. #ifconfig_lo0_alias0="inet 127.0.0.254 netmask 0xffffffff" # Sample alias entry. #ifconfig_ed0_ipx="ipx 0x00010010" # Sample IPX address family entry. diff --git a/etc/network.subr b/etc/network.subr index 2bf0b58..b715539 100644 --- a/etc/network.subr +++ b/etc/network.subr @@ -127,6 +127,11 @@ network_pass1() { ;; esac + # Attempt to create cloned interfaces. + for ifn in ${cloned_interfaces}; do + ifconfig ${ifn} create + done + # Special options for sppp(4) interfaces go here. These need # to go _before_ the general ifconfig section, since in the case # of hardwired (no link1 flag) but required authentication, you @@ -151,6 +156,9 @@ network_pass1() { [Aa][Uu][Tt][Oo]) network_interfaces="`ifconfig -l`" ;; + *) + network_interfaces="${network_interfaces} ${cloned_interfaces}" + ;; esac dhcp_interfaces="" @@ -795,7 +803,8 @@ network_gif_setup() { continue ;; *) - ifconfig $i create tunnel ${peers} + ifconfig $i create >/dev/null 2>&1 + ifconfig $i tunnel ${peers} ;; esac done diff --git a/etc/rc.d/netoptions b/etc/rc.d/netoptions index 2bf0b58..b715539 100644 --- a/etc/rc.d/netoptions +++ b/etc/rc.d/netoptions @@ -127,6 +127,11 @@ network_pass1() { ;; esac + # Attempt to create cloned interfaces. + for ifn in ${cloned_interfaces}; do + ifconfig ${ifn} create + done + # Special options for sppp(4) interfaces go here. These need # to go _before_ the general ifconfig section, since in the case # of hardwired (no link1 flag) but required authentication, you @@ -151,6 +156,9 @@ network_pass1() { [Aa][Uu][Tt][Oo]) network_interfaces="`ifconfig -l`" ;; + *) + network_interfaces="${network_interfaces} ${cloned_interfaces}" + ;; esac dhcp_interfaces="" @@ -795,7 +803,8 @@ network_gif_setup() { continue ;; *) - ifconfig $i create tunnel ${peers} + ifconfig $i create >/dev/null 2>&1 + ifconfig $i tunnel ${peers} ;; esac done diff --git a/etc/rc.d/network1 b/etc/rc.d/network1 index 2bf0b58..b715539 100644 --- a/etc/rc.d/network1 +++ b/etc/rc.d/network1 @@ -127,6 +127,11 @@ network_pass1() { ;; esac + # Attempt to create cloned interfaces. + for ifn in ${cloned_interfaces}; do + ifconfig ${ifn} create + done + # Special options for sppp(4) interfaces go here. These need # to go _before_ the general ifconfig section, since in the case # of hardwired (no link1 flag) but required authentication, you @@ -151,6 +156,9 @@ network_pass1() { [Aa][Uu][Tt][Oo]) network_interfaces="`ifconfig -l`" ;; + *) + network_interfaces="${network_interfaces} ${cloned_interfaces}" + ;; esac dhcp_interfaces="" @@ -795,7 +803,8 @@ network_gif_setup() { continue ;; *) - ifconfig $i create tunnel ${peers} + ifconfig $i create >/dev/null 2>&1 + ifconfig $i tunnel ${peers} ;; esac done diff --git a/etc/rc.d/network2 b/etc/rc.d/network2 index 2bf0b58..b715539 100644 --- a/etc/rc.d/network2 +++ b/etc/rc.d/network2 @@ -127,6 +127,11 @@ network_pass1() { ;; esac + # Attempt to create cloned interfaces. + for ifn in ${cloned_interfaces}; do + ifconfig ${ifn} create + done + # Special options for sppp(4) interfaces go here. These need # to go _before_ the general ifconfig section, since in the case # of hardwired (no link1 flag) but required authentication, you @@ -151,6 +156,9 @@ network_pass1() { [Aa][Uu][Tt][Oo]) network_interfaces="`ifconfig -l`" ;; + *) + network_interfaces="${network_interfaces} ${cloned_interfaces}" + ;; esac dhcp_interfaces="" @@ -795,7 +803,8 @@ network_gif_setup() { continue ;; *) - ifconfig $i create tunnel ${peers} + ifconfig $i create >/dev/null 2>&1 + ifconfig $i tunnel ${peers} ;; esac done diff --git a/etc/rc.d/network3 b/etc/rc.d/network3 index 2bf0b58..b715539 100644 --- a/etc/rc.d/network3 +++ b/etc/rc.d/network3 @@ -127,6 +127,11 @@ network_pass1() { ;; esac + # Attempt to create cloned interfaces. + for ifn in ${cloned_interfaces}; do + ifconfig ${ifn} create + done + # Special options for sppp(4) interfaces go here. These need # to go _before_ the general ifconfig section, since in the case # of hardwired (no link1 flag) but required authentication, you @@ -151,6 +156,9 @@ network_pass1() { [Aa][Uu][Tt][Oo]) network_interfaces="`ifconfig -l`" ;; + *) + network_interfaces="${network_interfaces} ${cloned_interfaces}" + ;; esac dhcp_interfaces="" @@ -795,7 +803,8 @@ network_gif_setup() { continue ;; *) - ifconfig $i create tunnel ${peers} + ifconfig $i create >/dev/null 2>&1 + ifconfig $i tunnel ${peers} ;; esac done diff --git a/etc/rc.d/routing b/etc/rc.d/routing index 2bf0b58..b715539 100644 --- a/etc/rc.d/routing +++ b/etc/rc.d/routing @@ -127,6 +127,11 @@ network_pass1() { ;; esac + # Attempt to create cloned interfaces. + for ifn in ${cloned_interfaces}; do + ifconfig ${ifn} create + done + # Special options for sppp(4) interfaces go here. These need # to go _before_ the general ifconfig section, since in the case # of hardwired (no link1 flag) but required authentication, you @@ -151,6 +156,9 @@ network_pass1() { [Aa][Uu][Tt][Oo]) network_interfaces="`ifconfig -l`" ;; + *) + network_interfaces="${network_interfaces} ${cloned_interfaces}" + ;; esac dhcp_interfaces="" @@ -795,7 +803,8 @@ network_gif_setup() { continue ;; *) - ifconfig $i create tunnel ${peers} + ifconfig $i create >/dev/null 2>&1 + ifconfig $i tunnel ${peers} ;; esac done diff --git a/etc/rc.network b/etc/rc.network index 2bf0b58..b715539 100644 --- a/etc/rc.network +++ b/etc/rc.network @@ -127,6 +127,11 @@ network_pass1() { ;; esac + # Attempt to create cloned interfaces. + for ifn in ${cloned_interfaces}; do + ifconfig ${ifn} create + done + # Special options for sppp(4) interfaces go here. These need # to go _before_ the general ifconfig section, since in the case # of hardwired (no link1 flag) but required authentication, you @@ -151,6 +156,9 @@ network_pass1() { [Aa][Uu][Tt][Oo]) network_interfaces="`ifconfig -l`" ;; + *) + network_interfaces="${network_interfaces} ${cloned_interfaces}" + ;; esac dhcp_interfaces="" @@ -795,7 +803,8 @@ network_gif_setup() { continue ;; *) - ifconfig $i create tunnel ${peers} + ifconfig $i create >/dev/null 2>&1 + ifconfig $i tunnel ${peers} ;; esac done |