Connect with us

Hi, what are you looking for?

SecurityWeekSecurityWeek

Vulnerabilities

Polkit Vulnerability Provides Root Privileges on Linux Systems

Qualys security researchers warn of an easily exploitable privilege escalation vulnerability in polkit’s pkexec, a SUID-root program found in all Linux distributions.

Qualys security researchers warn of an easily exploitable privilege escalation vulnerability in polkit’s pkexec, a SUID-root program found in all Linux distributions.

Formerly PolicyKit, Polkit is a component in Unix-like operating systems used to control system-wide privileges, allowing non-privileged processes to communicate with privileged ones. Polkit’s pkexec command can be used to execute commands with root privileges.

The security flaw – which is identified as CVE-2021-4034 and named PwnKit – has been around for more than 12 years, being introduced in pkexec in May 2009. Qualys has verified that default installations of CentOS, Debian, Fedora, and Ubuntu are vulnerable and warns that other Linux distributions might be vulnerable as well.

“Successful exploitation of this vulnerability allows any unprivileged user to gain root privileges on the vulnerable host,” Qualys notes.

The root cause of the issue is an out-of-bounds write that is created when pkexec’s main function processes command-line arguments and attempts to locate the program to be executed.

Because of this out-of-bounds write, an attacker can introduce an “unsecure” variable into pkexec’s environment. However, available options for unsecure variables are limited, because pkexec completely clears its environment shortly after the out-of-bounds write, Qualys says.

The security researchers found one such variable that allowed them to execute arbitrary libraries, which managed to exploit CVE-2021-4034 to execute their own shared library, as root.

Qualys also says the vulnerability is a memory corruption that “is exploitable instantly, reliably, in an architecture-independent way,” even if the polkit daemon is not running. The flaw cannot be exploited remotely, but does allow any unprivileged local user to gain full root privileges.

Advertisement. Scroll to continue reading.

CERT/CC vulnerability analyst Will Dormann noted on Twitter that an exploit released for CVE-2021-4034 is “simple and universal.”

The security hole was reported in November 2021 and a patch was issued on January 11, 2022.

With polkit supported on non-Linux operating systems as well, including Solaris and BSD, the attack surface for this security hole is wide. However Qualys says that OpenBSD is not exploitable.

However, considering the fact that both Linux and non-Linux operating systems are impacted, Qualys recommends applying the available patches for this vulnerability as soon as possible.

Qualys also notes that the exploitation technique they discovered leaves traces in logs, meaning that one can check their environment for potential exploitation attempts.

Related: Linux Foundation Fixes ‘Dangerous’ Code Execution Kernel Bug

Related: GitHub Discloses Details of Easy-to-Exploit Linux Vulnerability

Related: Researcher Finds Vulnerability Impacting Multiple Linux Marketplaces

Written By

Ionut Arghire is an international correspondent for SecurityWeek.

Click to comment

Trending

Daily Briefing Newsletter

Subscribe to the SecurityWeek Email Briefing to stay informed on the latest threats, trends, and technology, along with insightful columns from industry experts.

Join the session as we discuss the challenges and best practices for cybersecurity leaders managing cloud identities.

Register

SecurityWeek’s Ransomware Resilience and Recovery Summit helps businesses to plan, prepare, and recover from a ransomware incident.

Register

People on the Move

Cody Barrow has been appointed as CEO of threat intelligence company EclecticIQ.

Shay Mowlem has been named CMO of runtime and application security company Contrast Security.

Attack detection firm Vectra AI has appointed Jeff Reed to the newly created role of Chief Product Officer.

More People On The Move

Expert Insights

Related Content

Vulnerabilities

Less than a week after announcing that it would suspended service indefinitely due to a conflict with an (at the time) unnamed security researcher...

Data Breaches

OpenAI has confirmed a ChatGPT data breach on the same day a security firm reported seeing the use of a component affected by an...

IoT Security

A group of seven security researchers have discovered numerous vulnerabilities in vehicles from 16 car makers, including bugs that allowed them to control car...

Vulnerabilities

A researcher at IOActive discovered that home security systems from SimpliSafe are plagued by a vulnerability that allows tech savvy burglars to remotely disable...

Risk Management

The supply chain threat is directly linked to attack surface management, but the supply chain must be known and understood before it can be...

Cybercrime

Patch Tuesday: Microsoft calls attention to a series of zero-day remote code execution attacks hitting its Office productivity suite.

Vulnerabilities

Patch Tuesday: Microsoft warns vulnerability (CVE-2023-23397) could lead to exploitation before an email is viewed in the Preview Pane.

IoT Security

A vulnerability affecting Dahua cameras and video recorders can be exploited by threat actors to modify a device’s system time.