Bug 2087568 (CVE-2023-1838) - CVE-2023-1838 kernel: Possible use-after-free since the two fdget() during vhost_net_set_backend()
Summary: CVE-2023-1838 kernel: Possible use-after-free since the two fdget() during vh...
Keywords:
Status: NEW
Alias: CVE-2023-1838
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Nobody
QA Contact:
URL:
Whiteboard:
Depends On: 2111141 2111142 2111143 2111144
Blocks: 2087569
TreeView+ depends on / blocked
 
Reported: 2022-05-18 04:39 UTC by Sandipan Roy
Modified: 2024-04-16 19:48 UTC (History)
48 users (show)

Fixed In Version: kernel 5.18 25
Doc Type: If docs needed, set a value
Doc Text:
A use-after-free flaw was found in vhost_net_set_backend in drivers/vhost/net.c in the virtio network subcomponent in the Linux kernel due to a double fget. This issue could allow a local attacker to crash the system, and could lead to a kernel information leak problem.
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2024:0412 0 None None None 2024-01-24 16:42:32 UTC
Red Hat Product Errata RHSA-2024:0575 0 None None None 2024-01-30 13:21:08 UTC
Red Hat Product Errata RHSA-2024:0881 0 None None None 2024-02-20 12:27:51 UTC
Red Hat Product Errata RHSA-2024:0897 0 None None None 2024-02-20 12:33:00 UTC

Description Sandipan Roy 2022-05-18 04:39:37 UTC
A use-after-free flaw was found in vhost_net_set_backend in drivers/vhost/net.c in virtio network subcomponent in the Linux kernel due to a double fget. This flaw could allow a local attacker to crash the system, and could even lead to a kernel information leak problem.

The descriptor table is a shared resource; two fget() on the same descriptor may return different struct file references. get_tap_ptr_ring() is called after we'd found (and pinned) the socket we'll be using and it tries to find the private tun/tap data structures associated with it. Redoing the lookup by the same file descriptor we'd used to get the socket is racy - we need to same struct file.

Patch Reference:
https://lore.kernel.org/netdev/20220516084213.26854-1-jasowang@redhat.com/T/

Comment 17 errata-xmlrpc 2024-01-24 16:42:29 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8.6 Extended Update Support

Via RHSA-2024:0412 https://access.redhat.com/errata/RHSA-2024:0412

Comment 18 errata-xmlrpc 2024-01-30 13:21:04 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8.8 Extended Update Support

Via RHSA-2024:0575 https://access.redhat.com/errata/RHSA-2024:0575

Comment 20 errata-xmlrpc 2024-02-20 12:27:47 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2024:0881 https://access.redhat.com/errata/RHSA-2024:0881

Comment 21 errata-xmlrpc 2024-02-20 12:32:58 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 8

Via RHSA-2024:0897 https://access.redhat.com/errata/RHSA-2024:0897


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