# CVE-2021-4034: Red Hat Polkit Out-of-Bounds Read and Write Vulnerability

- Severity: High 7.8 (CVSS:3.1, scored by CISA-ADP) `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- Known to be exploited: yes. In CISA's catalogue since 2022-06-27; used in ransomware campaigns. Apply updates per vendor instructions.
- Likelihood of exploitation in the next 30 days (EPSS): 94.9%, higher than 99% of CVEs (2026-12-01)
- Public exploit code or proof of concept: 5 links below, marked "exploit"
- Published: 2022-01-28T00:00:00.000Z
- Modified: 2026-08-15T04:17:57.927Z
- Weaknesses: CWE-125, CWE-787
- SSVC (CISA-ADP): exploitation active, automatable no, technical impact total
- Assigned by: redhat

## Description

A local privilege escalation vulnerability was found on polkit's pkexec utility. The pkexec application is a setuid tool designed to allow unprivileged users to run commands as privileged users according predefined policies. The current version of pkexec doesn't handle the calling parameters count correctly and ends trying to execute environment variables as commands. An attacker can leverage this by crafting environment variables in such a way it'll induce pkexec to execute arbitrary code. When successfully executed the attack can cause a local privilege escalation given unprivileged users administrative rights on the target machine.

(As written by CVE List.)

## Affected

- polkit: all
- polkit_project polkit: before 121
- redhat enterprise_linux_server_update_services_for_sap_solutions: 7.6; 7.7; 8.1; 8.2; 8.4
- redhat enterprise_linux: 8.0
- redhat enterprise_linux_desktop: 7.0
- redhat enterprise_linux_eus: 8.2
- redhat enterprise_linux_for_ibm_z_systems: 7.0; 8.0
- redhat enterprise_linux_for_ibm_z_systems_eus: 8.2; 8.4
- redhat enterprise_linux_for_power_big_endian: 7.0
- redhat enterprise_linux_for_power_little_endian: 7.0; 8.0
- redhat enterprise_linux_for_power_little_endian_eus: 8.1; 8.2; 8.4
- redhat enterprise_linux_for_scientific_computing: 7.0
- redhat enterprise_linux_server: 6.0; 7.0
- redhat enterprise_linux_server_aus: 7.3; 7.4; 7.6; 7.7; 8.2; 8.4
- redhat enterprise_linux_server_eus: 8.4
- redhat enterprise_linux_server_tus: 7.6; 7.7; 8.2; 8.4
- redhat enterprise_linux_workstation: 7.0
- canonical ubuntu_linux: 14.04; 16.04; 18.04; 20.04; 21.10
- suse enterprise_storage: 7.0
- suse linux_enterprise_high_performance_computing: 15.0
- suse manager_proxy: 4.1
- suse manager_server: 4.1
- suse linux_enterprise_desktop: 15
- suse linux_enterprise_server: 15
- suse linux_enterprise_workstation_extension: 12
- oracle http_server: 12.2.1.3.0; 12.2.1.4.0
- oracle zfs_storage_appliance_kit: 8.8
- siemens sinumerik_edge: before 3.3.0
- siemens scalance_lpe9403_firmware: before 2.0
- starwindsoftware command_center: 1.0
- starwindsoftware starwind_virtual_san: v8
- Red Hat Polkit: no versions given

## Every score

- CISA-ADP: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:3.1 7.8 High `CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- NVD: CVSS:2.0 7.2 High `AV:L/AC:L/Au:N/C:C/I:C/A:C`

## References

- <https://www.qualys.com/2022/01/25/cve-2021-4034/pwnkit.txt> (exploit, mitigation, third-party-advisory)
- <http://packetstormsecurity.com/files/166196/Polkit-pkexec-Local-Privilege-Escalation.html> (exploit, third-party-advisory, vdb-entry)
- <http://packetstormsecurity.com/files/166200/Polkit-pkexec-Privilege-Escalation.html> (exploit, third-party-advisory, vdb-entry)
- <https://www.secpod.com/blog/local-privilege-escalation-vulnerability-in-major-linux-distributions-cve-2021-4034/> (exploit, third-party-advisory)
- <https://www.vicarius.io/vsociety/posts/pwnkit-pkexec-lpe-cve-2021-4034> (exploit, third-party-advisory)
- <https://access.redhat.com/security/vulnerabilities/RHSB-2022-001> (mitigation, vendor-advisory)
- <https://bugzilla.redhat.com/show_bug.cgi?id=2025869> (issue-tracking, patch)
- <https://gitlab.freedesktop.org/polkit/polkit/-/commit/a2bf5c9c83b6ae46cbd5c779d3055bff81ded683> (patch)
- <https://www.oracle.com/security-alerts/cpuapr2022.html> (patch, third-party-advisory)
- <https://www.suse.com/support/kb/doc/?id=000020564> (third-party-advisory)
- <https://cert-portal.siemens.com/productcert/pdf/ssa-330556.pdf> (third-party-advisory)
- <https://www.starwindsoftware.com/security/sw-20220818-0001/> (third-party-advisory)
- <https://www.cisa.gov/known-exploited-vulnerabilities-catalog?field_cve=CVE-2021-4034> (government-resource, us-government-resource)
- <https://nvd.nist.gov/vuln/detail/CVE-2021-4034> (kev)

## Sources

- CVE List: [CVE-2021-4034](https://www.cve.org/CVERecord?id=CVE-2021-4034), CVE Terms of Use, modified 2026-08-15
- NVD: [CVE-2021-4034](https://nvd.nist.gov/vuln/detail/CVE-2021-4034), Public domain, modified 2026-08-15
- CISA KEV: [CVE-2021-4034](https://www.cisa.gov/known-exploited-vulnerabilities-catalog?search_api_fulltext=CVE-2021-4034), CC0-1.0, modified 2022-06-27

---

Page: https://cve.day/CVE-2021-4034 · Whole record: https://cve.day/CVE-2021-4034.json · Rebuilt by cve.day 2026-11-25T22:58:06.717Z
