7.8
CWE
416
Advisory Published
Updated

CVE-2022-42332: Use After Free

First published: Tue Mar 21 2023(Updated: )

x86 shadow plus log-dirty mode use-after-free In environments where host assisted address translation is necessary but Hardware Assisted Paging (HAP) is unavailable, Xen will run guests in so called shadow mode. Shadow mode maintains a pool of memory used for both shadow page tables as well as auxiliary data structures. To migrate or snapshot guests, Xen additionally runs them in so called log-dirty mode. The data structures needed by the log-dirty tracking are part of aformentioned auxiliary data. In order to keep error handling efforts within reasonable bounds, for operations which may require memory allocations shadow mode logic ensures up front that enough memory is available for the worst case requirements. Unfortunately, while page table memory is properly accounted for on the code path requiring the potential establishing of new shadows, demands by the log-dirty infrastructure were not taken into consideration. As a result, just established shadow page tables could be freed again immediately, while other code is still accessing them on the assumption that they would remain allocated.

Credit: security@xen.org security@xen.org

Affected SoftwareAffected VersionHow to fix
debian/xen<=4.11.4+107-gef32c7afa2-1
4.14.6-1
4.14.5+94-ge49571868d-1
4.17.1+2-gb773c48e36-1
4.17.2+55-g0b56bed864-1
Xen Xen>=3.2.0
Debian Debian Linux=11.0
Fedoraproject Fedora=37
Fedoraproject Fedora=38

Never miss a vulnerability like this again

Sign up to SecAlerts for real-time vulnerability data matched to your software, aggregated from hundreds of sources.

Frequently Asked Questions

  • What is CVE-2022-42332?

    CVE-2022-42332 is a vulnerability in Xen that allows a use-after-free condition in environments where host assisted address translation is necessary but Hardware Assisted Paging (HAP) is unavailable.

  • How does Xen handle guests in shadow mode?

    Xen runs guests in shadow mode, which maintains a pool of memory used for shadow page tables as well as auxiliary data structures.

  • Which software versions are affected by CVE-2022-42332?

    Xen versions 4.14.6-1, 4.14.5+94-ge49571868d-1, 4.17.1+2-gb773c48e36-1, 4.17.2+55-g0b56bed864-1, and up to inclusive version 4.11.4+107-gef32c7afa2-1 are affected.

  • Is Xen affected in all environments?

    No, Xen is only affected in environments where host assisted address translation is necessary but Hardware Assisted Paging (HAP) is unavailable.

  • Where can I find more information about CVE-2022-42332?

    You can find more information about CVE-2022-42332 at the following references: [Openwall](https://www.openwall.com/lists/oss-security/2023/03/21/1), [Xen](https://xenbits.xen.org/xsa/advisory-427.html), [Debian Security Tracker](https://security-tracker.debian.org/tracker/CVE-2022-42332).

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2024 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203