SQL Injection - data[account][id] parameter
A SQL injection flaw was found in the data[account][id] parameter, allowing an attacker to manipulate backend SQL queries. This could lead to unauthorised data access, leakage, or corruption, and potentially full database compromise.
Originally disclosed on HackerOne
- Triaged in 2 hours
- Fixed in 28 days
- Disclosed after 8 months
Description: Hi! I discovered a SQL Injection vulnerability in the data[account][id] parameter on the website ███████. The vulnerability allows for the manipulation of SQL queries executed by the backend database, which could potentially lead to unauthorized data access or manipulation.
References
████
Impact
The ability to manipulate SQL queries can lead to: Unauthorized access to sensitive data. Potential data leakage. Data manipulation or corruption. Full database compromise if administrative permissions are accessible.
System Host(s)
█████
Affected Product(s) and Version(s)
CVE Numbers
Steps to Reproduce
Use the sqlmap:
sqlmap -r file.txt --dbs --tamper=between --batch -p 'data[account][id]'
Use the file.txt attached to the report.
Suggested Mitigation/Remediation Actions
Use parameterized queries when dealing with SQL queries that contain user input. Parameterized queries allow the database to understand which parts of the SQL query should be considered as user input, therefore solving SQL injection.
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 application built SQL queries by concatenating user input instead of using parameterised queries.
Impact
An attacker could access, leak, or corrupt sensitive data, and may achieve full database compromise if administrative permissions are available.
What the attacker needed
Ability to send requests with the parameter
The fix
The application should use parameterised queries so that user input is treated as data, not as part of the SQL command.
How it was found
- Capture a request containing the data[account][id] parameter and save it to a file.
- Run sqlmap against that saved request, targeting the parameter, to enumerate databases.
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.
SQL injection is when user input is inserted into a database command without being properly separated, so an attacker can change the command. Here, the data[account][id] value was not handled safely, letting someone alter what the database does. That could expose or change stored information.
What is SQL injection?
Input reaches a database query as code, letting an attacker read or change data the application never meant to expose.