All of lore.kernel.org
 help / color / mirror / Atom feed
* real time stateful filtering question
@ 2004-03-15 15:54 peter smith
  2004-03-17  7:13 ` Henrik Nordstrom
  2004-03-17 13:58 ` Harald Welte
  0 siblings, 2 replies; 12+ messages in thread
From: peter smith @ 2004-03-15 15:54 UTC (permalink / raw)
  To: netfilter-devel

Hello,

Sorry if this topic has come up before, but I was unable to find any past
posting on the subject:

If I wish to monitor using netfilter a link that has applications talking on
it that use ephemeral ports (like, for instance, FTP or H323), is there a
way to install filters fast enough /syncronously enough to guarantee that
you won't miss packets that you have already received? For instance, say
that you have some number of packets in your rx ring buffer waiting to be
processed. The first one is processed, and matches some filter you have set.
That packet is queued for delivery to userland.

That packet also has a FTP PORT command inside it's payload that specifies
the new data channel that the two hosts will use to transfer data. (where
channel == the src/dst ip and src/dst ports)

Unfortunately, packets sent on the data channel are also in your receive
buffer, and get processed by netfilter *before* the "PORT COMMAND" packet
gets processed by the userland monitor, or before the monitor can
sucessfully re-program the netfilter filter list. So they are dropped,
silently.

I have exaggerated this example a bit for clarity, but I believe the race
condition exists, particularly wrt the filter reprogramming.

Is this truly a problem? Have others found a way around it? It appears that
for a stateful filtering application, a user must build a faster mechanism
for programming the filters?

Any comments greatly appreciated.

Thanks,
Peter

^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2004-03-22 11:53 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-03-15 15:54 real time stateful filtering question peter smith
2004-03-17  7:13 ` Henrik Nordstrom
2004-03-17  7:49   ` Saber zrelli
2004-03-17 10:10     ` Henrik Nordstrom
2004-03-17 13:58 ` Harald Welte
2004-03-17 14:53   ` peter smith
2004-03-17 16:13     ` Henrik Nordstrom
2004-03-17 16:38       ` peter smith
2004-03-17 20:03         ` Henrik Nordstrom
2004-03-17 19:44     ` Harald Welte
2004-03-22 11:51   ` ipt_helper-any error Wojciech 'Sas' Cieciwa
2004-03-22 11:53     ` Patrick McHardy

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.