Skip to content
SQL injection Write-up Beginner

One Login Form, Two Burp Suite Tools, and a Full Database Schema

The login form accepted a common password for the admin account, and the product search box pasted user input straight into a SQL query. An attacker could guess the admin password and use a crafted search term to dump the full database schema.

Reva Zuranti Follow

Published on medium.com

Burp suite holds a whole toolbox, and two of its tools answer two very different questions about the same web app. Intruder answers “can I just guess the password.” Repeater answers “does this input reach the database unfiltered.” This walkthrough runs both against OWASP Juice Shop, a web app built on purposes to be…

Reva Zuranti, on medium.com

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 write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Likely a weak admin password with no lockout, plus search input concatenated into SQL instead of using parameterised queries.

Impact

An attacker could log in as admin and read the definition of every table in the database, including user and wallet data structures.

What the attacker needed

Target runs OWASP Juice Shop; a wordlist of common passwords; traffic routed through a proxy

The fix

It should be fixed with account lockout or rate limiting on login, stronger password rules, parameterised queries and generic error messages.

How it was found

  1. Send a login attempt through the proxy and capture the request.
  2. Send the request to Intruder, mark the password as the payload position and load a wordlist.
  3. Run the attack and look for a response that differs in status and length.
  4. Log in with the password that broke the pattern.
  5. Send a product search request to Repeater and add a single quote to the search term.
  6. Close the quote, comment out the rest, and add a UNION SELECT reading from sqlite_master.

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 write-up has not been written yet. The Original tab links to the source.

The site let someone keep guessing the admin password until a very common one worked. Separately, the search box put whatever you typed directly into a database command, so a special character could make the database reveal its own structure. Both are basic mistakes that let an attacker get in and see data they should not.

What is SQL injection?

Input reaches a database query as code, letting an attacker read or change data the application never meant to expose.

More by Reva Zuranti

View all

1 more disclosed report, best first.

Similar reports

View all

Same bug class and techniques, clearest first.

SQL injection

The lesson behind this report.

Input reaches a database query as code, letting an attacker read or change data the application never meant to expose.