summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarkus Ullmann <jokey@gentoo.org>2007-09-06 11:16:44 +0000
committerMarkus Ullmann <jokey@gentoo.org>2007-09-06 11:16:44 +0000
commitbc3b7540482a16faf2af4498edd9f6758c98315b (patch)
treef4d4f84829bc096373756e2e90383fa8b82716e7 /net-firewall/shorewall-common/files
parentInitial import of shorewall 4.x series wrt bug #174588 thanks to Vieri (diff)
downloadgentoo-2-bc3b7540482a16faf2af4498edd9f6758c98315b.tar.gz
gentoo-2-bc3b7540482a16faf2af4498edd9f6758c98315b.tar.bz2
gentoo-2-bc3b7540482a16faf2af4498edd9f6758c98315b.zip
Initial import of shorewall 4.x series wrt bug #174588 thanks to Vieri
(Portage version: 2.1.3.7)
Diffstat (limited to 'net-firewall/shorewall-common/files')
-rw-r--r--net-firewall/shorewall-common/files/digest-shorewall-common-4.0.36
-rw-r--r--net-firewall/shorewall-common/files/shorewall.initd75
2 files changed, 81 insertions, 0 deletions
diff --git a/net-firewall/shorewall-common/files/digest-shorewall-common-4.0.3 b/net-firewall/shorewall-common/files/digest-shorewall-common-4.0.3
new file mode 100644
index 000000000000..b23580de6063
--- /dev/null
+++ b/net-firewall/shorewall-common/files/digest-shorewall-common-4.0.3
@@ -0,0 +1,6 @@
+MD5 34c462dd278592a9b4a98c7ebee5cc9b shorewall-common-4.0.3.tar.bz2 127258
+RMD160 d7894d7f5ce3f9b14645ef36b8b08f1f413cadf9 shorewall-common-4.0.3.tar.bz2 127258
+SHA256 05738d5c6c895f861d5946160c9f4daf8e8316a1fdbb222173c5f5fff133d314 shorewall-common-4.0.3.tar.bz2 127258
+MD5 4657acca54b086992c5b979a99355f5b shorewall-docs-html-4.0.3.tar.bz2 2324955
+RMD160 cfe63071479637909b1ef9bd761814ec0b66cbc6 shorewall-docs-html-4.0.3.tar.bz2 2324955
+SHA256 a7821b955272b149bb7c8dfe164ae338ff62a97c8b417d995af3bf440c968067 shorewall-docs-html-4.0.3.tar.bz2 2324955
diff --git a/net-firewall/shorewall-common/files/shorewall.initd b/net-firewall/shorewall-common/files/shorewall.initd
new file mode 100644
index 000000000000..27efb064ed91
--- /dev/null
+++ b/net-firewall/shorewall-common/files/shorewall.initd
@@ -0,0 +1,75 @@
+#!/sbin/runscript
+# Copyright 1999-2006 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-firewall/shorewall-common/files/shorewall.initd,v 1.1 2007/09/06 11:16:44 jokey Exp $
+
+opts="start stop restart clear reset refresh check"
+
+depend() {
+ need net
+ provide firewall
+ after ulogd
+}
+
+start() {
+ ebegin "Starting firewall"
+ /sbin/shorewall -f start 1>/dev/null
+ eend $?
+}
+
+stop() {
+ ebegin "Stopping firewall"
+ /sbin/shorewall stop 1>/dev/null
+ eend $?
+}
+
+restart() {
+ # shorewall comes with its own control script that includes a
+ # restart function, so refrain from calling svc_stop/svc_start
+ # here. Note that this comment is required to fix bug 55576;
+ # runscript.sh greps this script... (09 Jul 2004 agriffis)
+ ebegin "Restarting firewall"
+ if [ -f /var/lib/shorewall/restore ] ; then
+ /sbin/shorewall restore
+ else
+ /sbin/shorewall restart 1>/dev/null
+ fi
+ eend $?
+}
+
+clear() {
+ # clear will remove all the rules and bring the system to an unfirewalled
+ # state. (21 Nov 2004 eldad)
+
+ ebegin "Clearing all firewall rules and setting policy to ACCEPT"
+ /sbin/shorewall clear
+ eend $?
+}
+
+reset() {
+ # reset the packet and byte counters in the firewall
+
+ ebegin "Resetting the packet and byte counters in the firewall"
+ /sbin/shorewall reset
+ eend $?
+}
+
+refresh() {
+ # refresh the rules involving the broadcast addresses of firewall
+ # interfaces, the black list, traffic control rules and
+ # ECN control rules
+
+ ebegin "Refreshing firewall rules"
+ /sbin/shorewall refresh
+ eend $?
+}
+
+check() {
+ # perform cursory validation of the zones, interfaces, hosts, rules
+ # and policy files. CAUTION: does not parse and validate the generated
+ # iptables commands.
+
+ ebegin "Checking configuration files"
+ /sbin/shorewall check
+ eend $?
+}