A use-after-free flaw was found in libvirt. The qemuMonitorUnregister() function in qemuProcessHandleMonitorEOF is called using multiple threads without being adequately protected by a monitor lock. This flaw could be triggered by the virConnectGetAllDomainStats API when the guest is shutting down. An unprivileged client with a read-only connection could use this flaw to perform a denial of service attack by causing the libvirt daemon to crash.
[ { "signature_type": "Line", "target": { "file": "src/qemu/qemu_process.c" }, "source": "https://github.com/libvirt/libvirt/commit/1ac703a7d0789e46833f4013a3876c2e3af18ec7", "digest": { "threshold": 0.9, "line_hashes": [ "315265246104295043233028789217389565548", "105764427624893722313441396925088733050", "286241987283172516990844761613712295006", "197158705559895140885010290749044057343" ] }, "deprecated": false, "id": "CVE-2021-3975-12a0a0d2", "signature_version": "v1" }, { "signature_type": "Function", "target": { "function": "qemuProcessHandleMonitorEOF", "file": "src/qemu/qemu_process.c" }, "source": "https://github.com/libvirt/libvirt/commit/1ac703a7d0789e46833f4013a3876c2e3af18ec7", "digest": { "function_hash": "230318565073693938830034361256505555002", "length": 654.0 }, "deprecated": false, "id": "CVE-2021-3975-57583cdb", "signature_version": "v1" } ]