On Tue, Mar 09, 2010 at 06:03:02PM +0100, Jan Engelhardt wrote: > On Tuesday 2010-03-09 17:48, Lutz Jaenicke wrote: > > >On some platforms (here: Intel IXP4xx ARM big endian) > >sizeof(struct nf_ct_tcp_flags) evaluates to 4 bytes while in the user > >space code 2 bytes is hard coded. > > Why does it evaluate to 4 bytes? That seems to go against all good C > practice. I agree wrt the "against all good C practice" point of view :-) Nevertheless it fails in the policy check via tcp_nla_policy[]: [CTA_PROTOINFO_TCP_FLAGS_ORIGINAL] = { .len = sizeof(struct nf_ct_tcp_flags) }, [CTA_PROTOINFO_TCP_FLAGS_REPLY] = { .len = sizeof(struct nf_ct_tcp_flags) }, The expected length in "validate_nla()" case "default:" is pt->len = 4 while from user space only 2 byte are sent. If you have a good hint on how to answer the "Why does it evaluate to 4 bytes?" question, you are welcome... I cannot explain, I just observed. Best regards, Lutz -- Dr.-Ing. Lutz Jänicke CTO Innominate Security Technologies AG /protecting industrial networks/ tel: +49.30.921028-200 fax: +49.30.921028-020 Rudower Chaussee 13 D-12489 Berlin, Germany www.innominate.com Register Court: AG Charlottenburg, HR B 81603 Management Board: Dirk Seewald Chairman of the Supervisory Board: Volker Bibelhausen -- To unsubscribe from this list: send the line "unsubscribe netfilter-devel" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html