Milesight UR32L libzebra.so security_decrypt_password buffer overflow vulnerability
A stack-based buffer overflow exists in the security_decrypt_password function of Milesight UR32L routers. An authenticated attacker can send a specially crafted HTTP request to trigger the overflow, potentially leading to code execution.
Originally disclosed on Cisco Talos
A stack-based buffer overflow vulnerability exists in the libzebra.so.0.0.0 securitydecryptpassword functionality of Milesight UR32L v32.3.0.5. A specially crafted HTTP request can lead to a buffer overflow.
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 ys_aes_decrypt function writes decrypted data into a fixed-length stack buffer without checking the input length, causing a stack-based buffer overflow.
Impact
An authenticated attacker could exploit this to cause a buffer overflow, potentially leading to arbitrary code execution with high impact on confidentiality, integrity, and availability.
What the attacker needed
Authenticated access to the router
How it was found
- Authenticate to the router.
- Send an HTTP request to the /cgi endpoint with core yruo_usermanagement and function set.
- Include an overly long encrypted password in the old_password, new_password, or confirm_password field.
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.
This report describes a memory corruption bug in a router's password decryption routine. When the router tries to decrypt a password that is too long, it writes past the end of a fixed-size buffer on the stack, which can crash the device or let an attacker run their own code. The attacker must already be logged in to send the malicious request.
What is Memory corruption?
Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.