From: Roman Ammann <rammann@ita.hsr.ch>
To: netfilter-devel@lists.netfilter.org
Subject: Connection ID in conntrack and libctnetlink / Max connections showed by conntrack
Date: Sun, 01 May 2005 13:08:40 +0200 [thread overview]
Message-ID: <1114945720.22582.26.camel@localhost.localdomain> (raw)
Hello
Background:
(short version) I tried to use conntrack to delete connections in the
conntrack table.
(long version) I'm using iptables to give some customers access for some
time (1 or 2h). I allow established connections to pass and also the
customer's source IP. The problem is if I drop the rule which allows the
customer's IP address to pass, it doesn't drops his connections, because
they are handled in the state full part of iptables. So if he's using
VPN for example the connection is never dropped :-(. I need to use
state-full inspections because I have to NAT.
What I've done until now:
I've used patch-o-magic to patch my kernel with the nfnetlink, the
conntrack-event-api and the ctnetlink patch. I also compiled and
installed libnfnetlink, libctnetlink and conntrack (newest
SVN-Versions). Everthing seems to work.
Problems:
a) I can't drop a connections because I have to pass the connections ID
to the programm conntrack (conntrack -D conntrack -i <id>) and conntrack
doesn't listen dem (conntrack -L conntrack).
So i checked the source code and I found in the file
conntrack/src/libct.c (line 194) and also in dhe Kernel-Sources
(include/linux/netfilter_ipv4/ip_conntrack_netlink.h) that the ID part
is commented out.
Why? Is there a problem with the ID? I removed the comments and
recompile it. Afterwards the ID was showed but some connections had the
same ID. Is that correct?
b) I used conntrack (conntrack -L conntrack) to list my current
connections. But conntrack list just 16 connections. But if I
use /proc/net/ip_conntrack is see 31 connections.
Is there a problem to get all connections over netlink? Is there a
difference between fetch the connections with netlink or
via /proc/net/ip_conntrack?
Thanks for any input
Roman
next reply other threads:[~2005-05-01 11:08 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-05-01 11:08 Roman Ammann [this message]
2005-05-03 0:01 ` Connection ID in conntrack and libctnetlink / Max connections showed by conntrack Pablo Neira
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=1114945720.22582.26.camel@localhost.localdomain \
--to=rammann@ita.hsr.ch \
--cc=netfilter-devel@lists.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.