Microsoft Azure Sphere Normal World application /proc/thread-self/mem unsigned code execution vulnerability
The /proc/thread-self/mem file remained writable after a patch made /proc/self/mem read-only, allowing an attacker who has already compromised an application to overwrite executable memory with shellcode and run unsigned code.
Originally disclosed on Cisco Talos
A code execution vulnerability exists in the normal world’s signed code execution functionality of Microsoft Azure Sphere 20.07. A specially crafted shellcode can cause a process’ non-writable memory to be written.
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
Impact
An attacker who has already compromised an application could execute unsigned code, bypassing the platform's memory protection.
What the attacker needed
Already compromised application
How it was found
- Open /proc/thread-self/mem with write-only access.
- Seek to the address of the target function.
- Write shellcode to overwrite the function.
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.
Normally, a program's code is protected from being changed while it runs. This report found that a special file in the Linux system still allowed writing to that protected memory, so an attacker who already had control of a program could replace its code with their own.
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.