diff options
author | des <des@FreeBSD.org> | 1999-04-10 10:56:58 +0000 |
---|---|---|
committer | des <des@FreeBSD.org> | 1999-04-10 10:56:58 +0000 |
commit | 0a96c9181ded745c4371a9b88030dc943e4c0b2b (patch) | |
tree | dc58cbf0c7700843d1a64fd565b8b1cd440bf069 /etc | |
parent | 4ea2c51252058b5f9a0a3caaed88e110a970de9d (diff) | |
download | FreeBSD-src-0a96c9181ded745c4371a9b88030dc943e4c0b2b.zip FreeBSD-src-0a96c9181ded745c4371a9b88030dc943e4c0b2b.tar.gz |
Allow the user to specify a different firewall script than /etc/rc.firewall.
Diffstat (limited to 'etc')
-rw-r--r-- | etc/defaults/rc.conf | 3 | ||||
-rw-r--r-- | etc/network.subr | 9 | ||||
-rw-r--r-- | etc/rc.d/netoptions | 9 | ||||
-rw-r--r-- | etc/rc.d/network1 | 9 | ||||
-rw-r--r-- | etc/rc.d/network2 | 9 | ||||
-rw-r--r-- | etc/rc.d/network3 | 9 | ||||
-rw-r--r-- | etc/rc.d/routing | 9 | ||||
-rw-r--r-- | etc/rc.network | 9 |
8 files changed, 44 insertions, 22 deletions
diff --git a/etc/defaults/rc.conf b/etc/defaults/rc.conf index 32c33b7..285fa6a 100644 --- a/etc/defaults/rc.conf +++ b/etc/defaults/rc.conf @@ -9,7 +9,7 @@ # # All arguments must be in double or single quotes. # -# $Id: rc.conf,v 1.6 1999/03/28 20:36:03 imp Exp $ +# $Id: rc.conf,v 1.7 1999/04/02 07:15:44 grog Exp $ ############################################################## ### Important initial Boot-time options ##################### @@ -32,6 +32,7 @@ rc_conf_files="/etc/rc.conf /etc/rc.conf.local" hostname="myname.my.domain" # Set this! nisdomainname="NO" # Set to NIS domain if using NIS (or NO). firewall_enable="NO" # Set to YES to enable firewall functionality +firewall_script="/etc/rc.firewall" # Which script to run to set up the firewall firewall_type="UNKNOWN" # Firewall type (see /etc/rc.firewall) firewall_quiet="NO" # Set to YES to suppress rule display natd_program="/sbin/natd" # path to natd, if you want a different one. diff --git a/etc/network.subr b/etc/network.subr index e913c88..81cd4d2 100644 --- a/etc/network.subr +++ b/etc/network.subr @@ -1,6 +1,6 @@ #!/bin/sh - # -# $Id: rc.network,v 1.41 1999/03/24 10:28:49 brian Exp $ +# $Id: rc.network,v 1.42 1999/03/28 20:36:03 imp Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in @@ -100,8 +100,11 @@ network_pass1() { # Load the filters if required if [ $firewall_in_kernel = 1 ]; then - if [ -f /etc/rc.firewall -a X"$firewall_enable" = X"YES" ]; then - . /etc/rc.firewall + if [ -z "${firewall_script}" ] ; then + firewall_script="/etc/rc.firewall" + fi + if [ -f ${firewall_script} -a X"$firewall_enable" = X"YES" ]; then + . ${firewall_script} echo -n 'Firewall rules loaded, starting divert daemons: ' # Network Address Translation daemon diff --git a/etc/rc.d/netoptions b/etc/rc.d/netoptions index e913c88..81cd4d2 100644 --- a/etc/rc.d/netoptions +++ b/etc/rc.d/netoptions @@ -1,6 +1,6 @@ #!/bin/sh - # -# $Id: rc.network,v 1.41 1999/03/24 10:28:49 brian Exp $ +# $Id: rc.network,v 1.42 1999/03/28 20:36:03 imp Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in @@ -100,8 +100,11 @@ network_pass1() { # Load the filters if required if [ $firewall_in_kernel = 1 ]; then - if [ -f /etc/rc.firewall -a X"$firewall_enable" = X"YES" ]; then - . /etc/rc.firewall + if [ -z "${firewall_script}" ] ; then + firewall_script="/etc/rc.firewall" + fi + if [ -f ${firewall_script} -a X"$firewall_enable" = X"YES" ]; then + . ${firewall_script} echo -n 'Firewall rules loaded, starting divert daemons: ' # Network Address Translation daemon diff --git a/etc/rc.d/network1 b/etc/rc.d/network1 index e913c88..81cd4d2 100644 --- a/etc/rc.d/network1 +++ b/etc/rc.d/network1 @@ -1,6 +1,6 @@ #!/bin/sh - # -# $Id: rc.network,v 1.41 1999/03/24 10:28:49 brian Exp $ +# $Id: rc.network,v 1.42 1999/03/28 20:36:03 imp Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in @@ -100,8 +100,11 @@ network_pass1() { # Load the filters if required if [ $firewall_in_kernel = 1 ]; then - if [ -f /etc/rc.firewall -a X"$firewall_enable" = X"YES" ]; then - . /etc/rc.firewall + if [ -z "${firewall_script}" ] ; then + firewall_script="/etc/rc.firewall" + fi + if [ -f ${firewall_script} -a X"$firewall_enable" = X"YES" ]; then + . ${firewall_script} echo -n 'Firewall rules loaded, starting divert daemons: ' # Network Address Translation daemon diff --git a/etc/rc.d/network2 b/etc/rc.d/network2 index e913c88..81cd4d2 100644 --- a/etc/rc.d/network2 +++ b/etc/rc.d/network2 @@ -1,6 +1,6 @@ #!/bin/sh - # -# $Id: rc.network,v 1.41 1999/03/24 10:28:49 brian Exp $ +# $Id: rc.network,v 1.42 1999/03/28 20:36:03 imp Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in @@ -100,8 +100,11 @@ network_pass1() { # Load the filters if required if [ $firewall_in_kernel = 1 ]; then - if [ -f /etc/rc.firewall -a X"$firewall_enable" = X"YES" ]; then - . /etc/rc.firewall + if [ -z "${firewall_script}" ] ; then + firewall_script="/etc/rc.firewall" + fi + if [ -f ${firewall_script} -a X"$firewall_enable" = X"YES" ]; then + . ${firewall_script} echo -n 'Firewall rules loaded, starting divert daemons: ' # Network Address Translation daemon diff --git a/etc/rc.d/network3 b/etc/rc.d/network3 index e913c88..81cd4d2 100644 --- a/etc/rc.d/network3 +++ b/etc/rc.d/network3 @@ -1,6 +1,6 @@ #!/bin/sh - # -# $Id: rc.network,v 1.41 1999/03/24 10:28:49 brian Exp $ +# $Id: rc.network,v 1.42 1999/03/28 20:36:03 imp Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in @@ -100,8 +100,11 @@ network_pass1() { # Load the filters if required if [ $firewall_in_kernel = 1 ]; then - if [ -f /etc/rc.firewall -a X"$firewall_enable" = X"YES" ]; then - . /etc/rc.firewall + if [ -z "${firewall_script}" ] ; then + firewall_script="/etc/rc.firewall" + fi + if [ -f ${firewall_script} -a X"$firewall_enable" = X"YES" ]; then + . ${firewall_script} echo -n 'Firewall rules loaded, starting divert daemons: ' # Network Address Translation daemon diff --git a/etc/rc.d/routing b/etc/rc.d/routing index e913c88..81cd4d2 100644 --- a/etc/rc.d/routing +++ b/etc/rc.d/routing @@ -1,6 +1,6 @@ #!/bin/sh - # -# $Id: rc.network,v 1.41 1999/03/24 10:28:49 brian Exp $ +# $Id: rc.network,v 1.42 1999/03/28 20:36:03 imp Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in @@ -100,8 +100,11 @@ network_pass1() { # Load the filters if required if [ $firewall_in_kernel = 1 ]; then - if [ -f /etc/rc.firewall -a X"$firewall_enable" = X"YES" ]; then - . /etc/rc.firewall + if [ -z "${firewall_script}" ] ; then + firewall_script="/etc/rc.firewall" + fi + if [ -f ${firewall_script} -a X"$firewall_enable" = X"YES" ]; then + . ${firewall_script} echo -n 'Firewall rules loaded, starting divert daemons: ' # Network Address Translation daemon diff --git a/etc/rc.network b/etc/rc.network index e913c88..81cd4d2 100644 --- a/etc/rc.network +++ b/etc/rc.network @@ -1,6 +1,6 @@ #!/bin/sh - # -# $Id: rc.network,v 1.41 1999/03/24 10:28:49 brian Exp $ +# $Id: rc.network,v 1.42 1999/03/28 20:36:03 imp Exp $ # From: @(#)netstart 5.9 (Berkeley) 3/30/91 # Note that almost all the user-configurable behavior is no longer in @@ -100,8 +100,11 @@ network_pass1() { # Load the filters if required if [ $firewall_in_kernel = 1 ]; then - if [ -f /etc/rc.firewall -a X"$firewall_enable" = X"YES" ]; then - . /etc/rc.firewall + if [ -z "${firewall_script}" ] ; then + firewall_script="/etc/rc.firewall" + fi + if [ -f ${firewall_script} -a X"$firewall_enable" = X"YES" ]; then + . ${firewall_script} echo -n 'Firewall rules loaded, starting divert daemons: ' # Network Address Translation daemon |