Skip to content
SQL injection Write-up Beginner

SQL injection vulnerability allowing login bypass — Post Method

The login page was vulnerable to SQL injection via the POST method, allowing an attacker to bypass authentication and log in as the administrator user.

RayofHope Follow

Published on infosecwriteups.com

Hi, my fellow hackers. This is Rayofhope.

RayofHope, on infosecwriteups.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

Impact

An attacker could bypass authentication and gain access to the administrator account, potentially leading to full control of the application.

What the attacker needed

Knowledge of a valid username (e.g., administrator)

How it was found

  1. Navigate to the My Account login page.
  2. Submit a crafted username with an SQL injection payload and any password.
  3. Observe the 'Invalid credentials' error, indicating the injection affected the query.
  4. Use the username 'administrator' with the injection payload to bypass authentication.
  5. Successfully log in to the administrator account.

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.

SQL injection is when user input is inserted into a database query without proper handling, letting an attacker change the query's meaning. Here, the login form's username field was vulnerable, so a crafted input could make the login check succeed without a valid password, giving access to the admin account.

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 RayofHope

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.