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]
Date:   Thu, 31 May 2018 04:50:21 -0400
From:   Eric Dumazet <eric.dumazet@...il.com>
To:     Samuel Mendoza-Jonas <sam@...dozajonas.com>, netdev@...r.kernel.org
Cc:     "David S . Miller" <davem@...emloft.net>,
        linux-kernel@...r.kernel.org, openbmc@...ts.ozlabs.org
Subject: Re: [PATCH net-next] net/ncsi: Avoid GFP_KERNEL in response handler



On 05/31/2018 03:02 AM, Samuel Mendoza-Jonas wrote:
> ncsi_rsp_handler_gc() allocates the filter arrays using GFP_KERNEL in
> softirq context, causing the below backtrace. This allocation is only a
> few dozen bytes during probing so allocate with GFP_ATOMIC instead.
> 

Hi Samuel

You forgot to add

Fixes: 062b3e1b6d4f ("net/ncsi: Refactor MAC, VLAN filters")

size = (rsp->uc_cnt + rsp->mc_cnt + rsp->mixed_cnt) * ETH_ALEN;

-> seems to be able to reach more than few dozen bytes...

Also, what prevents ncsi_rsp_handler_gc() to be called multiples times ?

nc->mac_filter.addrs & nc->vlan_filter.vids would be re-allocated and memory would leak.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ