Need Help !!!
A message that is not in the archive (sent off-list or not yet received): [email protected]
HI,
Can u help me ???
---------------------------------------------------------------------
INTRO :
----------------------------------------------------------------------
i need to maintain counters for number of packets
1. drop
2. accepted.
by Netfilter and the protocol distribution among them.
i put two counters in nf_hook_slow(...) function inBnet/core/netfilter.c
switch(verdict){
case NF_ACCEPT:
pkt_accept_count++;
case NF_DROP :
pkt_drop_count++;
} -----------------------------------------------------------------------
OBSERVATION :
-----------------------------------------------------------------------
when default policy is ACCEPT and i write rules to drop
selective packets i am getting the appropiate values of counters.
but when the default policy is DROP and no other rule for
ACCEPT then both the counters (pkt_accept_count and pkt_drop_count ) are incrementing !!!!
-----------------------------------------------------------------------
QUERY :
-----------------------------------------------------------------------
1. As i am not accepting a single packet the whypkt_accept_count counter is incrementing !!!
2. Is there any other better way to do the job ?
-----------------------------------------------------------------------
Regards
Biswajit