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] [thread-next>] [day] [month] [year] [list]
Message-ID: <30529.1494853879@warthog.procyon.org.uk>
Date:   Mon, 15 May 2017 14:11:19 +0100
From:   David Howells <dhowells@...hat.com>
To:     "Jason A. Donenfeld" <Jason@...c4.com>
Cc:     dhowells@...hat.com, netdev@...r.kernel.org,
        linux-kernel@...r.kernel.org, davem@...emloft.net,
        kernel-hardening@...ts.openwall.com
Subject: Re: [PATCH v8 3/5] rxrpc: check return value of skb_to_sgvec always

Jason A. Donenfeld <Jason@...c4.com> wrote:

> +	if (unlikely(skb_to_sgvec(skb, sg, offset, 8) < 0))
> +		goto nomem;
> ...
> +	if (unlikely(skb_to_sgvec(skb, sg, offset, len) < 0)) {
> +		if (sg != _sg)
> +			kfree(sg);
> +		goto nomem;

skb_to_sgvec() can return -EMSGSIZE in some circumstances.  You shouldn't
return -ENOMEM here in such a case.

David

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ