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: <IA1PR11MB62896ACA123AAED81DA3FFC689E92@IA1PR11MB6289.namprd11.prod.outlook.com>
Date: Thu, 30 Jan 2025 19:18:53 +0000
From: "Joshi, Sreedevi" <sreedevi.joshi@...el.com>
To: Russell King <linux@...linux.org.uk>, sreedevi.joshi
	<joshisre@...mtp.an.intel.com>
CC: "andrew@...n.ch" <andrew@...n.ch>, "hkallweit1@...il.com"
	<hkallweit1@...il.com>, "edumazet@...gle.com" <edumazet@...gle.com>,
	"kuba@...nel.org" <kuba@...nel.org>, "pabeni@...hat.com" <pabeni@...hat.com>,
	"netdev@...r.kernel.org" <netdev@...r.kernel.org>
Subject: RE: [PATCH net] phy: fix null pointer issue in phy_attach_direct()



> -----Original Message-----
> From: Russell King <linux@...linux.org.uk>
> Sent: Wednesday, January 29, 2025 2:30 PM
> To: sreedevi.joshi <joshisre@...mtp.an.intel.com>
> Cc: andrew@...n.ch; hkallweit1@...il.com; edumazet@...gle.com; kuba@...nel.org; pabeni@...hat.com;
> netdev@...r.kernel.org; Joshi, Sreedevi <sreedevi.joshi@...el.com>
> Subject: Re: [PATCH net] phy: fix null pointer issue in phy_attach_direct()
> 
> On Wed, Jan 29, 2025 at 12:36:38PM -0600, sreedevi.joshi wrote:
> > From: Sreedevi Joshi <sreedevi.joshi@...el.com>
> >
> > When attaching a fixed phy to devices like veth, it is possible that
> > there is no parent. The logic in
> > phy_attach_direct() tries to access the driver member without checking
> > for the null. This causes segfault in the case of fixed phy.
> 
> Kernel mode doesn't segfault. That's a userspace thing. Kernel mode oopses.
You are right. My bad for using for the wrong terminology. I have attached the
Kernel Oops log in my previous reply.
> 
> I'm confused. You mention veth, which presumably is drivers/net/veth.c.
> Grepping this driver for "phy" returns nothing. So how can veth be broken by a phylib change?
Yes. There is no PHY attached to the veth. This is part of the POC we are working on. We attach a
Fixed PHY to veth so the mii_timestamper hooks can be exercised for the demo. This was uncovered 
during that and even though there is no PHY usually attached to a virtual interface, it may be good
idea to have the necessary check before accessing the member to avoid issues. Wanted to check with
community if it can be included in the upstream driver.
> 
> --
> RMK's Patch system: https://www.armlinux.org.uk/developer/patches/
> FTTP is here! 80Mbps down 10Mbps up. Decent connectivity at last!

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ