Skip to contentSkip to conversation

Libipq and invalid packet_id

DISCUSSION Eric Leblond 2 participants 5 messages Jun 25, 2003 – Jun 27, 2003 netfilter

lore
Share & tools
lore
#0 lore raw

Hi,

I'm starting to code an application using libipq.

I saw that, if I give an invalid packet_id to ipq_set_verdict, I'm not able to receive any packet afterward. So I've got two questions :
- Is this a wanted feature ?
- If Yes, then Why ? ;-)

BR,

Signature · 1 line
Eric Leblond <[email protected]>
#1 lore raw
Quoted 3 lines · Eric Leblond

I saw that, if I give an invalid packet_id to ipq_set_verdict, I'm not able to receive any packet afterward. So I've got two questions :
- Is this a wanted feature ?

No.

- James

Signature · 2 lines
James Morris
<[email protected]>
#2 lore raw
Quoted 4 lines · James Morris
Quoted 1 line · Eric Leblond

- Is this a wanted feature ?

No.

So I've got other related questions :
- How is memory managed, ie what's happen if we queue a lot of packet
without setting any verdict ?
- In particular, what's happened if we do successive call to
ipg_getmessage ? Do ipg_getmessage reuse address space after each call ?

BR,

Signature · 1 line
Eric Leblond <[email protected]>
#3 lore raw
Quoted 9 lines · Eric Leblond
Quoted 4 lines · James Morris
Quoted 1 line · Eric Leblond

- Is this a wanted feature ?

No.

So I've got other related questions :
- How is memory managed, ie what's happen if we queue a lot of packet
without setting any verdict ?

There is a tunable queue length, and packets are dropped once it fills up.

Quoted 2 lines

- In particular, what's happened if we do successive call to
ipg_getmessage ? Do ipg_getmessage reuse address space after each call ?

Do you mean ipq_get_packet() ? It's just a wrapper which reads one netlink message from your local receive buffer.

- James

Signature · 2 lines
James Morris
<[email protected]>
#4 lore raw

Le jeu 26/06/2003 à 15:40, James Morris a écrit :

OOPS, that was a mistake on my side....
Receiving the error message from netlink causes one of the thread to stop :-(

Thanks for all

Signature · 1 line
Eric Leblond <[email protected]>