How about issueing conntrack event in init_conntrack()?
hi, all
We all know event IPCT_NEW is issued whenever conntrack is confirmed, then how about issueing a IPCT_INIT event in init_conntrack()? IPCT_INIT indicates that one IP is trying to create a connection, maybe we can catch these kind of events, do some analyzation work, and block the evil *attempting* packet(this will prevent conntrack being confirmed).
Is this make any sense?
Thanks :-)
Daniel
2007-11-15
Quoted 6 lines · Daniel
hi, all
We all know event
IPCT_NEWis issued whenever conntrack is confirmed,
then how about issueing aIPCT_INITevent ininit_conntrack()?IPCT_INITindicates that one IP is trying to create a connection, maybe we can catch these kind of events, do some analyzation work, and block the evil *attempting* packet(this will prevent conntrack being confirmed).Is this make any sense?
That wouldn't work since the connection is going to be confirmed before you get a chance to do something. On SMP it might work, but would be racy. In general ctnetlink events relate to the conntrack table, so we don't want to send events for connections that are not confirmed.