Dirty COW variation can root any type of Android devices

Oct 24, 2016 21:45 GMT  ·  By

Security researcher David Manouchehri has published exploit code for the Dirty COW Linux flaw that can be used to root Android smartphones.

The Dirty COW vulnerability came to light last week when the Linux project patched a security flaw that existed in the Linux kernel since version 3.6, released in 2007.

Nicknamed Dirty COW and tracked as CVE-2016-5195, the flaw was a race condition in kernel operations that allowed attackers to elevate privileges and execute code as another user (an EoP - Escalation of Privilege vulnerability). In simpler terms, Dirty COW allowed attackers to get root privileges on Linux machines.

Dirty COW affects all Android versions released

At the time, it was unclear if the Android operating system, which is based on the Linux kernel, was vulnerable to the issue.

Phil Oester, the man who discovered Dirty COW, didn't test for the vulnerability's presence in Android devices. Fortunately, Manouchehri did and published proof-of-concept code on GitHub on Sunday.

In a Twitter post, the researcher said he was able to use a variation of Dirty COW and get root privileges on a device running Android 6.0.1.

In an interview with Dan Goodin of ArsTechnica, Manouchehri says that all Android versions since version 1.0 seem to be vulnerable to Dirty COW.

Dirty COW is more dangerous than previously thought

While initially the infosec community has mocked Oester for overhyping Dirty COW by creating a dedicated website, logo, and Twitter feed, the vulnerability packed a bigger punch than even Oester had expected.

Exploitation is still a little bit tricky, since multiple conditions have to be met before triggering a kernel race condition, but the danger is still there.

Since Dirty COW's discovery, multiple Linux OS projects have patched their distros for the security flaw.

This is the second rooting method that came to light over the weekend, after an international team of researchers found a way to use the Rowhammer attack against Android devices, which also results in rooting the device.

UPDATE: There is also a report from NowSecure that details a different Dirty COW exploit variation that can root Android devices. The code is available on GitHub as well.