Missing back-end user input validation can lead to DOS flaw
The application only enforced a maximum length for the public name field in the browser, not on the server. An attacker could send very long values in the POST request, causing the server to return a 400 error with the entire string and potentially consume server memory, leading to denial of service.
- Fixed in under an hour
- Disclosed after 47 hours
Hello Team,
Usually such kind of reports are out of scope, however I still would like to report you the business logic weakness that should be eliminated, at least from my point of view. Due to missing user input validation it is can lead to application unavailability.
Details:
During brief review of Liberapay application I have noticed that under 'Profile' page it's allowed to change username + name data. The first thing that caught my eye - "Name (optional) Maximum length is 64 <input name="public_name" class="form-control" value="zzzzz" maxlength="64" placeholder="Name">". It means that application has front-end user input validation, but what about back-end?
In case when the user exceeds the specified limit, the application server will return a response with the following status: 400 Bad Request + entire string that was inserted by user. Having this information in mind it was decided to check how the application server will handle the POST request that contains 100, 500, 10000, ... public_name value length.
In my case I simply changed the maxlength value directly at the DOM.
PoC: The usual response time for valid request is about ~150-200ms (65 public_name value length)

This one for 500 public_name value length

This one for 10000 public_name value length

This one for 15000 public_name value length

Remediation:
- The recommendation here is simple, before sending an actual processing request - the application need to double check the content-length at back end. All user input input should be validated at back-end.
Impact
This surface is a good base for a planning a DDoS attack Liberapay with a small bot-net asset, i.e. small number of machines may cause a consuming of server's RAM.
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 server does not validate the length of the public_name field and processes arbitrarily long input, returning it in error responses.
Impact
A small botnet could send many such requests to consume server RAM and cause a denial of service.
What the attacker needed
A user account; ability to modify DOM or send custom requests
The fix
The application should validate the length of all user input on the back-end before processing.
How it was found
- Go to the Profile page and edit the username or name.
- Change the maxlength attribute of the public_name input in the DOM to allow longer input.
- Submit a POST request with a public_name value longer than 64 characters (e.g., 100, 500, 10000, 15000).
- Observe the server response time and status code (400 Bad Request) including the entire submitted string.
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.
The form limits the name to 64 characters in the browser only. Sending a very long name directly to the server returns a 400 error containing the whole string, and may consume server memory, potentially slowing the site.
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.