Security Experts:

Connect with us

Hi, what are you looking for?


Endpoint Security

‘DirtyCred’ Vulnerability Haunting Linux Kernel for 8 Years

Academic researchers from Northwestern University have shared details on ‘DirtyCred’, a previously unknown privilege escalation vulnerability affecting the Linux kernel.

Academic researchers from Northwestern University have shared details on ‘DirtyCred’, a previously unknown privilege escalation vulnerability affecting the Linux kernel.

Tracked as CVE-2022-2588, the security flaw can be exploited to escalate privileges, and can also lead to a container escape. The academics say the vulnerability has been present in Linux for eight years.

Described as a use-after-free in the cls_route filter implementation of the Linux kernel, the bug exists because an old filter is not removed from the hashtable before it is freed. The issue can be exploited by a local user with the CAP_NET_ADMIN capability and could lead to a system crash or arbitrary code execution.

PhD students Zhenpeng Lin and Yuhang Wu, and associate professor Xinyu Xing explained earlier this month during the Black Hat conference that the issue is similar to the Dirty Pipe vulnerability (CVE-2022-0847) impacting Linux kernel versions 5.8 and later.

What made Dirty Pipe reputable was its easy exploitation despite protections such as kernel address randomization and pointer integrity check, coupled with the fact that it could be exploited without modifications on all impacted kernel versions.

The academics claim that the DirtyCred exploitation method surpasses limitations of Dirty Pipe, which uses the Linux kernel’s pipe mechanism for injecting data into arbitrary files.

“We argue that our new exploitation method is not only more general than the dirty pipe but also more powerful. First, rather than tying to a specific vulnerability, this exploitation method allows any vulnerabilities with double-free ability to demonstrate dirty-pipe-like ability,” the academics say.

The new attack relies on the dirty-pipe-like ability to overwrite any file with read permission, in order to escalate privileges on the system.

“DirtyCred is a kernel exploitation concept that swaps unprivileged kernel credentials with privileged ones to escalate privilege. Instead of overwriting any critical data fields on kernel heap, DirtyCred abuses the heap memory reuse mechanism to get privileged. Although the concept is simple, it is effective,” the researchers say.

Basically, the attacker needs to free an in-use unprivileged credential in memory, allocate privileged credentials to the free slot, and then operate as the privileged user – which will require stabilizing file exploitations, the researchers say.

The DirtyCred exploit works without modifications across different kernels and architectures and there are no mitigations available for it as of now, according to the academics, who demonstrated their exploit on both Linux and Android.

One possible defense against DirtyCred, the researchers note, involves isolating privileged credentials from unprivileged ones in virtual memory.

DirtyCred and Dirty Pipe are similar to Dirty Cow (CVE-2016-5195), a Linux kernel vulnerability allowing local attackers to escalate privileges by modifying existing ‘setuid’ files.

Related: Google Boosts Bug Bounty Rewards for Linux Kernel Vulnerabilities

Related: DoS Vulnerabilities Impact Linux Kernel

Related: Two-Year Old Vulnerability Patched in Linux Kernel

Written By

Ionut Arghire is an international correspondent for SecurityWeek.

Click to comment

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 this webinar to learn best practices that organizations can use to improve both their resilience to new threats and their response times to incidents.


Join this live webinar as we explore the potential security threats that can arise when third parties are granted access to a sensitive data or systems.


Expert Insights

Related Content


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

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...


Apple has released updates for macOS, iOS and Safari and they all include a WebKit patch for a zero-day vulnerability tracked as CVE-2023-23529.

Application Security

Drupal released updates that resolve four vulnerabilities in Drupal core and three plugins.

Cloud Security

VMware vRealize Log Insight vulnerability allows an unauthenticated attacker to take full control of a target system.

IoT Security

Lexmark warns of a remote code execution (RCE) vulnerability impacting over 120 printer models, for which PoC code has been published.


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

Application Security

A CSRF vulnerability in the source control management (SCM) service Kudu could be exploited to achieve remote code execution in multiple Azure services.