From: Pablo Neira <pablo@eurodev.net>
To: mase hare <masehare@webmail.co.za>, netfilter-devel@lists.netfilter.org
Subject: Re: Probing counters without calling IPtables -L
Date: Fri, 05 Mar 2004 20:01:56 +0100 [thread overview]
Message-ID: <4048CEA4.1050604@eurodev.net> (raw)
In-Reply-To: <web-250618034@mail01.infosat.net>
Hi mase,
mase hare wrote:
>Good day all NetFilter/IPtables developers!
>
>I am a IPtables user, and I do like it very much.
>Thats why I want to use IPtables with my development.
>I want to develop my own C program to compilment
>IPtables to do accounting on network traffic for me.
>
>Now there is plenty of accounting programs available
>on the web, but most uses scripts with the iptables -L -v
>command to generate sumarry files.
>
>I would like to build a stand-alone deamon to probe
>only the specific rules' counters ( packets, bytes ),
>thus no scripting, and no iptables -L -v.
>
>I think this was possible with IPchaincs by looking in
>a specific file in /proc/net/ip_*
>
>---------------------------------
>Now my question is:
>Is there for IPtables also a file which one can cat
>to read the counters from, in /proc/net/*?
>And if not, what -in your opinions- would be the
>best course for me to take
>in getting these counters inside my C program
>with their source and destination addresses.
>---------------------------------
>
>
Anyway, if you are thinking about reading from /proc/net/* in short
period of time, you must take into account that this will decrease
considerably the performance. Harald pointed out a similar issue for
iptstate.
regards,
Pablo
prev parent reply other threads:[~2004-03-05 19:01 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-03-05 14:51 Probing counters without calling IPtables -L mase hare
2004-03-05 19:01 ` Pablo Neira [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=4048CEA4.1050604@eurodev.net \
--to=pablo@eurodev.net \
--cc=masehare@webmail.co.za \
--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.