Skip to content
Access control Advisory Advanced CVE-2018-4041

Clean My Mac X enableLaunchdAgentAtPath privilege escalation vulnerability

The root helper service of Clean My Mac X accepted a caller-supplied path and passed it to launchctl without validating the calling application or the path. Any local application could therefore load a launchd configuration file as root, crossing a privilege boundary and allowing modification of the file system as root.

Tyler Bohan Follow

Originally disclosed on Cisco Talos

High 7.1 View original

An exploitable privilege escalation vulnerability exists in the helper service of Clean My Mac X, version 4.04, due to improper input validation. An attacker with local access could exploit this vulnerability to modify the file system as root.

Tyler Bohan, on Cisco Talos

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Root cause

The helper's enableLaunchdAgentAtPath function passed user input straight to launchctl without validating the caller or the path.

Impact

A local attacker could load arbitrary root launchd configuration files, crossing a privilege boundary and modifying the file system as root; the proof of concept needed an administrator password to set up the root files first.

What the attacker needed

Local access to the Mac; ability to run an application

The fix

The vendor patched the issue, presumably by validating the calling application and the supplied path before loading it.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

Some apps run a small background helper with administrator rights so they can do privileged work. This helper trusted whatever path it was given and never checked who was asking, so any program on the machine could ask it to load a startup configuration file as the all-powerful root user. That means a normal user could get root-level changes made to the system.

What is Access control?

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.

More by Tyler Bohan

View all

84 more disclosed reports, best first.

More from Cisco Talos

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Broken access control

The lesson behind this report.

A user can do something their role should not allow: reach an admin function, act on a feature they have not paid for, or skip a permission check. IDOR is the special case where the object belongs to someone else.