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 for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <449D3522-802F-47D8-9D8E-C7DF2CBD6C5F@oracle.com>
Date:   Fri, 6 Dec 2019 20:07:19 +0100
From:   Håkon Bugge <haakon.bugge@...cle.com>
To:     Eric Dumazet <eric.dumazet@...il.com>
Cc:     "David S . Miller" <davem@...emloft.net>, netdev@...r.kernel.org
Subject: Re: [PATCH net] net: netlink: Fix uninit-value in netlink_recvmsg()



> On 6 Dec 2019, at 19:47, Eric Dumazet <eric.dumazet@...il.com> wrote:
> 
> 
> 
> On 12/6/19 5:49 AM, Håkon Bugge wrote:
>> If skb_recv_datagram() returns NULL, netlink_recvmsg() will return an
>> arbitrarily value.
>> 
>> Signed-off-by: Håkon Bugge <haakon.bugge@...cle.com>
>> ---
>> net/netlink/af_netlink.c | 1 +
>> 1 file changed, 1 insertion(+)
>> 
>> diff --git a/net/netlink/af_netlink.c b/net/netlink/af_netlink.c
>> index 90b2ab9dd449..bb7276f9c9f8 100644
>> --- a/net/netlink/af_netlink.c
>> +++ b/net/netlink/af_netlink.c
>> @@ -1936,6 +1936,7 @@ static int netlink_recvmsg(struct socket *sock, struct msghdr *msg, size_t len,
>> 		return -EOPNOTSUPP;
>> 
>> 	copied = 0;
>> +	err = 0;
>> 
>> 	skb = skb_recv_datagram(sk, flags, noblock, &err);
>> 	if (skb == NULL)
>> 
> 
> Please provide a Fixes: tag
> 
> By doing the research, you probably would find there is no bug.
> 
> err is set in skb_recv_datagram() when there is no packet to read.

yes, you are right, by bad.


Håkon


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ