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: <20250625170001.GI1562@horms.kernel.org>
Date: Wed, 25 Jun 2025 18:00:01 +0100
From: Simon Horman <horms@...nel.org>
To: Fushuai Wang <wangfushuai@...du.com>
Cc: andrew+netdev@...n.ch, davem@...emloft.net, edumazet@...gle.com,
	ioana.ciornei@....com, kuba@...nel.org,
	linux-kernel@...r.kernel.org, netdev@...r.kernel.org,
	pabeni@...hat.com
Subject: Re: [PATCH net] dpaa2-eth: fix xdp_rxq_info leak in
 dpaa2_eth_setup_rx_flow

On Wed, Jun 25, 2025 at 08:55:47PM +0800, Fushuai Wang wrote:
> >> When xdp_rxq_info_reg_mem_model() fails after a successful
> >> xdp_rxq_info_reg(), the kernel may leaks the registered RXQ
> >> info structure. Fix this by calling xdp_rxq_info_unreg() in
> >> the error path, ensuring proper cleanup when memory model
> >> registration fails.
> >>
> >> Fixes: d678be1dc1ec ("dpaa2-eth: add XDP_REDIRECT support")
> >> Signed-off-by: Fushuai Wang <wangfushuai@...du.com>
> > 
> > Thanks, I agree this is needed.
> > 
> > Reviewed-by: Simon Horman <horms@...nel.org>
> > 
> > But I wonder how these resources are released in the following cases:
> > 
> > * Error in dpaa2_eth_bind_dpni() after at least one
> >   successful call to dpaa2_eth_setup_rx_flow()
> > 
> > * Error in dpaa2_eth_probe() after a successful call to
> >   dpaa2_eth_bind_dpni()
> > 
> > * Driver removal (dpaa2_eth_remove())
> 
> Hi, Simon
> 
> I think these paths also leak xdp_rxq_info.
> I'll add cleanup for them and send v2 shortly.

Great, thanks.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ