[leaf-commits] src/bering-uclibc4/source/shorewall-shell accounting.file, NONE, 1.1 buildtool.cfg, NONE, 1.1 buildtool.mk, NONE, 1.1 common.cfg, NONE, 1.1 dynamiczones.file, NONE, 1.1 maclist.file, NONE, 1.1 providers.file, NONE, 1.1 proxyarp.file, NONE, 1.1 shorewall-config.diff, NONE, 1.1 shorewall-default, NONE, 1.1 shorewall-lrp.diff, NONE, 1.1 stripscript.pl, NONE, 1.1 tc.file, NONE, 1.1 tcrules.file, NONE, 1.1 tunnels.file, NONE, 1.1

KP Kirchd?rfer <[email protected]>
Newsgroups gmane.linux.leaf.cvs
Message-ID <[email protected]>
Update of /cvsroot/leaf/src/bering-uclibc4/source/shorewall-shell
In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv15075

Added Files:
	accounting.file buildtool.cfg buildtool.mk common.cfg 
	dynamiczones.file maclist.file providers.file proxyarp.file 
	shorewall-config.diff shorewall-default shorewall-lrp.diff 
	stripscript.pl tc.file tcrules.file tunnels.file 
Log Message:
shorewall 4.0.15
The shell-based version of shorewall - slowly phasing out of support by the shorewall developers


--- NEW FILE: tcrules.file ---
			<File>
				Filename    = usr/share/shorewall-shell/lib.tcrules
				Source      = usr/share/shorewall-shell/lib.tcrules
				Type        = binary
			</File>

			<File>
				Filename    = etc/shorewall/tcrules
				Source      = etc/shorewall/tcrules
				Permissions = 600
				Description = TCRules   FWMark Rules
				Type        = binary
				Type        = conf
			</File>
--- NEW FILE: stripscript.pl ---
#! /usr/bin/perl

$^I = ".orig";

my $copy = 0, $initial=1;

while (<>) {
    #
    # $copy counts the number of unmatched << __EOF__ blocks.
    #
    if ( $copy ) {
	print;
	
	if ( /__EOF__/ ) {
	    $copy--;
	}
	
	next;
    }
    elsif ( /<< __EOF__/ ) {
	$copy++;
	print;
	next;
    }
    #
    # Drop lines that begin with '#'
    #
    if ( /^\s*#/ ) { 
	 $initial || next;
     }
    else {
	 $initial = 0;
     }
    #
    # Retain this line
    #
    print;
}

--- NEW FILE: providers.file ---
			<File>
				Filename    = usr/share/shorewall-shell/lib.providers
				Source      = usr/share/shorewall-shell/lib.providers
				Type        = binary
			</File>

			<File>
				Filename    = etc/shorewall/providers
				Source      = etc/shorewall/providers
				Permissions = 600
				Description = Providers Additional routing table
				Type        = binary
				Type        = conf
			</File>

--- NEW FILE: shorewall-default ---
#
# Shoreline Firewall startup options
#
# Any flags that appear in this file will be passed to shorewall
# by init.d on startup.
#
# -f = fast
# -q = quiet
#
OPTIONS="-f"

# if your Shorewall configuration requires detection of the ip address of a ppp
# interface, you must list such interfaces in "wait_interface" to get Shorewall
# wait until the interface is configured. Otherwise the script will fail because
# it won't be able to detect the IP address.
#
# Example:
#    wait_interface="ppp0"
# or
#    wait_interface="ppp0 ppp1"
#
#wait_interface="ppp0"

--- NEW FILE: tunnels.file ---
			<File>
				Filename    = usr/share/shorewall-shell/lib.tunnels
				Source      = usr/share/shorewall-shell/lib.tunnels
				Type        = binary
			</File>

			<File>
				Filename    = etc/shorewall/tunnels
				Source      = etc/shorewall/tunnels
				Permissions = 600
				Description = Tunnels   Tunnel Definition (ipsec
				Type        = binary
				Type        = conf
			</File>
--- NEW FILE: maclist.file ---
			<File>
				Filename    = usr/share/shorewall-shell/lib.maclist
				Source      = usr/share/shorewall-shell/lib.maclist
				Type        = binary
			</File>

			<File>
				Filename    = etc/shorewall/maclist
				Source      = etc/shorewall/maclist
				Permissions = 600
				Description = Maclist   MAC Verification
				Type        = binary
				Type        = conf
			</File>   

--- NEW FILE: proxyarp.file ---
			<File>
				Filename    = usr/share/shorewall-shell/lib.proxyarp
				Source      = usr/share/shorewall-shell/lib.proxyarp
				Type        = binary
			</File>

			<File>
				Filename    = etc/shorewall/proxyarp
				Source      = etc/shorewall/proxyarp
				Permissions = 600
				Description = ProxyArp  Proxy ARP Configuration
				Type        = binary
				Type        = conf
			</File>

--- NEW FILE: dynamiczones.file ---
			<File>
				Filename    = usr/share/shorewall/lib.dynamiczones
				Source      = usr/share/shorewall/lib.dynamiczones
				Type        = binary
			</File>

--- NEW FILE: accounting.file ---
			<File>
				Filename    = usr/share/shorewall-shell/lib.accounting
				Source      = usr/share/shorewall-shell/lib.accounting
				Type        = binary
			</File>

			<File>
				Filename    = etc/shorewall/accounting
				Source      = etc/shorewall/accounting
				Permissions = 600
				Description = Account   Traffic Accounting Rules
				Type        = binary
				Type        = conf
			</File>    
--- NEW FILE: shorewall-lrp.diff ---
diff -urN shorewall-common-4.0.9.org/start shorewall-common-4.0.9/start
--- shorewall-common-4.0.9.org/start	2007-07-09 16:01:07.000000000 +0200
+++ shorewall-common-4.0.9/start	2008-03-17 13:08:30.000000000 +0100
@@ -10,4 +10,7 @@
 # information.
 #
 ###############################################################################
+for file in /etc/shorewall/start.d/* ; do
+    run_user_exit $file
+done
 #LAST LINE - ADD YOUR ENTRIES ABOVE THIS ONE - DO NOT REMOVE
diff -urN shorewall-common-4.0.9.org/stop shorewall-common-4.0.9/stop
--- shorewall-common-4.0.9.org/stop	2007-07-09 16:01:07.000000000 +0200
+++ shorewall-common-4.0.9/stop	2008-03-17 13:09:03.000000000 +0100
@@ -10,4 +10,7 @@
 # information.
 #
 ###############################################################################
+for file in /etc/shorewall/stop.d/* ; do
+    run_user_exit $file
+done
 #LAST LINE - ADD YOUR ENTRIES ABOVE THIS ONE - DO NOT REMOVE
diff -urN shorewall-common-4.0.9.org/shorewall.conf shorewall-common-4.0.9/shorewall.conf
--- shorewall-common-4.0.9.org/shorewall.conf	2008-01-21 16:51:59.000000000 +0100
+++ shorewall-common-4.0.9/shorewall.conf	2008-03-17 13:12:07.000000000 +0100
@@ -18,7 +18,7 @@
 #		       S T A R T U P   E N A B L E D
 ###############################################################################
 
-STARTUP_ENABLED=No
+STARTUP_ENABLED=Yes
 
 ###############################################################################
 #		              V E R B O S I T Y
@@ -31,13 +31,13 @@
 #      (setting this to 'perl' requires installation of Shorewall-perl)
 ###############################################################################
 
-SHOREWALL_COMPILER=
+SHOREWALL_COMPILER=shell
 
 ###############################################################################
 #			       L O G G I N G
 ###############################################################################
 
-LOGFILE=/var/log/messages
+LOGFILE=/var/log/shorewall.log
 
 LOGFORMAT="Shorewall:%s:%s:"
 
@@ -51,13 +51,13 @@
 
 BLACKLIST_LOGLEVEL=
 
-MACLIST_LOG_LEVEL=info
+MACLIST_LOG_LEVEL=ULOG
 
-TCP_FLAGS_LOG_LEVEL=info
+TCP_FLAGS_LOG_LEVEL=ULOG
 
-RFC1918_LOG_LEVEL=info
+RFC1918_LOG_LEVEL=ULOG
 
-SMURF_LOG_LEVEL=info
+SMURF_LOG_LEVEL=ULOG
 
 LOG_MARTIANS=No
 
@@ -71,7 +71,7 @@
 
 SHOREWALL_SHELL=/bin/sh
 
-SUBSYSLOCK=/var/lock/subsys/shorewall
+SUBSYSLOCK=/var/run/shorewall
 
 MODULESDIR=
 
@@ -136,7 +136,7 @@
 
 MODULE_SUFFIX=
 
-DISABLE_IPV6=Yes
+DISABLE_IPV6=No
 
 BRIDGING=No
 
diff -urN shorewall-common-4.0.15.orig/init.debian.sh shorewall-common-4.0.15/init.debian.sh
--- shorewall-common-4.0.15.orig/init.debian.sh	2008-09-23 01:41:22.000000000 +0200
+++ shorewall-common-4.0.15/init.debian.sh	2009-11-27 15:12:38.000000000 +0100
@@ -1,81 +1,29 @@
 #!/bin/sh
-### BEGIN INIT INFO
-# Provides:          shorewall
-# Required-Start:    $network
-# Required-Stop:     $network
-# Default-Start:     S
-# Default-Stop:      0 6
-# Short-Description: Configure the firewall at boot time
-# Description:       Configure the firewall according to the rules specified in
-#                    /etc/shorewall
-### END INIT INFO
-
-
-
+RCDLINKS="2,S19 3,S19 4,S19 5,S19 0,K91 6,K91"
 SRWL=/sbin/shorewall
-SRWL_OPTS="-tvv"
 WAIT_FOR_IFUP=/usr/share/shorewall/wait4ifup
-# Note, set INITLOG to /dev/null if you do not want to
-# keep logs of the firewall (not recommended)
-INITLOG=/var/log/shorewall-init.log
-
-test -x $SRWL || exit 0
-test -x $WAIT_FOR_IFUP || exit 0
-test -n $INITLOG || {
-	echo "INITLOG cannot be empty, please configure $0" ; 
-	exit 1;
-}
-
-if [ "$(id -u)" != "0" ]
-then
-  echo "You must be root to start, stop or restart \"Shorewall firewall\"."
-  exit 1
-fi
-
-echo_notdone () {
-
-  if [ "$INITLOG" = "/dev/null" ] ; then 
-	  echo "not done."
-  else 
-	  echo "not done (check $INITLOG)."
-  fi
 
-}
-
-not_configured () {
-	echo "#### WARNING ####"
-	echo "The firewall won't be started/stopped unless it is configured"
-	if [ "$1" != "stop" ]
-	then
-		echo ""
-		echo "Please read about Debian specific customization in"
-		echo "/usr/share/doc/shorewall-common/README.Debian.gz."
-	fi
-	echo "#################"
-	exit 0
-}
-
-# check if shorewall is configured or not
+# parse the shorewall params file in order to use params in
+# /etc/default/shorewall
 if [ -f "/etc/default/shorewall" ]
 then
 	. /etc/default/shorewall
-	SRWL_OPTS="$SRWL_OPTS $OPTIONS"
-	if [ "$startup" != "1" ]
-	then
-		not_configured
-	fi
-else
-	not_configured
 fi
 
-# wait for an unconfigured interface 
+# wait an unconfigured interface
 wait_for_pppd () {
 	if [ "$wait_interface" != "" ]
 	then
+	    if [ -f $WAIT_FOR_IFUP ]
+	    then
 		for i in $wait_interface
 		do
 			$WAIT_FOR_IFUP $i 90
 		done
+	    else
+		echo "$WAIT_FOR_IFUP: File not found"
+		exit 2
+	    fi
 	fi
 }
 
@@ -83,28 +31,28 @@
 shorewall_start () {
   echo -n "Starting \"Shorewall firewall\": "
   wait_for_pppd
-  $SRWL $SRWL_OPTS start >> $INITLOG 2>&1 && echo "done." || echo_notdone
+  $SRWL $OPTIONS start 2>&1 && echo "done."
   return 0
 }
 
 # stop the firewall
 shorewall_stop () {
   echo -n "Stopping \"Shorewall firewall\": "
-  $SRWL $SRWL_OPTS clear >> $INITLOG 2>&1 && echo "done." || echo_notdone
+  $SRWL stop 2>&1 && echo "done."
   return 0
 }
 
 # restart the firewall
 shorewall_restart () {
   echo -n "Restarting \"Shorewall firewall\": "
-  $SRWL $SRWL_OPTS restart >> $INITLOG 2>&1 && echo "done." || echo_notdone
+  $SRWL $OPTIONS restart 2>&1 && echo "done."
   return 0
 }
 
 # refresh the firewall
 shorewall_refresh () {
   echo -n "Refreshing \"Shorewall firewall\": "
-  $SRWL $SRWL_OPTS refresh >> $INITLOG 2>&1 && echo "done." || echo_notdone
+  $SRWL refresh 2>&1 && echo "done."
   return 0
 }
 

--- NEW FILE: shorewall-config.diff ---
diff -urN shorewall-common-4.0.9.org/interfaces shorewall-common-4.0.9/interfaces
--- shorewall-common-4.0.9.org/interfaces	2007-08-30 17:40:17.000000000 +0200
+++ shorewall-common-4.0.9/interfaces	2008-03-17 15:34:22.000000000 +0100
@@ -8,4 +8,6 @@
 #
 ###############################################################################
 #ZONE	INTERFACE	BROADCAST	OPTIONS
+net    eth0            detect          dhcp,routefilter,norfc1918
+loc    eth1            detect          dhcp
 #LAST LINE -- ADD YOUR ENTRIES BEFORE THIS ONE -- DO NOT REMOVE
diff -urN shorewall-common-4.0.9.org/policy shorewall-common-4.0.9/policy
--- shorewall-common-4.0.9.org/policy	2007-08-30 17:40:17.000000000 +0200
+++ shorewall-common-4.0.9/policy	2008-03-17 15:35:12.000000000 +0100
@@ -9,4 +9,13 @@
 ###############################################################################
 #SOURCE		DEST		POLICY		LOG		LIMIT:BURST
 #						LEVEL
+loc            net             ACCEPT
+net            all             DROP            ULOG
+# If you want open access to the Internet from your Firewall
+# remove the comment from the following line.
+#fw             net             ACCEPT
+#
+# THE FOLLOWING POLICY MUST BE LAST
+#
+all           
 #LAST LINE -- DO NOT REMOVE
diff -urN shorewall-common-4.0.9.org/zones shorewall-common-4.0.9/zones
--- shorewall-common-4.0.9.org/zones	2007-08-30 17:40:17.000000000 +0200
+++ shorewall-common-4.0.9/zones	2008-03-17 15:35:46.000000000 +0100
@@ -10,4 +10,7 @@
 #ZONE	TYPE		OPTIONS		IN			OUT
 #					OPTIONS			OPTIONS
 fw	firewall
+net    ipv4
+loc    ipv4
+#dmz   ipv4
 #LAST LINE - ADD YOUR ENTRIES ABOVE THIS ONE - DO NOT REMOVE
diff -urN shorewall-common-4.0.9.org/rules shorewall-common-4.0.9/rules
--- shorewall-common-4.0.9.org/rules	2007-08-30 17:40:17.000000000 +0200
+++ shorewall-common-4.0.9/rules	2008-03-17 15:36:53.000000000 +0100
@@ -12,4 +12,28 @@
 #SECTION ESTABLISHED
 #SECTION RELATED
 SECTION NEW
+#      Accept DNS connections from the firewall to the network
+#      and from the local network to the firewall (in case dnsmasq is running)
+DNS/ACCEPT   fw          net
+DNS/ACCEPT   loc         fw
+
+#      Accept SSH connections from the local network for administration
+#
+SSH/ACCEPT   loc         fw
+
+#      Allow Ping to Firewall
+#
+Ping/ACCEPT  net         fw
+Ping/ACCEPT  loc         fw
+#
+#      Allow all ICMP types (including ping) from firewall
+ACCEPT    fw           loc                     icmp
+ACCEPT    fw           net                     icmp
+#      Allow local network to access weblet/webconf
+#
+Web/ACCEPT   loc        fw
+# timeserver (allow syncing with time servers (default: pool.ntp.org))
+NTP/ACCEPT         fw       net
+# timeserver (allow LAN clients to sync with the time service on the router)
+# NTP/ACCEPT         loc    fw
 #LAST LINE -- ADD YOUR ENTRIES BEFORE THIS ONE -- DO NOT REMOVE
diff -urN shorewall-common-4.0.9.org/masq shorewall-common-4.0.9/masq
--- shorewall-common-4.0.9.org/masq	2007-08-30 17:40:17.000000000 +0200
+++ shorewall-common-4.0.9/masq	2008-03-17 15:37:10.000000000 +0100
@@ -8,4 +8,5 @@
 #
 ###############################################################################
 #INTERFACE		SOURCE		ADDRESS		PROTO	PORT(S)	IPSEC	MARK
+eth0                     eth1
 #LAST LINE -- ADD YOUR ENTRIES ABOVE THIS LINE -- DO NOT REMOVE

--- NEW FILE: common.cfg ---
			<File>
				Filename    = etc/init.d/shorewall
				Source	    = etc/init.d/shorewall
				Permissions = 755
				Type	    = binary
			</File>
			<File>
				Filename    = sbin/shorewall
				Source	    = sbin/shorewall
				Permissions = 755
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall/
				Type	    = local
			</File>
			<File>
				Filename    = usr/share/shorewall/
				Source	    = usr/share/shorewall/macro*
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall/firewall
				Source	    = usr/share/shorewall/firewall
				Permissions = 755
				Type	    = binary
			</File>

			<File>
				Filename    = usr/share/shorewall/wait4ifup
				Source	    = usr/share/shorewall/wait4ifup
				Permissions = 755
				Type	    = binary
			</File>

			<File>
				Filename    = usr/share/shorewall/version
				Source	    = usr/share/shorewall/version
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall/rfc1918
				Source	    = usr/share/shorewall/rfc1918
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall-shell/prog.footer
				Source	    = usr/share/shorewall-shell/prog.footer
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall-shell/prog.header
				Source	    = usr/share/shorewall-shell/prog.header
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall/modules
				Source	    = usr/share/shorewall/modules
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall/version
				Source	    = usr/share/shorewall/version
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall-shell/version
				Source	    = usr/share/shorewall-shell/version
				Type	    = binary
			</File>

			<File>
				Filename    = usr/share/shorewall-shell/lib.nat
				Source	    = usr/share/shorewall-shell/lib.nat
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall/lib.config
				Source	    = usr/share/shorewall/lib.config
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall/lib.cli
				Source	    = usr/share/shorewall/lib.cli
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall/lib.base
				Source	    = usr/share/shorewall/lib.base
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall-shell/lib.actions
				Source	    = usr/share/shorewall-shell/lib.actions
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall/configpath
				Source	    = usr/share/shorewall/configpath
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall/functions
				Source	    = usr/share/shorewall/functions
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall-shell/compiler
				Source	    = usr/share/shorewall-shell/compiler
				Permissions  = 755 
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall/actions.std
				Source	    = usr/share/shorewall/actions.std
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall/action.Drop
				Source	    = usr/share/shorewall/action.Drop
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall/action.Reject
				Source	    = usr/share/shorewall/action.Reject
				Type	    = binary
			</File>
			<File>
				Filename    = usr/share/shorewall/action.template
				Source	    = usr/share/shorewall/action.template
				Type	    = binary
			</File>

			<File>
				Filename    = var/lib/shorewall/
				Type	    = directory
			</File>
			<File>
				Filename    = etc/default/shorewall
				Source	    = etc/default/shorewall
				Description = Default	Shorewall Runtime Startup options
				Type	    = binary
				Type	    = conf
				Type        = local
			</File>
			<File>
				Filename    = etc/shorewall/
				Type	    = local
			</File>
			<File>
				Filename    = etc/shorewall/start.d
				Type	    = directory
			</File>
			<File>
				Filename    = etc/shorewall/stop.d
				Type	    = directory
			</File>
			<File>
				Filename    = etc/shorewall/params
				Source	    = etc/shorewall/params
				Permissions = 600
				Description = Params    Assign parameter values
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/zones
				Source	    = etc/shorewall/zones
				Description = Zones     Partition the network into Zones
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/interfaces
				Source	    = etc/shorewall/interfaces
				Permissions = 600
				Description = Ifaces    Shorewall Networking Interfaces
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/hosts
				Source	    = etc/shorewall/hosts
				Permissions = 600
				Description = Hosts     Define specific zones
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/policy
				Source	    = etc/shorewall/policy
				Permissions = 600
				Description = Policy    Firewall high-level policy
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/rules
				Source	    = etc/shorewall/rules
				Permissions = 600
				Description = Rules     Exceptions to policy
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/masq
				Source	    = etc/shorewall/masq
				Permissions = 600
				Description = Masq      Internal MASQ Server Configuration
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/routestopped
				Source	    = etc/shorewall/routestopped
				Permissions = 600
				Description = RStopped  Hosts admitted after 'shorewall stop'
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/nat
				Source	    = etc/shorewall/nat
				Permissions = 600
				Description = Nat       Static NAT Configuration
				Type	    = binary
				Type	    = conf
			</File>
		
			<File>
				Filename    = etc/shorewall/shorewall.conf
				Source	    = etc/shorewall/shorewall.conf
				Permissions = 600
				Description = Config    Shorewall Global Parameters
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = usr/share/shorewall/modules
				Source	    = usr/share/shorewall/modules
				Permissions = 600
				Description = Modules   Netfilter modules to load
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/tos
				Source	    = etc/shorewall/tos
				Permissions = 600
				Description = TOS       Type of Service policy
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/blacklist
				Source	    = etc/shorewall/blacklist
				Permissions = 600
				Description = Blacklist Blacklisted hosts
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/ecn
				Source	    = etc/shorewall/ecn
				Permissions = 600
				Description = ECN       Disable ECN to hosts and networks
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/init
				Source	    = etc/shorewall/init
				Permissions = 600
				Description = Init      Commands executed before [re]start
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/initdone
				Source	    = etc/shorewall/initdone
				Permissions = 600
				Description = Initdone     Commands executed during [re]start
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/start
				Source	    = etc/shorewall/start
				Permissions = 600
				Description = Start     Commands executed after [re]start
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/started
				Source	    = etc/shorewall/started
				Permissions = 600
				Description = Started     Commands executed after complete [re]start
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/stop
				Source	    = etc/shorewall/stop
				Permissions = 600
				Description = Stop      Commands executed before stop
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/stopped
				Source	    = etc/shorewall/stopped
				Permissions = 600
				Description = Stopped   Commands executed after stop
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/actions
				Source	    = etc/shorewall/actions
				Permissions = 600
				Description = Actions   Define user actions
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/continue
				Source	    = etc/shorewall/continue
				Permissions = 600
				Description = Continue  Commands executed early in [re]start
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/netmap
				Source	    = etc/shorewall/netmap
				Permissions = 600
				Description = Netmap    Network Mapping Table
				Type	    = binary
				Type	    = conf
			</File>
			<File>
				Filename    = etc/shorewall/route_rules
				Source	    = etc/shorewall/route_rules
				Permissions = 600
				Description = Route_rules Routing to providers
				Type	    = binary
				Type	    = conf
			</File>
			
--- NEW FILE: tc.file ---
			<File>
				Filename    = usr/share/shorewall-shell/lib.tc
				Source      = usr/share/shorewall-shell/lib.tc
				Type        = binary
			</File>

			<File>
				Filename    = etc/shorewall/tcclasses
				Source      = etc/shorewall/tcclasses
				Permissions = 600
				Description = TCClasses
				Type        = binary
				Type        = conf
			</File>

			<File>
				Filename    = etc/shorewall/tcdevices
				Source      = etc/shorewall/tcdevices
				Permissions = 600
				Description = TCDevices
				Type        = binary
				Type        = conf
			</File>

--- NEW FILE: buildtool.mk ---
######################################
#
# buildtool makefile for Shoreline Firewall
#
######################################

include $(MASTERMAKEFILE)

TARGET_DIR=$(BT_BUILD_DIR)/shorewall

SHOREWALL_C_DIR:=shorewall-common-4.0.15
SHOREWALL_SH_DIR:=shorewall-shell-4.0.15

$(SHOREWALL_C_DIR)/.source:
	zcat $(SHOREWALL_COMMON_SOURCE) | tar -xvf -
	zcat $(SHOREWALL_SHELL_SOURCE) | tar -xvf -
	cat $(SHOREWALL_LRP_DIFF)	| patch -d $(SHOREWALL_C_DIR) -p1
	cat $(SHOREWALL_CONFIG_DIFF)	| patch -d $(SHOREWALL_C_DIR) -p1
	touch $(SHOREWALL_C_DIR)/.source

$(SHOREWALL_C_DIR)/.build: $(SHOREWALL_C_DIR)/.source
	chmod 755 ./stripscript.pl
#errata
#	cp compiler $(SHOREWALL_DIR)	

	./stripscript.pl $(SHOREWALL_C_DIR)/firewall
	./stripscript.pl $(SHOREWALL_C_DIR)/shorewall
	./stripscript.pl $(SHOREWALL_C_DIR)/lib.*
	./stripscript.pl $(SHOREWALL_SH_DIR)/compiler
	./stripscript.pl $(SHOREWALL_SH_DIR)/lib.*


	cp $(SHOREWALL_C_DIR)/init.debian.sh $(SHOREWALL_C_DIR)/init.sh
	mkdir -p $(TARGET_DIR)
	(cd $(SHOREWALL_C_DIR); env PREFIX=$(TARGET_DIR) ./install.sh)
	(cd $(SHOREWALL_SH_DIR); env PREFIX=$(TARGET_DIR) ./install.sh)
	
	chmod 755 $(TARGET_DIR)/usr/share/shorewall/firewall
	mkdir -p $(TARGET_DIR)/etc/default
	install -c $(SHOREWALL_DEFAULT) $(TARGET_DIR)/etc/default/shorewall

	rm -rf $(TARGET_DIR)/usr/share/shorewall/configfiles
	rm -rf $(TARGET_DIR)/usr/share/shorewall/macro.template
	rm -rf $(TARGET_DIR)/etc/shorewall/Makefile
	rm -rf $(TARGET_DIR)/etc/shorewall/Documentation
	rm -rf $(TARGET_DIR)/usr/share/shorewall/xmodules
	touch $(SHOREWALL_C_DIR)/.build

source: $(SHOREWALL_C_DIR)/.source

build:	$(SHOREWALL_C_DIR)/.build
	cp -afv $(TARGET_DIR)/* $(BT_STAGING_DIR)
#	cp -afv $(TARGET_DIR)-shell/* $(BT_STAGING_DIR)

clean:	stageclean
	rm -rf $(TARGET_DIR)
	rm -f  $(SHOREWALL_C_DIR)/.build

stageclean:
	rm -f  $(BT_STAGING_DIR)/etc/init.d/shorewall
	rm -f  $(BT_STAGING_DIR)/etc/default/shorewall
	rm -f  $(BT_STAGING_DIR)/sbin/shorewall
	rm -rf $(BT_STAGING_DIR)/etc/shorewall
	rm -rf $(BT_STAGING_DIR)/usr/share/shorewall
	rm -rf $(BT_STAGING_DIR)/var/lib/shorewall
	rm -rf $(BT_STAGING_DIR)/var/state/shorewall

srcclean: clean
	rm -rf $(SHOREWALL_C_DIR)
	rm -rf $(SHOREWALL_SH_DIR)

--- NEW FILE: buildtool.cfg ---
<Server shorewall-net>
	Type = http
	Name = www.shorewall.net
	Serverpath = /pub/shorewall
</Server>

<File shorewall-common-4.0.15.tgz>
	Server = shorewall-net
	Directory = 4.0/shorewall-4.0.15
	Envname = SHOREWALL_COMMON_SOURCE
</File>

<File shorewall-shell-4.0.15.tgz>
	Server = shorewall-net
	Directory = 4.0/shorewall-4.0.15
	Envname = SHOREWALL_SHELL_SOURCE
</File>

<File buildtool.mk>
	Server = cvs4-sourceforge
	Revision = HEAD
	Directory = shorewall
</File>

<File common.cfg>
	Server = cvs4-sourceforge
	Revision = HEAD
	Directory = shorewall
</File>

<File maclist.file>
	Server = cvs4-sourceforge
	Revision = HEAD
	Directory = shorewall

</File>

<File dynamiczones.file>
	Server = cvs4-sourceforge
	Revision = HEAD
	Directory = shorewall
</File>

<File accounting.file>
	Server = cvs4-sourceforge
	Revision = HEAD
	Directory = shorewall
</File>

<File providers.file>
	Server = cvs4-sourceforge
	Revision = HEAD
	Directory = shorewall
</File>

<File proxyarp.file>
	Server = cvs4-sourceforge
	Revision = HEAD
	Directory = shorewall
</File>

<File tunnels.file>
	Server = cvs4-sourceforge
	Revision = HEAD
	Directory = shorewall
</File>

<File tc.file>
	Server = cvs4-sourceforge
	Revision = HEAD
	Directory = shorewall
</File>

<File tcrules.file>
	Server = cvs4-sourceforge
	Revision = HEAD
	Directory = shorewall
</File>

 This patch provides generic changes to run under Bering uClibc
<File shorewall-lrp.diff>
	Server = cvs4-sourceforge
	Revision = HEAD
	Directory = shorewall
	Envname = SHOREWALL_LRP_DIFF
</File>

 This patch provides the Bering-uClibc specific configuration defaults
<File shorewall-config.diff>
	Server = cvs4-sourceforge
	Revision = HEAD
	Directory = shorewall
	Envname = SHOREWALL_CONFIG_DIFF
</File>

# This patch provides the Bering-uClibc specific configuration defaults
<File shorewall-default>
	Server = cvs4-sourceforge
	Revision = HEAD
	Directory = shorewall
	Envname = SHOREWALL_DEFAULT
</File>

<File stripscript.pl>
	Server = cvs4-sourceforge
	Revision = HEAD
	Directory = shorewall
</File>

# ---------------------------------------------------------------------
<Package>
	<shorwall-basic>
		packagename=shorwall
		Version 4.0.15
		Revision = 1

		Help <<EOF
		Shoreline Firewall (Shorewall)
		Homepage: http://www.shorewall.net
		Requires: iptables.lrp ulogd.lrp

		LEAF package by __PACKAGER__, __BUILDDATE__
		EOF

		<Permissions>
			Files = 644
			Directories = 755
		</Permissions>

		<Owner>
			Files = root:root
			Directories = root:root
		</Owner>

		<Contents>
		#include <common.cfg>
		</Contents>
	</shorwall-basic>
	<shorwall-maclist>
			Version 4.0.15
		Revision = 1

		Help <<EOF
		Shoreline Firewall (Shorewall)
		Homepage: http://www.shorewall.net
		Requires: shorwall.lrp iptables.lrp ulogd.lrp

		LEAF package by __PACKAGER__, __BUILDDATE__
		EOF

		<Permissions>
			Files = 644
			Directories = 755
		</Permissions>

		<Owner>
			Files = root:root
			Directories = root:root
		</Owner>
		<Contents>
		#include <maclist.file>
		</Contents>
	</shorwall-maclist>

	<shorwall-accounting>
			Version 4.0.15
		Revision = 1

		Help <<EOF
		Shoreline Firewall (Shorewall)
		Homepage: http://www.shorewall.net
		Requires: shorwall.lrp iptables.lrp ulogd.lrp

		LEAF package by __PACKAGER__, __BUILDDATE__
		EOF

		<Permissions>
			Files = 644
			Directories = 755
		</Permissions>

		<Owner>
			Files = root:root
			Directories = root:root
		</Owner>
		<Contents>
		#include <accounting.file>
		</Contents>
	</shorwall-accounting>

	<shorwall-providers>
			Version 4.0.15
		Revision = 1

		Help <<EOF
		Shoreline Firewall (Shorewall)
		Homepage: http://www.shorewall.net
		Requires: shorwall.lrp iptables.lrp ulogd.lrp

		LEAF package by __PACKAGER__, __BUILDDATE__
		EOF

		<Permissions>
			Files = 644
			Directories = 755
		</Permissions>

		<Owner>
			Files = root:root
			Directories = root:root
		</Owner>
		<Contents>
		#include <providers.file>
		</Contents>
	</shorwall-providers>
	<shorwall-dynamiczones>
			Version 4.0.15
		Revision = 1

		Help <<EOF
		Shoreline Firewall (Shorewall)
		Homepage: http://www.shorewall.net
		Requires: shorwall.lrp iptables.lrp ulogd.lrp

		LEAF package by __PACKAGER__, __BUILDDATE__
		EOF

		<Permissions>
			Files = 644
			Directories = 755
		</Permissions>

		<Owner>
			Files = root:root
			Directories = root:root
		</Owner>
		<Contents>
		 #include <dynamiczones.file>
		</Contents>
	</shorwall-dynamiczones>
	<shorwall-proxyarp>
			Version 4.0.15
		Revision = 1

		Help <<EOF
		Shoreline Firewall (Shorewall)
		Homepage: http://www.shorewall.net
		Requires: shorwall.lrp iptables.lrp ulogd.lrp

		LEAF package by __PACKAGER__, __BUILDDATE__
		EOF

		<Permissions>
			Files = 644
			Directories = 755
		</Permissions>

		<Owner>
			Files = root:root
			Directories = root:root
		</Owner>
		<Contents>
			#include <proxyarp.file>
		</Contents>
	</shorwall-proxyarp>
	<shorwall-tunnels>
			Version 4.0.15
		Revision = 1

		Help <<EOF
		Shoreline Firewall (Shorewall)
		Homepage: http://www.shorewall.net
		Requires: shorwall.lrp iptables.lrp ulogd.lrp

		LEAF package by __PACKAGER__, __BUILDDATE__
		EOF

		<Permissions>
			Files = 644
			Directories = 755
		</Permissions>

		<Owner>
			Files = root:root
			Directories = root:root
		</Owner>
		<Contents>
		#include <tunnels.file>
		</Contents>
	</shorwall-tunnels>
	<shorwall-tcrules>
			Version 4.0.15
		Revision = 1

		Help <<EOF
		Shoreline Firewall (Shorewall)
		Homepage: http://www.shorewall.net
		Requires: shorwall.lrp iptables.lrp ulogd.lrp

		LEAF package by __PACKAGER__, __BUILDDATE__
		EOF

		<Permissions>
			Files = 644
			Directories = 755
		</Permissions>

		<Owner>
			Files = root:root
			Directories = root:root
		</Owner>
		<Contents>
			#include <tcrules.file>
		</Contents>
	</shorwall-tcrules>
	<shorwall-tc>
		Version 4.0.15
		Revision = 1

		Help <<EOF
		Shoreline Firewall (Shorewall)
		Homepage: http://www.shorewall.net
		Requires: shorwall.lrp iptables.lrp ulogd.lrp

		LEAF package by __PACKAGER__, __BUILDDATE__
		EOF

		<Permissions>
			Files = 644
			Directories = 755
		</Permissions>

		<Owner>
			Files = root:root
			Directories = root:root
		</Owner>
		<Contents>
			#include <tc.file>
		</Contents>
	</shorwall-tc>

	<shorwall>
		packagename=shorwall
		Version 4.0.15
		Revision = 1

		Help <<EOF
		Shoreline Firewall (Shorewall)
		Homepage: http://www.shorewall.net
		Requires: iptables.lrp ulogd.lrp

		LEAF package by __PACKAGER__, __BUILDDATE__
		EOF

		<Permissions>
			Files = 644
			Directories = 755
		</Permissions>

		<Owner>
			Files = root:root
			Directories = root:root
		</Owner>

		<Contents>
		#include <common.cfg>
		#include <maclist.file>
		#include <dynamiczones.file>
		#include <accounting.file>
		#include <providers.file>
		#include <proxyarp.file>
		#include <tunnels.file>
		#include <tcrules.file>
		#include <tc.file>
		</Contents>
	</shorwall>
</Package>


------------------------------------------------------------------------------
This SF.net email is sponsored by Sprint
What will you do first with EVO, the first 4G phone?
Visit sprint.com/first -- http://p.sf.net/sfu/sprint-com-first
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.