From: Ramunas Vabolis <ramuva@openoffice.lt>
To: netfilter@vger.kernel.org
Subject: Re: raw table and NOTRACK target
Date: Fri, 26 Jun 2009 16:09:44 +0300 [thread overview]
Message-ID: <20090626130944.GA18792@openoffice.lt> (raw)
In-Reply-To: <1246020740.3985.11.camel@casper.meteor.dp.ua>
Hello again,
> If I've got it right you are trying to do DNAT. The problem was that
> everything was not being traced by conntrack, this is what you've
> already fixed.
Yes, I'm trying to do some DNAT, but still got a long way to go.
> Next, as you've told in further message nothing block that traffic in -t
> filter, that's good.
>
> Next, show as the actual DNAT rules and check the counters encrease as
> you trying to connect.
>
> You can also check whether the connection is actually being tracked by
> analizing output of "conntrack -L" or "conntrack -E"
The problem is that I'm stuck at step.1 - excluding items from
NOTRACK. As soon as I add rules with RETURN in raw table, packets are
dropped somewhere. To reproduce:
I've got a host, which connects with lynx to any website.
In router there no DROP rules in FORWARD and single line in raw table:
/sbin/iptables -t raw -A PREROUTING -j NOTRACK
Host connects to any remote host port 80.
As soon as I add two lines with -j RETURN in raw table (so the entries
are tracked) I experience the same effect as I've added -j DROP:
/sbin/iptables -t raw -I PREROUTING -p tcp -s host.ip --dport 80 -j RETURN
/sbin/iptables -t raw -I PREROUTING -p tcp -d host.ip --sport 80 -j RETURN
are acting as I've made these rules:
/sbin/iptables -t raw -I PREROUTING -p tcp -s host.ip --dport 80 -j DROP
/sbin/iptables -t raw -I PREROUTING -p tcp -d host.ip --sport 80 -j DROP
I've tried replacing RETURN with ACCEPT with same results. As soon as I
remove those 2 rules, host.ip can connect to remote 80 port.
next prev parent reply other threads:[~2009-06-26 13:09 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-25 13:05 raw table and NOTRACK target Ramunas Vabolis
2009-06-26 7:08 ` Покотиленко Костик
2009-06-26 7:43 ` Ramunas Vabolis
2009-06-26 7:53 ` Philip Craig
2009-06-26 8:20 ` Ramunas Vabolis
2009-06-26 12:52 ` Покотиленко Костик
2009-06-26 13:09 ` Ramunas Vabolis [this message]
2009-06-26 13:31 ` Покотиленко Костик
2009-06-29 7:33 ` Ramunas Vabolis
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=20090626130944.GA18792@openoffice.lt \
--to=ramuva@openoffice.lt \
--cc=netfilter@vger.kernel.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