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: <CANr6G5zw4NR5brVZ=AwXa9Gk0ALYDbPO=+LL-aRLJW=xsvdwJw@mail.gmail.com>
Date:	Mon, 3 Aug 2015 13:34:58 -0700
From:	Joe Stringer <joestringer@...ira.com>
To:	Pablo Neira Ayuso <pablo@...filter.org>
Cc:	Dan Carpenter <dan.carpenter@...cle.com>,
	Patrick McHardy <kaber@...sh.net>,
	Jozsef Kadlecsik <kadlec@...ckhole.kfki.hu>,
	"David S. Miller" <davem@...emloft.net>,
	netfilter-devel@...r.kernel.org, coreteam@...filter.org,
	Linux Netdev List <netdev@...r.kernel.org>,
	kernel-janitors@...r.kernel.org
Subject: Re: [patch -master] netfilter: xt_CT: checking for IS_ERR() instead
 of NULL

On 3 August 2015 at 13:24, Pablo Neira Ayuso <pablo@...filter.org> wrote:
> On Mon, Aug 03, 2015 at 11:30:16AM -0700, Joe Stringer wrote:
>> On 3 August 2015 at 11:29, Joe Stringer <joestringer@...ira.com> wrote:
>> > On 30 July 2015 at 04:57, Pablo Neira Ayuso <pablo@...filter.org> wrote:
>> >> On Tue, Jul 28, 2015 at 01:42:28AM +0300, Dan Carpenter wrote:
>> >>> We recently changed this from nf_conntrack_alloc() to nf_ct_tmpl_alloc()
>> >>> so the error handling needs to changed to check for NULL instead of
>> >>> IS_ERR().
>> >>>
>> >>> Fixes: 0838aa7fcfcd ('netfilter: fix netns dependencies with conntrack templates')
>> >>> Signed-off-by: Dan Carpenter <dan.carpenter@...cle.com>
>> >>
>> >> Applied, thanks.
>> >>
>> >> I have also appended this chunk, since synproxy is also affected:
>> >>
>> >> --- a/net/netfilter/nf_synproxy_core.c
>> >> +++ b/net/netfilter/nf_synproxy_core.c
>> >> @@ -353,7 +353,7 @@ static int __net_init synproxy_net_init(struct net *net)
>> >>         int err = -ENOMEM;
>> >>
>> >>         ct = nf_ct_tmpl_alloc(net, 0, GFP_KERNEL);
>> >> -       if (IS_ERR(ct)) {
>> >> +       if (!ct) {
>> >>                 err = PTR_ERR(ct);
>> >>                 goto err1;
>> >>         }
>> >
>> > Does PTR_ERR() implicitly interpret NULL as -ENOMEM? Seems like the
>> > fix applied here is a little different from the xt_CT fix.
>>
>> Just saw the initialization of err now, but this would be overridden
>> within the error checking statement.
>
> Right, I noticed before pushing out this change, the final applied
> patch is here:
>
> http://git.kernel.org/cgit/linux/kernel/git/pablo/nf.git/commit/?id=1a727c63612fc582370cf3dc01239d3d239743b5
>
> Let me know if you still have any concern, thanks Joe.

Looks fine. Apologies for the noise.
--
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