# CVE-2021-4034 (PwnKit)

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.

- Page: https://www.vulneraibility.com/cve/CVE-2021-4034
- CVSS: 7.8
- Known exploited: yes, in CISA KEV since 2022-06-27; CISA due date 2022-07-18; known ransomware use
- EPSS: 94.92% (percentile 99.9)
- Public exploit code: 1 on Exploit-DB · 1 Metasploit module · 184 GitHub proofs of concept (first 2022-01-25)
- CISA SSVC: exploitation active, automatable no, technical impact total (assessed 2022-06-27)
- Weakness: CWE-787
- Published: 2022-01-28

## Affected

- polkit_project:polkit
- redhat:enterprise_linux_server_update_services_for_sap_solutions
- redhat:enterprise_linux
- redhat:enterprise_linux_desktop
- redhat:enterprise_linux_eus
- redhat:enterprise_linux_for_ibm_z_systems
- redhat:enterprise_linux_for_ibm_z_systems_eus
- redhat:enterprise_linux_for_power_big_endian
- redhat:enterprise_linux_for_power_little_endian
- redhat:enterprise_linux_for_power_little_endian_eus
- redhat:enterprise_linux_for_scientific_computing
- redhat:enterprise_linux_server
- redhat:enterprise_linux_server_aus
- redhat:enterprise_linux_server_eus
- redhat:enterprise_linux_server_tus
- redhat:enterprise_linux_workstation
- canonical:ubuntu_linux
- suse:enterprise_storage
- suse:linux_enterprise_high_performance_computing
- suse:manager_proxy
- suse:manager_server
- suse:linux_enterprise_desktop
- suse:linux_enterprise_server
- suse:linux_enterprise_workstation_extension
- oracle:http_server
- oracle:zfs_storage_appliance_kit
- siemens:sinumerik_edge
- siemens:scalance_lpe9403_firmware
- starwindsoftware:command_center
- starwindsoftware:starwind_virtual_san

## References

- [other] https://access.redhat.com/security/vulnerabilities/RHSB-2022-001
- [other] https://www.qualys.com/2022/01/25/cve-2021-4034/pwnkit.txt
- [other] https://bugzilla.redhat.com/show_bug.cgi?id=2025869
- [other] https://gitlab.freedesktop.org/polkit/polkit/-/commit/a2bf5c9c83b6ae46cbd5c779d3055bff81ded683
- [other] https://www.oracle.com/security-alerts/cpuapr2022.html
- [other] http://packetstormsecurity.com/files/166196/Polkit-pkexec-Local-Privilege-Escalation.html
- [other] http://packetstormsecurity.com/files/166200/Polkit-pkexec-Privilege-Escalation.html
- [other] https://www.suse.com/support/kb/doc/?id=000020564
- [other] https://cert-portal.siemens.com/productcert/pdf/ssa-330556.pdf
- [other] https://www.starwindsoftware.com/security/sw-20220818-0001/
- [other] https://www.secpod.com/blog/local-privilege-escalation-vulnerability-in-major-linux-distributions-cve-2021-4034/
- [other] https://www.vicarius.io/vsociety/posts/pwnkit-pkexec-lpe-cve-2021-4034
- [other] https://www.cisa.gov/known-exploited-vulnerabilities-catalog?field_cve=CVE-2021-4034

---
Summary, impact and action are written by the vulneraibility.com AI analysis pipeline from the CVE record, NVD, CISA and FIRST data; verify against the references.
