CVE-2018-18021: Input Validation

Published Oct 3, 2018
·
Updated

arch/arm64/kvm/guest.c in KVM in the Linux kernel before 4.18.12 on the arm64 platform mishandles the KVMSETONREG ioctl. This is exploitable by attackers who can create virtual machines. An attacker can arbitrarily redirect the hypervisor flow of control (with full register control). An attacker can also cause a denial of service (hypervisor panic) via an illegal exception return. This occurs because of insufficient restrictions on userspace access to the core register file, and because PSTATE.M validation does not prevent unintended execution modes.

Other sources

The Linux kernel has vulnerability on 64-bit ARM architectures that allows an attacker to escalate privileges. A local attacker with permission to create KVM-based virtual machines can both panic the hypervisor by triggering an illegal exception return (resulting in a DoS) and to redirect execution elsewhere within the hypervisor with full register control, instead of causing a return to the guest.

Reference:

https://www.openwall.com/lists/oss-security/2018/10/02/2

Proposed Upstream Patches:

https://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git/commit/?id=d26c25a9 https://git.kernel.org/pub/scm/linux/kernel/git/arm64/linux.git/commit/?id=2a3f9345

— Red Hat

Affected Software

29 affected componentsFixes available
Linux Linux kernel<4.18.12
Debian Debian Linux=9.0
Canonical Ubuntu Linux=14.04
Canonical Ubuntu Linux=16.04
ubuntu/linux-lts-xenial<4.4.0-139.165~14.04.1
4.4.0-139.165~14.04.1
ubuntu/linux*
ubuntu/linux<4.4.0-139.165
4.4.0-139.165
ubuntu/linux-aws-hwe<4.15.0-1035.37~16.04.1
4.15.0-1035.37~16.04.1
ubuntu/linux-hwe<4.15.0-47.50~16.04.1
4.15.0-47.50~16.04.1
ubuntu/linux-oracle<4.15.0-1010.12~16.04.1
4.15.0-1010.12~16.04.1
ubuntu/linux-raspi2<4.4.0-1100.108
4.4.0-1100.108
ubuntu/linux-snapdragon<4.4.0-1104.109
4.4.0-1104.109
ubuntu/linux-fips<4.4.0-1008.10
4.4.0-1008.10
ubuntu/linux<4.15.0-47.50
4.15.0-47.50
ubuntu/linux-oracle<4.15.0-1010.12
4.15.0-1010.12
ubuntu/linux-raspi2<4.15.0-1033.35
4.15.0-1033.35
ubuntu/linux-azure-fde*
ubuntu/linux-gke*
ubuntu/linux-raspi2*
ubuntu/linux-riscv*
ubuntu/linux-intel-iot-realtime*
ubuntu/linux-realtime*
ubuntu/linux-riscv*
ubuntu/linux-azure-6.11*
ubuntu/linux-gcp-6.11*
ubuntu/linux-hwe-6.11*
ubuntu/linux-lowlatency-hwe-6.11*
ubuntu/linux-raspi-realtime*
debian/linux
6.1.176-16.1.190-16.12.107-16.12.116-17.2.15-17.3.4-1

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade ubuntu/linux-lts-xenial to a version that resolves this vulnerability.

    Fixed in 4.4.0-139.165~14.04.1
  2. Upgrade

    Upgrade ubuntu/linux to a version that resolves this vulnerability.

    Fixed in 4.4.0-139.165
  3. Upgrade

    Upgrade ubuntu/linux-aws-hwe to a version that resolves this vulnerability.

    Fixed in 4.15.0-1035.37~16.04.1
  4. Upgrade

    Upgrade ubuntu/linux-hwe to a version that resolves this vulnerability.

    Fixed in 4.15.0-47.50~16.04.1
  5. Upgrade

    Upgrade ubuntu/linux-oracle to a version that resolves this vulnerability.

    Fixed in 4.15.0-1010.12~16.04.1
  6. Upgrade

    Upgrade ubuntu/linux-raspi2 to a version that resolves this vulnerability.

    Fixed in 4.4.0-1100.108
  7. Upgrade

    Upgrade ubuntu/linux-snapdragon to a version that resolves this vulnerability.

    Fixed in 4.4.0-1104.109
  8. Upgrade

    Upgrade ubuntu/linux-fips to a version that resolves this vulnerability.

    Fixed in 4.4.0-1008.10
  9. Upgrade

    Upgrade ubuntu/linux to a version that resolves this vulnerability.

    Fixed in 4.15.0-47.50
  10. Upgrade

    Upgrade ubuntu/linux-oracle to a version that resolves this vulnerability.

    Fixed in 4.15.0-1010.12
  11. Upgrade

    Upgrade ubuntu/linux-raspi2 to a version that resolves this vulnerability.

    Fixed in 4.15.0-1033.35
  12. Upgrade

    Upgrade debian/linux to a version that resolves this vulnerability.

    Fixed in 6.1.176-1Fixed in 6.1.190-1Fixed in 6.12.107-1Fixed in 6.12.116-1Fixed in 7.2.15-1Fixed in 7.3.4-1
  13. Upgrade

    Upgrade Linux kernel KVM on arm64 to a version that resolves this vulnerability.

    Fixed in 4.18.12

Event History

Oct 3, 2018
Data Sourced
via Red Hat·03:55 AM
DescriptionSeverityAffected Software
Oct 7, 2018
CVE Published
via OSV·12:00 AM
Data Sourced
via OSV·12:00 AM
DescriptionSeverityAffected Software
Data Sourced
via Ubuntu·12:00 AM
RemedyDescriptionSeverityAffected Software
CVE Published
via MITRE·06:00 AM
Data Sourced
via MITRE·06:00 AM
Description
Data Sourced
via NVD·06:29 AM
RemedyDescriptionSeverityWeaknessAffected Software

Parent advisories

This vulnerability appears in the following advisories.

Peer vulnerabilities

Found alongside the following vulnerabilities.

Frequently Asked Questions

1

What is the severity of CVE-2018-18021?

The severity of CVE-2018-18021 is high with a severity value of 7.

2

How does CVE-2018-18021 affect the Linux kernel?

CVE-2018-18021 affects the Linux kernel before version 4.18.12 on the arm64 platform.

3

What is the vulnerability in CVE-2018-18021?

The vulnerability in CVE-2018-18021 is a mishandling of the KVM_SET_ON_REG ioctl in KVM in the Linux kernel.

4

Who is affected by CVE-2018-18021?

Users of the Linux kernel before version 4.18.12 on the arm64 platform are affected by CVE-2018-18021.

5

How can CVE-2018-18021 be fixed?

To fix CVE-2018-18021, users should update to Linux kernel version 4.18.12 or higher.

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.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203