CVE-2020-27170: Infoleak

Published Mar 18, 2021
·
Updated

A flaw was found in the Linux kernels eBPF verification code. By default accessing the eBPF verifier is only accessible to privileged users with CAPSYSADMIN. A local user with the ability to insert eBPF instructions can use the eBPF verifier to abuse a spectre like flaw where they can infer all system memory.

Other sources

An issue was discovered in the Linux kernel before 5.11.8. kernel/bpf/verifier.c performs undesirable out-of-bounds speculation on pointer arithmetic, leading to side-channel attacks that defeat Spectre mitigations and obtain sensitive information from kernel memory, aka CID-f232326f6966. This affects pointer types that do not define a ptrlimit.

Linux Kernel could allow a local authenticated attacker to obtain sensitive information, caused by an out-of-bounds loads flaw. By executing specially-crafted BPF programs, an attacker could exploit this vulnerability to obtain contents of kernel memory, and use this information to launch further attacks against the affected system.

— IBM

Speculation on pointer arithmetic against bpfcontext pointer allows unprivileged local users to leak content of kernel memory.

Bug Fix

The minimal fix is:

bpf: Prohibit alu ops for pointer types not defining ptrlimit [ https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf.git/patch/?id=f232326f6966cf2a1d1db7bc917a4ce5f9f55f76 ]

However it is recommended to use the whole series that also includes fix for another similar vulnerability reported at the same time and improvements of the affected code:

bpf: Prohibit alu ops for pointer types not defining ptrlimit [ https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf.git/patch/?id=f232326f6966cf2a1d1db7bc917a4ce5f9f55f76 ] bpf: Fix off-by-one for area size in creating mask to left [ https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf.git/patch/?id=10d2bb2e6b1d8c4576c56a748f697dbeb8388899 ] bpf: Simplify alulimit masking for pointer arithmetic [ https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf.git/patch/?id=b5871dca250cd391885218b99cc015aca1a51aea ] bpf: Add sanity check for upper ptrlimit [ https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf.git/patch/?id=1b1597e64e1a610c7a96710fc4717158e98a08b3 ] bpf, selftests: Fix up some testverifier cases for unprivileged [ https://git.kernel.org/pub/scm/linux/kernel/git/bpf/bpf.git/patch/?id=0a13e3537ea67452d549a6a80da3776d6b7dedb3 ]

— Red Hat

Affected Software

93 affected componentsFixes available
redhat/kernel-rt<0:3.10.0-1160.31.1.rt56.1169.el7
0:3.10.0-1160.31.1.rt56.1169.el7
redhat/kernel<0:3.10.0-1160.31.1.el7
0:3.10.0-1160.31.1.el7
IBM DRM<=2.0.6
Linux Linux kernel<5.11.8
Fedoraproject Fedora=32
Fedoraproject Fedora=33
Fedoraproject Fedora=34
Canonical Ubuntu Linux=14.04
Canonical Ubuntu Linux=16.04
Canonical Ubuntu Linux=18.04
Canonical Ubuntu Linux=20.04
Debian Debian Linux=9.0
debian/linux
5.10.223-15.10.234-16.1.129-16.1.135-16.12.22-16.12.25-1
android/:linux_kernel:>=:0<:2021-07-05
:2021-07-05
ubuntu/linux-azure<4.15.0-1111.123~14.04.1
4.15.0-1111.123~14.04.1
ubuntu/linux-aws*
ubuntu/linux-lts-xenial*
ubuntu/linux-aws-hwe<4.15.0-1097.104~16.04.1
4.15.0-1097.104~16.04.1
ubuntu/linux-azure<4.15.0-1111.123~16.04.1
4.15.0-1111.123~16.04.1
ubuntu/linux-gcp<4.15.0-1096.109~16.04.1
4.15.0-1096.109~16.04.1
ubuntu/linux-hwe<4.15.0-140.144~16.04.1
4.15.0-140.144~16.04.1
ubuntu/linux-oracle<4.15.0-1068.76~16.04.1
4.15.0-1068.76~16.04.1
ubuntu/linux*
ubuntu/linux-aws*
ubuntu/linux-hwe-edge*
ubuntu/linux-kvm*
ubuntu/linux-fips*
ubuntu/linux-fips*
ubuntu/linux<4.15.0-140.144
4.15.0-140.144
ubuntu/linux-aws<4.15.0-1097.104
4.15.0-1097.104
ubuntu/linux-aws-5.4<5.4.0-1041.43~18.04.1
5.4.0-1041.43~18.04.1
ubuntu/linux-azure-4.15<4.15.0-1111.123
4.15.0-1111.123
ubuntu/linux-azure-5.4<5.4.0-1043.45~18.04.1
5.4.0-1043.45~18.04.1
ubuntu/linux-dell300x<4.15.0-1015.19
4.15.0-1015.19
ubuntu/linux-gcp-4.15<4.15.0-1096.109
4.15.0-1096.109
ubuntu/linux-gcp-5.4<5.4.0-1040.43~18.04.1
5.4.0-1040.43~18.04.1
ubuntu/linux-gke-5.3<5.3.0-1041.44
5.3.0-1041.44
ubuntu/linux-gke-5.4<5.4.0-1039.41~18.04.1
5.4.0-1039.41~18.04.1
ubuntu/linux-gkeop-5.4<5.4.0-1012.13~18.04.1
5.4.0-1012.13~18.04.1
ubuntu/linux-hwe<5.3.0-72.68
5.3.0-72.68
ubuntu/linux-hwe-5.4<5.4.0-70.78~18.04.1
5.4.0-70.78~18.04.1
ubuntu/linux-kvm<4.15.0-1088.90
4.15.0-1088.90
ubuntu/linux-oracle<4.15.0-1068.76
4.15.0-1068.76
ubuntu/linux-oracle-5.4<5.4.0-1041.44~18.04.1
5.4.0-1041.44~18.04.1
ubuntu/linux-raspi-5.4<5.4.0-1032.35~18.04.1
5.4.0-1032.35~18.04.1
ubuntu/linux-raspi2<4.15.0-1082.87
4.15.0-1082.87
ubuntu/linux-raspi2-5.3<5.3.0-1038.40
5.3.0-1038.40
ubuntu/linux-snapdragon<4.15.0-1099.108
4.15.0-1099.108
ubuntu/linux-aws-5.0*
ubuntu/linux-aws-5.3*
ubuntu/linux-azure*
ubuntu/linux-azure-5.3*
ubuntu/linux-azure-edge*
ubuntu/linux-gcp*
ubuntu/linux-gcp-5.3*
ubuntu/linux-gcp-edge*
ubuntu/linux-gke-4.15*
ubuntu/linux-hwe-edge*
ubuntu/linux-oem*
ubuntu/linux-oracle-5.0*
ubuntu/linux-oracle-5.3*
ubuntu/linux-aws-fips<4.15.0-2040.42
4.15.0-2040.42
ubuntu/linux-azure-fips<4.15.0-2023.26
4.15.0-2023.26
ubuntu/linux-fips<4.15.0-1056.64
4.15.0-1056.64
ubuntu/linux-aws-fips*
ubuntu/linux-azure-fips*
ubuntu/linux-fips*
ubuntu/linux-gcp-fips*
ubuntu/linux<5.4.0-70.78
5.4.0-70.78
ubuntu/linux-aws<5.4.0-1041.43
5.4.0-1041.43
ubuntu/linux-azure<5.4.0-1043.45
5.4.0-1043.45
ubuntu/linux-gcp<5.4.0-1040.43
5.4.0-1040.43
ubuntu/linux-gke<5.4.0-1039.41
5.4.0-1039.41
ubuntu/linux-gkeop<5.4.0-1012.13
5.4.0-1012.13
ubuntu/linux-hwe-5.8<5.8.0-48.54~20.04.1
5.8.0-48.54~20.04.1
ubuntu/linux-kvm<5.4.0-1036.37
5.4.0-1036.37
ubuntu/linux-oem-5.10<5.10.0-1019.20
5.10.0-1019.20
ubuntu/linux-oem-5.6<5.6.0-1052.56
5.6.0-1052.56
ubuntu/linux-oracle<5.4.0-1041.44
5.4.0-1041.44
ubuntu/linux-raspi<5.4.0-1032.35
5.4.0-1032.35
ubuntu/linux-riscv-5.8<5.8.0-20.22~20.04.1
5.8.0-20.22~20.04.1
ubuntu/linux-raspi2*
ubuntu/linux-riscv*
ubuntu/linux-aws-fips<5.4.0-1069.73+fips2
5.4.0-1069.73+fips2
ubuntu/linux-azure-fips<5.4.0-1073.76+fips1
5.4.0-1073.76+fips1
ubuntu/linux-gcp-fips<5.4.0-1067.71~20.04.1
5.4.0-1067.71~20.04.1
ubuntu/linux-aws-fips*
ubuntu/linux-azure-fips*
ubuntu/linux-gcp-fips*
ubuntu/linux-intel-iot-realtime*
ubuntu/linux-realtime*
ubuntu/linux-raspi-realtime*
ubuntu/linux-vmware*

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade redhat/kernel-rt to a version that resolves this vulnerability.

    Fixed in 0:3.10.0-1160.31.1.rt56.1169.el7
  2. Upgrade

    Upgrade redhat/kernel to a version that resolves this vulnerability.

    Fixed in 0:3.10.0-1160.31.1.el7
  3. Upgrade

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

    Fixed in 5.10.223-1Fixed in 5.10.234-1Fixed in 6.1.129-1Fixed in 6.1.135-1Fixed in 6.12.22-1Fixed in 6.12.25-1
  4. Upgrade

    Upgrade android/:linux_kernel: to a version that resolves this vulnerability.

    Fixed in :2021-07-05
  5. Upgrade

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

    Fixed in 4.15.0-1111.123~14.04.1
  6. Upgrade

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

    Fixed in 4.15.0-1097.104~16.04.1
  7. Upgrade

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

    Fixed in 4.15.0-1111.123~16.04.1
  8. Upgrade

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

    Fixed in 4.15.0-1096.109~16.04.1
  9. Upgrade

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

    Fixed in 4.15.0-140.144~16.04.1
  10. Upgrade

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

    Fixed in 4.15.0-1068.76~16.04.1
  11. Upgrade

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

    Fixed in 4.15.0-140.144
  12. Upgrade

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

    Fixed in 4.15.0-1097.104
  13. Upgrade

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

    Fixed in 5.4.0-1041.43~18.04.1
  14. Upgrade

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

    Fixed in 4.15.0-1111.123
  15. Upgrade

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

    Fixed in 5.4.0-1043.45~18.04.1
  16. Upgrade

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

    Fixed in 4.15.0-1015.19
  17. Upgrade

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

    Fixed in 4.15.0-1096.109
  18. Upgrade

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

    Fixed in 5.4.0-1040.43~18.04.1
  19. Upgrade

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

    Fixed in 5.3.0-1041.44
  20. Upgrade

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

    Fixed in 5.4.0-1039.41~18.04.1
  21. Upgrade

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

    Fixed in 5.4.0-1012.13~18.04.1
  22. Upgrade

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

    Fixed in 5.3.0-72.68
  23. Upgrade

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

    Fixed in 5.4.0-70.78~18.04.1
  24. Upgrade

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

    Fixed in 4.15.0-1088.90
  25. Upgrade

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

    Fixed in 4.15.0-1068.76
  26. Upgrade

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

    Fixed in 5.4.0-1041.44~18.04.1
  27. Upgrade

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

    Fixed in 5.4.0-1032.35~18.04.1
  28. Upgrade

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

    Fixed in 4.15.0-1082.87
  29. Upgrade

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

    Fixed in 5.3.0-1038.40
  30. Upgrade

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

    Fixed in 4.15.0-1099.108
  31. Upgrade

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

    Fixed in 4.15.0-2040.42
  32. Upgrade

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

    Fixed in 4.15.0-2023.26
  33. Upgrade

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

    Fixed in 4.15.0-1056.64
  34. Upgrade

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

    Fixed in 5.4.0-70.78
  35. Upgrade

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

    Fixed in 5.4.0-1041.43
  36. Upgrade

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

    Fixed in 5.4.0-1043.45
  37. Upgrade

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

    Fixed in 5.4.0-1040.43
  38. Upgrade

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

    Fixed in 5.4.0-1039.41
  39. Upgrade

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

    Fixed in 5.4.0-1012.13
  40. Upgrade

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

    Fixed in 5.8.0-48.54~20.04.1
  41. Upgrade

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

    Fixed in 5.4.0-1036.37
  42. Upgrade

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

    Fixed in 5.10.0-1019.20
  43. Upgrade

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

    Fixed in 5.6.0-1052.56
  44. Upgrade

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

    Fixed in 5.4.0-1041.44
  45. Upgrade

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

    Fixed in 5.4.0-1032.35
  46. Upgrade

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

    Fixed in 5.8.0-20.22~20.04.1
  47. Upgrade

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

    Fixed in 5.4.0-1069.73+fips2
  48. Upgrade

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

    Fixed in 5.4.0-1073.76+fips1
  49. Upgrade

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

    Fixed in 5.4.0-1067.71~20.04.1
  50. Upgrade

    Upgrade Linux kernel to a version that resolves this vulnerability.

    Fixed in 5.11.8
  51. Configuration

    Set kernel.unprivileged_bpf_disabled to 1 to prevent unprivileged users from using eBPF.

    Linux kernel kernel.unprivileged_bpf_disabled = 1

Event History

Mar 18, 2021
CVE Published
12:00 AM
Data Sourced
12:00 AM
RemedyDescriptionSeverityAffected Software
Updated
via Ubuntu·12:00 AM
Affected Software
Updated
via Ubuntu·12:00 AM
RemedyDescriptionAffected Software
Updated
via Ubuntu·12:00 AM
Description
Data Sourced
via OSV·10:00 PM
DescriptionSeverityAffected Software
Mar 19, 2021
Data Sourced
12:00 AM
Weakness
Event
12:00 AM
Mar 20, 2021
CVE Published
via MITRE·09:30 PM
Data Sourced
via MITRE·09:30 PM
Description
Jul 1, 2021
Advisory Published
via OSV·12:00 AM
Oct 11, 2021
Data Sourced
via IBM·12:00 AM
DescriptionSeverityAffected Software
May 5, 2022
Data Sourced
via Red Hat·02:01 PM
DescriptionSeverityAffected Software
Nov 7, 2023
Data Sourced
via NVD·03:20 AM
RemedyDescriptionSeverityWeaknessAffected Software
Updated
03:20 AM
Affected Software
Nov 21, 2024
Updated
via NVD·05:20 AM
RemedyAffected Software
Oct 8, 2026
Updated
via NVD·09:17 PM
Affected Software
Nov 11, 2026
Updated
via OSV·09:35 AM
Affected Software
Nov 12, 2026
Updated
via OSV·05:22 PM
Affected Software

Parent advisories

This vulnerability appears in the following advisories.

Frequently Asked Questions

1

What is the severity of CVE-2020-27170?

The severity of CVE-2020-27170 is classified as medium.

2

How do I fix CVE-2020-27170?

To fix CVE-2020-27170, update to the latest kernel version that contains the patch for this vulnerability.

3

Which Linux kernel versions are affected by CVE-2020-27170?

CVE-2020-27170 affects Linux kernel versions prior to 5.11.8.

4

Is CVE-2020-27170 exploitable remotely?

CVE-2020-27170 is a local vulnerability and cannot be exploited remotely.

5

What types of systems are impacted by CVE-2020-27170?

CVE-2020-27170 impacts systems running affected versions of the Linux kernel and certain distributions like Red Hat, Ubuntu, and Debian.

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