lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CA+rthh-nL5SemBqxEJah493E8iofaWb1zg=JJmiKifamUL9RJg@mail.gmail.com>
Date:	Sun, 19 Jul 2015 21:57:18 +0200
From:	Mathias Krause <minipli@...glemail.com>
To:	David Miller <davem@...emloft.net>
Cc:	Pablo Neira Ayuso <pablo@...filter.org>,
	Patrick McHardy <kaber@...sh.net>,
	Jozsef Kadlecsik <kadlec@...ckhole.kfki.hu>,
	netdev@...r.kernel.org, netfilter-devel@...r.kernel.org
Subject: Re: [PATCH net-next] net: #ifdefify sk_classid member of struct sock

On 19 July 2015 at 20:42, David Miller <davem@...emloft.net> wrote:
> From: Mathias Krause <minipli@...glemail.com>
> Date: Sun, 19 Jul 2015 20:17:41 +0200
>
>> The sk_classid member is only required when CONFIG_CGROUP_NET_CLASSID is
>> enabled. #ifdefify it to reduce the size of struct sock on 32 bit
>> systems, at least.
>>
>> Signed-off-by: Mathias Krause <minipli@...glemail.com>
>
> Are you sure NFT_META_CGROUP cannot enter nft_meta_get_eval()?  If so it'll
> WARN_ON().

I just tried to bring the code in line as it already is for
NFT_META_RTCLASSID and NFT_META_SECMARK. But, obviously, I messed it
up by missing the nft_meta_get_init() function. Sorry for that!

The init function gets called prior to the eval function (see
nft_expr_init() and nf_tables_newrule()). If it returns an error, the
latter won't be called. So the fix is, to add the #ifdef to
nft_meta_get_init() as well.

Another direct caller of  nft_meta_get_eval() is
nft_meta_bridge_get_eval(). However, it also complies to the init /
eval rule by calling nft_meta_get_init() in its init function, so will
error out in the case, too.

I'll send a v2 soon.

Thanks for the review!

> I really don't like changes like this.

Sorry. I should have taken more attention.


Thanks,
Mathias
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ