Bug 1721962 (CVE-2019-12819) - CVE-2019-12819 kernel: use-after-free in function __mdiobus_register() in drivers/net/phy/mdio_bus.c
Summary: CVE-2019-12819 kernel: use-after-free in function __mdiobus_register() in dri...
Keywords:
Status: CLOSED ERRATA
Alias: CVE-2019-12819
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact: Fendy Tjahjadi
URL:
Whiteboard:
Depends On: 1721969 1723284 1723285 1723286 1772010
Blocks: 1721977
TreeView+ depends on / blocked
 
Reported: 2019-06-19 10:20 UTC by Dhananjay Arunesh
Modified: 2021-02-16 21:48 UTC (History)
44 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
A use-after-free flaw was found in the Linux kernel's MDIO section of the network management subsystem. An attacker who is able to hot-plug a network device can trigger the __mdiobus_register() function in drivers/net/phy/mdio_bus.c, which can cause a use-after-free condition causing a memory corruption and kernel panic or privilege escalation.
Clone Of:
Environment:
Last Closed: 2020-11-04 02:21:25 UTC
Embargoed:


Attachments (Terms of Use)

Description Dhananjay Arunesh 2019-06-19 10:20:25 UTC
An issue was discovered in the Linux kernels implementation of Management Data Input/Output (MDIO) or SMI system.

An attacker who is able to hot-plug a network device can trigger the function
__mdiobus_register() in drivers/net/phy/mdio_bus.c which calls put_device(), which will trigger a fixed_mdio_bus_init use-after-free. This will cause a denial of service.

While this function is also run during system boot with onboard networking hardware, exploiting the use-after-free during this narrow timeframe makes the exploit a non-trivial exercise.


Reference:

https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git/commit/?id=6ff7b060535e87c2ae14dd8548512abfdda528fb

https://en.wikipedia.org/wiki/Management_Data_Input/Output

Comment 1 Dhananjay Arunesh 2019-06-19 10:27:56 UTC
Created kernel tracking bugs for this issue:

Affects: fedora-all [bug 1721969]

Comment 2 Justin M. Forbes 2019-06-19 13:06:22 UTC
This issue was fixed for Fedora with the 4.20.17 stable update

Comment 5 Wade Mealing 2019-06-24 07:47:25 UTC
This flaw is rated as moderate as the MDIO loading code
will likely only be run in early boot, it would be a difficult flaw to exploit and would require
the attacker to be able to run code at this time to groom the memory into place.  I find it unlikely
that this would be exploited on stationary servers, but it may be more of a problem when you can hotplug
devices..

Comment 9 Product Security DevOps Team 2020-11-04 02:21:25 UTC
This bug is now closed. Further updates for individual products will be reflected on the CVE page(s):

https://access.redhat.com/security/cve/cve-2019-12819


Note You need to log in before you can comment on or make changes to this bug.