Variable-length data?
Greetings.
I have written a simple filter for matching multiple network masks in a list. From what I can see, the actual netfilter data has to be constant sized. Is this true, or is there an easy way to have a non-fixed size list of addresses (for example)? It seems rather wasteful to allocate a large array when only a small one is needed.
Thanks.
Signature · 2 lines
Bruce Guenter <[email protected]> http://em.ca/~bruceg/ http://untroubled.org/ OpenPGP key: 699980E8 / D0B7 C8DD 365D A395 29DA 2E2A E96F B2DC 6999 80E8
Quoted 4 lines · Bruce Guenter
I have written a simple filter for matching multiple network masks in a list. From what I can see, the actual netfilter data has to be constant sized. Is this true, or is there an easy way to have a non-fixed size list of addresses (for example)?
iptables matches (and targets) must use a static size matchdata structure per match (or target).
Quoted 1 line
It seems rather wasteful to allocate a large array when only a small one is needed.
It is.
Regards
Henrik