From: Mr Dash Four <mr.dash.four@googlemail.com>
To: Pablo Neira Ayuso <pablo@netfilter.org>
Cc: Jan Engelhardt <jengelh@medozas.de>,
Netfilter Developer Mailing List
<netfilter-devel@vger.kernel.org>,
netfilter@vger.kernel.org
Subject: Re: event-driven connection tracking
Date: Thu, 14 Oct 2010 14:26:15 +0100 [thread overview]
Message-ID: <4CB704F7.60608@googlemail.com> (raw)
In-Reply-To: <4CB6F1E2.3030702@netfilter.org>
>>>> conntrack -Ee NEW,DESTROY
>>>>
>>>> would list you the specified events as they happen. Combined with a script
>>>> that reacts when a new line is outputted by conntrack should
>>>> do the trick.
>>>>
>>>>
>>> That's not what I am after!
>>>
>>> If I want to poll a text output every-so-often I can use /proc/net/nf_conntrack
>>>
>> -E is event driven. (That's why it's got the "E".)
>>
>
> Indeed, if you're looking for a tool to listen to event-driven conntrack
> notifications, then what Jan suggests is the correct approach. If you
> want to make your own handling application, you can use
> libnetfilter_conntrack.
>
Making my own handling application was the preferred way, though I would
have settled for text-based notifications through the stdin pipe (a bit
clumsy, but doable). As it turns out libnetfilter_conntrack seems to
provide me with what I need, so I would settle for that.
Another constraint I have (which I did not mention in my initial post)
is that, for various reasons, I am using the 2.6.16.60 kernel - the
libnetfilter_conntrack requirements suggest I can get away with it, is
there anything in particular I should be aware of when installing/using
this package with this kernel version (no, I am not in a position to
upgrade - not yet!)?
> For logging, you can use ulogd2.
>
I have been doing the logging and it is not what I need as the 'action'
I take depends on what I find in the event matches - sometimes it is
necessary to just log the necessary data, but sometimes I would need to
initiate process scanning and full packet dumps on a particular
connection - for that to just use logging won't be enough.
next prev parent reply other threads:[~2010-10-14 13:26 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-13 15:24 event-driven connection tracking Mr Dash Four
2010-10-13 15:48 ` Jan Engelhardt
2010-10-13 22:18 ` Mr Dash Four
2010-10-13 22:56 ` Jan Engelhardt
2010-10-14 12:04 ` Pablo Neira Ayuso
2010-10-14 13:26 ` Mr Dash Four [this message]
2010-10-15 7:17 ` Pablo Neira Ayuso
2010-10-14 12:01 ` Pablo Neira Ayuso
2010-10-14 13:14 ` Mr Dash Four
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=4CB704F7.60608@googlemail.com \
--to=mr.dash.four@googlemail.com \
--cc=jengelh@medozas.de \
--cc=netfilter-devel@vger.kernel.org \
--cc=netfilter@vger.kernel.org \
--cc=pablo@netfilter.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.