All of lore.kernel.org
 help / color / mirror / Atom feed
From: Pablo Neira Ayuso <pablo@netfilter.org>
To: Gregory Nietsky <gregory@distrotech.co.za>
Cc: netfilter@vger.kernel.org
Subject: Re: libnetfilter_conntrack userspace nat via NFQUEUE
Date: Mon, 4 Jun 2012 14:20:11 +0200	[thread overview]
Message-ID: <20120604122011.GA15680@1984> (raw)
In-Reply-To: <4FCBD18F.2020607@distrotech.co.za>

On Sun, Jun 03, 2012 at 11:05:19PM +0200, Gregory Nietsky wrote:
> 
> Greetings
> 
> I have been working on userspace nat via NFQUEUE i have it working
> but something does not make
> sense to me.

So, you're implementing NAT in user-space with NFQUEUE, right?

> the code below is to build the conntrack and attach the nat attributes.
> 
> i cannot get it working unless i use the following
> 
> nfct_set_attr_u8(ct, ATTR_TCP_STATE, TCP_CONNTRACK_ESTABLISHED);

Yes, this is mandatory to create a new conntrack entry, with and without
NAT.

> the documentation and examples suggest this is not correct however this way
> it works no other options function.
> 
> as the documentation is not extensive perhaps someone will be able
> to comment on this.
> 
> am i correct to only use this for TCP connections.
> 
> the code for this is available @
> http://pbx.distrotech.co.za/svn/taploop/trunk/ in the framework
> directory.

I have a patch here to improve integration between ctnetlink and
nfnl_queue, but you'll have to wait to see that in mainstream.

      reply	other threads:[~2012-06-04 12:20 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-03 21:05 libnetfilter_conntrack userspace nat via NFQUEUE Gregory Nietsky
2012-06-04 12:20 ` Pablo Neira Ayuso [this message]

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=20120604122011.GA15680@1984 \
    --to=pablo@netfilter.org \
    --cc=gregory@distrotech.co.za \
    --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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.