2022-01-26
12 Year-Old Bug in Polkit Allows for Privilege Elevation
Researchers from Qualys identified a flaw in Polkit’s pkexec dating back to 2009. The memory-corruption vulnerability, dubbed PwnKit, allows a user with access to a vulnerable machine to elevate to root privileges. Discovered in November, tracked as CVE-2021-4034, patches have been released. Polkit, previously known as PolicyKit manages privileges in most Unix/Linux distributions, managing access to privileged processes from unmanaged processes.
Editor's Note
Patches should be available for all major Linux distributions, and the patch does not require a reboot. Privilege escalation vulnerabilities are often assigned a lower urgency. But this vulnerability is easy to exploit, and some of the exploits publicly available will not leave a mark in your logs.

Johannes Ullrich
Updates to Polkit have been released for RedHat/CentOS and other Linux distributions and are available through you regular repositories. IF you cannot patch, remove the set UID root permission from pkexec. (e.g., chmod 755 /bin/pkexec). Exploitation can be detected by looking for log entries, see the Qualys blog for examples; however, it is possible to exploit the flaw without leaving any traces in system logs.

Lee Neely
Unix/Linux escalation of privilege vulnerabilities linger around for a significant amount of time since they are “only” privilege escalation and lower CVSSv3 score. Make the effort to get your systems patched for this vulnerability that is trivially exploited.

Jorge Orchilles
This bug is fascinating to me for several reasons. First, it indicates to researchers that other SUID binaries may have a similar issue, so I suspect we may see more of these. Second, this bug is dead simple to exploit. Almost all the POC's available were written based on the initial writeup. It also does not deal with any type of ASLR or memory corruption bug in this exploit, so this universally works everywhere regardless of kernel or distribution version. Patch it now.

Moses Frost
Read more in
Qualys: PwnKit: Local Privilege Escalation Vulnerability Discovered in polkit’s pkexec (CVE-2021-4034)
The Register: Linux distros haunted by Polkit-geist for 12+ years: Bug grants root access to any user
Ars Technica: A bug lurking for 12 years gives attackers root on most major Linux distros
VentureBeat: Linux vulnerability can be ‘easily exploited’ for local privilege escalation, researchers say
Dark Reading: Experts Urge Firms to Patch Trivial-to-Exploit Flaw in Linux PolicyKit
Threatpost: Linux Bug in All Major Distros: ‘An Attacker’s Dream Come True’