All of lore.kernel.org
 help / color / mirror / Atom feed
From: Psyspy 22 <psyspy2020@gmail.com>
To: Florian Westphal <fw@strlen.de>
Cc: netfilter@vger.kernel.org
Subject: Re: libnetfilter_queue: Access conntrack info
Date: Tue, 29 Jun 2021 08:22:23 -0600	[thread overview]
Message-ID: <CAFqmWq-J8zkO8_nHUh=eS_AyhHJ6kAgPiODXu5wKNQM-d7TRLQ@mail.gmail.com> (raw)
In-Reply-To: <20210629063802.GD24271@breakpoint.cc>

Thanks Florian. I added that flag, no dice.

If  I run the libmnl dump example, it successfully prints all
conntrack entries. I would assume all the conntrack related kernel
modules are loaded. I am on 4.1 kernel. I could be missing something.

On Tue, Jun 29, 2021 at 12:38 AM Florian Westphal <fw@strlen.de> wrote:
>
> Psyspy 22 <psyspy2020@gmail.com> wrote:
> > Hello Duncan,
> >
> > I actually need connmark and other conntrack fields like secmark etc.
> > I think attr[NFQA_CT] is the correct way to access it but it's empty
> > in my case.
> > The libnetfilter_queue example sets connmark but doesn't show a way to
> > get connmark from the packet.
>
> IIRC you need to set NFQA_CFG_F_CONNTRACK in NFQA_CFG_FLAGS when setting
> up the queue.  The example only sets F_GSO, so no conntrack info is
> added.

  reply	other threads:[~2021-06-29 14:22 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-06-28  4:07 libnetfilter_queue: Access conntrack info Psyspy 22
2021-06-29  2:20 ` Duncan Roe
2021-06-29  4:02   ` Psyspy 22
2021-06-29  6:38     ` Florian Westphal
2021-06-29 14:22       ` Psyspy 22 [this message]
2021-06-29 14:38         ` Florian Westphal
2021-07-01 18:13           ` Psyspy 22

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='CAFqmWq-J8zkO8_nHUh=eS_AyhHJ6kAgPiODXu5wKNQM-d7TRLQ@mail.gmail.com' \
    --to=psyspy2020@gmail.com \
    --cc=fw@strlen.de \
    --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.