From: git@ipfire.org
To: ipfire-scm@lists.ipfire.org
Subject: [git.ipfire.org] IPFire 2.x development tree branch, core84, updated. e43b21264f8b0c28a9b03f8f65d46e47572df719
Date: Sat, 04 Oct 2014 18:00:02 +0200 [thread overview]
Message-ID: <20141004160002.DDBDC21260@argus.ipfire.org> (raw)
[-- Attachment #1: Type: text/plain, Size: 2467 bytes --]
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "IPFire 2.x development tree".
The branch, core84 has been updated
discards 402c0097ec47b82437296507bc2c5118b8cf9401 (commit)
This update discarded existing revisions and left the branch pointing at
a previous point in the repository history.
* -- * -- N (e43b21264f8b0c28a9b03f8f65d46e47572df719)
\
O -- O -- O (402c0097ec47b82437296507bc2c5118b8cf9401)
The removed revisions are not necessarilly gone - if another reference
still refers to them they will stay in the repository.
No new revisions were added by this update.
Summary of changes:
config/firewall/rules.pl | 16 +++++++++++++---
src/initscripts/init.d/firewall | 5 -----
2 files changed, 13 insertions(+), 8 deletions(-)
Difference in files:
diff --git a/config/firewall/rules.pl b/config/firewall/rules.pl
index 58cc439..4d70382 100755
--- a/config/firewall/rules.pl
+++ b/config/firewall/rules.pl
@@ -554,19 +554,29 @@ sub time_convert_to_minutes {
}
sub p2pblock {
+ my $search_action;
+ my $target;
+
+ if ($fwdfwsettings{"POLICY"} eq "MODE1") {
+ $search_action = "on";
+ $target = "ACCEPT";
+ } else {
+ $search_action = "off";
+ $target = "DROP";
+ }
+
open(FILE, "<$p2pfile") or die "Unable to read $p2pfile";
my @protocols = ();
foreach my $p2pentry (<FILE>) {
my @p2pline = split(/\;/, $p2pentry);
- next unless ($p2pline[2] eq "off";
+ next unless ($p2pline[2] eq $search_action);
push(@protocols, "--$p2pline[1]");
}
close(FILE);
if (@protocols) {
- run("$IPTABLES -F P2PBLOCK");
- run("$IPTABLES -A P2PBLOCK -m ipp2p @protocols -j DROP");
+ run("$IPTABLES -A FORWARDFW -m ipp2p @protocols -j $target");
}
}
diff --git a/src/initscripts/init.d/firewall b/src/initscripts/init.d/firewall
index 9620c80..66ca432 100644
--- a/src/initscripts/init.d/firewall
+++ b/src/initscripts/init.d/firewall
@@ -84,11 +84,6 @@ iptables_init() {
iptables -A INPUT -p tcp -j BADTCP
iptables -A FORWARD -p tcp -j BADTCP
- # P2P Block (must before connection tracking)
- iptables -N P2PBLOCK
- iptables -A INPUT -p tcp -j P2PBLOCK
- iptables -A FORWARD -p tcp -j P2PBLOCK
-
# Connection tracking chain
iptables -N CONNTRACK
iptables -A CONNTRACK -m conntrack --ctstate ESTABLISHED,RELATED -j ACCEPT
hooks/post-receive
--
IPFire 2.x development tree
next reply other threads:[~2014-10-04 16:00 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-10-04 16:00 git [this message]
-- strict thread matches above, loose matches on Subject: below --
2014-10-04 11:54 git
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20141004160002.DDBDC21260@argus.ipfire.org \
--to=git@ipfire.org \
--cc=ipfire-scm@lists.ipfire.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox