netfilter-devel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Pablo Neira Ayuso <pablo@netfilter.org>
To: Ed W <lists@wildgooses.com>
Cc: netfilter-devel@vger.kernel.org
Subject: Re: How to access conntrack connection expiration in a netfilter module?
Date: Wed, 3 Oct 2012 10:25:36 +0200	[thread overview]
Message-ID: <20121003082535.GA26812@1984> (raw)
In-Reply-To: <506BEAC3.30103@wildgooses.com>

On Wed, Oct 03, 2012 at 08:35:31AM +0100, Ed W wrote:
> On 02/10/2012 19:17, Pablo Neira Ayuso wrote:
> 
> >We used to have notifier call chains to deliver in-kernel
> >nofitications to events. However, since it was overkill for just one
> >single client (ctnetlink), we removed it and use a single hook
> >function.
> >
> >The workaround is to dig into the history, find that code and forward
> >port it.
> >
> >But I have to warn you that I won't take that patch into mainstream
> >since there's only one single client in the official Linux kernel
> >code, and external clients like that ndpi thing do not justify such
> >change. Sorry.
> 
> Understood.  I have temporarily hacked in a crude second notifier
> variable, just about to test it.
> 
> However, it seems like a common requirement to want to be able to do
> some housekeeping in netfilter modules - what am I missing, how are
> other modules doing stuff like this?  Is there another technique
> which might be used?  Any other modules which do something similar
> that I could crib from, ie with some internal state augmenting a
> flow and then needing to cleanup sometime after the flow has gone
> away?

I guess your modules are not using conntrack extensions:

See net/netfilter/nf_conntrack_extend.c and
net/netfilter/nf_conntrack_acct.c for instance.

  reply	other threads:[~2012-10-03  8:25 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-10-01 21:17 How to access conntrack connection expiration in a netfilter module? Ed W
2012-10-02 17:02 ` Ed W
2012-10-02 18:17 ` Pablo Neira Ayuso
2012-10-03  7:35   ` Ed W
2012-10-03  8:25     ` Pablo Neira Ayuso [this message]
2013-05-29 19:22       ` Aidan McGurn

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=20121003082535.GA26812@1984 \
    --to=pablo@netfilter.org \
    --cc=lists@wildgooses.com \
    --cc=netfilter-devel@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;
as well as URLs for NNTP newsgroup(s).