Skip to content
Access control Write-up Advanced

Leveraging Android Permissions: A Solver Approach

A custom permission defined as normal could be redefined as dangerous and grouped with a system permission, causing the system permission to be granted without user consent. An attacker could silently obtain any system permission part of a group.

Jérémy Breton Follow

Published on blog.thalium.re

The work presented in this post was part of an internship carried out in 2022 within Thalium.

Jérémy Breton, on blog.thalium.re

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 write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely the permission system did not revoke granted status when a custom permission definition was removed, allowing a later redefinition to escalate privileges.

What the attacker needed

Ability to install apps; user installs malicious apps

The fix

Google fixed the issue by revoking install permission status when the defining application is uninstalled.

How it was found

  1. Install app-exp, which defines a normal custom permission.
  2. Install app-eop, which requests that custom permission and a system permission.
  3. Uninstall app-exp, leaving app-eop with the granted status.
  4. Install app-exp-update, which redefines the custom permission as dangerous and grouped with the system permission.
  5. The system permission is granted to app-eop without user consent.

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 write-up has not been written yet. The Original tab links to the source.

Android apps ask for permissions to use things like the camera or phone. Normally, the user must approve these requests. This bug let a malicious app trick Android into giving it a dangerous permission without ever asking the user, by abusing how custom permissions are defined and grouped.

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.

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.