DoS via Automatic Response Message
The automatic response message field had no size limit or validation, so a user could store an extremely large value. Sending several such requests at once consumed server resources and crashed the server, making the application unavailable to all users.
- Triaged in 21 hours
- Fixed in 3 months
- Paid in 22 hours
- Disclosed after 3 months
Summary:
A user can enable and modify its automatic response message, that is automatically sent when the user has the "Out of Office" status. This response message doesn't have any size check or validation, which allows an attacker to set an almost unlimited number of characters as the response value.
In a production environment is possible to set up to 50MB of data, due to the default nginx configuration, as the response message value, which causes the server to stop responding to user requests and ultimately leads to the server crash due to the incapacity to update and handle such a large amount of data.
Steps To Reproduce:
-
Login as a normal user in the platform.
-
Grab the
MMAUTHTOKENauthentication token. -
Generate the payload string, which consists in 50000000(50MB) characters. Python can be used for this:
Bash python2.7 -c "print 'A' * 50000000" -
Send the following
PUTrequest to the/api/v4/users/me/patchAPI Endpoint:PUT http://localhost:8065/api/v4/users/me/patch Content-Type: application/json X-CSRF-TOKEN: <csrf-token> Cookie: MMAUTHTOKEN=<token> {"notify_props":{"auto_responder_active":"true","auto_responder_message":"<payload>"}} -
For a greater impact, the above request should be sent 5 times at the same time. After the requests are sent, the server will start to consume an abnormal quantity of computing resources, and crashes after some seconds.
-
The application becomes unavailable for all its users.
The steps 3-6 can be automated using the following 2 commands:
$ python2.7 -c "print '{\"notify_props\":{\"auto_responder_active\":\"true\",\"auto_responder_message\":\"' + 'A' * 50000000 + '\"}}'" > payload
$ for ((i = 0; i < 5; i++)); do curl -X PUT "http://<domain>/api/v4/users/me/patch" -H 'Content-Type: application/json' -d @payload --cookie "MMAUTHTOKEN=<token>" -H "X-CSRF-TOKEN: <csrf-token>" &; done;
Supporting Material/References:
- PoC Video
Impact
A user can cause a full denial of service attack in the application server, making the application server unavailable to all its users.
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
Likely the auto-responder message field was stored without any maximum length or input validation, so oversized values exhausted server resources.
Impact
A single authenticated user could crash the server and make the application unavailable to all its users.
What the attacker needed
A normal user account; valid session token and CSRF token
How it was found
- Log in as a normal user.
- Obtain the authentication token from the session cookie.
- Build a very large string of characters as the message value.
- Send a PUT request to the user patch API endpoint with the auto-responder enabled and the large message.
- Send the request five times simultaneously so the server runs out of resources and crashes.
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.
Every user has an 'out of office' auto-reply message. The server saved whatever length of text was sent without checking it. By sending a huge message several times at once, the attacker overloaded the server until it stopped working for everyone.
What is DoS?
A request that exhausts resources or crashes a component. Many programs forbid testing it; reports usually show it from code, not by attacking.