Skip to content
Memory corruption Advisory Advanced CVE-2024-36290

Wavlink AC3000 login.cgi Goto_chidx() buffer overflow vulnerability

The login.cgi binary of the Wavlink AC3000 router contains a stack-based buffer overflow in the Goto_chidx function because the wlanUrl parameter is copied into a fixed-size stack buffer without length checking. An unauthenticated attacker can send a crafted HTTP request to overflow the buffer and potentially execute code.

Lilith >_> Follow

Originally disclosed on Cisco Talos

Critical 10.0 View original

A buffer overflow vulnerability exists in the login.cgi Gotochidx() functionality of Wavlink AC3000 M33A8.V5030.210505. A specially crafted HTTP request can lead to stack-based buffer overflow.

Lilith >_>, 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

Impact

An unauthenticated attacker could exploit this to execute arbitrary code on the device, potentially taking full control of the router.

What the attacker needed

Network access to the device; no authentication required

The fix

The vendor has discontinued the product but is working on patches; the code should be fixed by using a bounded copy function instead of sprintf.

How it was found

  1. Send an HTTP POST request to login.cgi with a Content-Length less than 0x1f3.
  2. Set the page parameter to Goto_chidx.
  3. Provide a wlanUrl parameter with a value longer than the stack buffer (at least 0x90 bytes) to overflow the return address.

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.

A buffer overflow happens when a program puts more data into a fixed-size memory space than it can hold, causing the extra data to spill over and overwrite nearby memory. Here, the router's login program takes a URL parameter from an HTTP request and copies it into a small stack buffer without checking its length. An attacker can send a very long value to overwrite the return address on the stack, which may let them run their own code on the device.

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.

More by Lilith >_>

View all

148 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.

Memory corruption

The lesson behind this report.

Native code reads or writes memory it should not: overflows, use-after-free, type confusion. The core of browser, kernel and parser bugs.