cbcvebase.
CVE-2019-6974
published 2019-02-15

CVE-2019-6974: In the Linux kernel before 4.20.8, kvm_ioctl_create_device in virt/kvm/kvm_main.c mishandles reference counting because of a race condition, leading to a…

PriorityP266high8.1CVSS 3.1
AVNACHPRNUINSUCHIHAH
EXPLOIT
EPSS
16.52%
96.7th percentile
In the Linux kernel before 4.20.8, kvm_ioctl_create_device in virt/kvm/kvm_main.c mishandles reference counting because of a race condition, leading to a use-after-free.

Affected

68 ranges· showing 25
VendorProductVersion rangeFixed in
canonicalubuntu_linux
canonicalubuntu_linux
canonicalubuntu_linux
canonicalubuntu_linux
canonicalubuntu_linux
debiandebian_linux
debianlinux< linux 4.19.20-1 (bookworm)linux 4.19.20-1 (bookworm)
f5big-ip_access_policy_manager13.0.0 – 13.1.1
f5big-ip_access_policy_manager14.0.0 – 14.1.0
f5big-ip_access_policy_manager>= 15.0.0 < 15.1.015.1.0
f5big-ip_advanced_firewall_manager13.0.0 – 13.1.1
f5big-ip_advanced_firewall_manager14.0.0 – 14.1.0
f5big-ip_advanced_firewall_manager>= 15.0.0 < 15.1.015.1.0
f5big-ip_analytics13.0.0 – 13.1.1
f5big-ip_analytics14.0.0 – 14.1.0
f5big-ip_analytics>= 15.0.0 < 15.1.015.1.0
f5big-ip_application_acceleration_manager13.0.0 – 13.1.1
f5big-ip_application_acceleration_manager14.0.0 – 14.1.0
f5big-ip_application_acceleration_manager>= 15.0.0 < 15.1.015.1.0
f5big-ip_application_security_manager13.0.0 – 13.1.1
f5big-ip_application_security_manager14.0.0 – 14.1.0
f5big-ip_application_security_manager>= 15.0.0 < 15.1.015.1.0
f5big-ip_edge_gateway13.0.0 – 13.1.1
f5big-ip_edge_gateway14.0.0 – 14.1.0
f5big-ip_edge_gateway>= 15.0.0 < 15.1.015.1.0

Detection & IOCsextracted from sources · hover to see the quote

path/dev/kvm
hashcfa39381173d5f969daf43582c95ad679189cbc9
  • The exploit triggers the race by predicting the file descriptor number and racing a close() call against kvm_ioctl_create_device(). Monitor for rapid repeated close() syscalls on predicted KVM device FDs from the same thread, combined with KVM_CREATE_VM and KVM_CREATE_DEVICE ioctls.
  • The vulnerability is in virt/kvm/kvm_main.c:kvm_ioctl_create_device(). Kernel crash signatures include NULL pointer dereference at address 0x00000000000000a8 in down_write(), or kernel paging request faults in kvm_vm_ioctl(), both triggered by use-after-free of the kvm object.
  • Kernel oops call trace includes kvm_put_kvm, kvm_vm_release, __fput, task_work_run, do_exit — indicating the VM object refcount dropped to zero prematurely due to the race. Alert on kernel oops with this call trace pattern.
  • The exploit can be run in a loop to reliably trigger the crash on unpatched kernels. Monitor for repeated rapid executions of a process issuing KVM_CREATE_VM followed by KVM_CREATE_DEVICE ioctls on /dev/kvm.
  • Affected Linux kernel versions are before 4.20.8. Ensure kernel version is patched; Red Hat Enterprise Linux 7 was confirmed affected while RHEL 5, 6, and MRG 2 were not.
  • ·The race window is narrow and exploitation requires local access to /dev/kvm. The crash may take multiple attempts in a loop to trigger on unpatched kernels without the artificial msleep(100) delay.
  • ·This issue does not affect Red Hat Enterprise Linux 5, 6, or Red Hat Enterprise MRG 2. Only RHEL 7 (and kernels before 4.20.8) are affected.

CVSS provenance

nvdv3.18.1HIGHCVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
nvdv2.06.8MEDIUMAV:N/AC:M/Au:N/C:P/I:P/A:P
osv8.1HIGH
vendor_debian8.1HIGH
vendor_redhat8.1HIGH
vendor_ubuntu7.8HIGH
CVEs like this are exactly what “Exploited This Week” covers.

Every Monday: what got weaponized or added to CISA KEV in the last seven days — each CVE cross-linked to its PoC, Nuclei template, and detection rule. Free, one email a week, unsubscribe in one click.