Skip to content
SQL injection Write-up Beginner

How i Hacked into My College Website ??

The college website had a SQL injection in a faculty profile parameter that exposed an admin credentials table stored in plaintext, and those credentials gave access to the admin dashboard. The author also found missing DMARC allowing email spoofing, personal data exposure, a denial-of-service via a long input, and several informational issues.

Mehboob khan Follow

Published on systemweakness.com

👋 Hi, I’m Mehboob Khan, a Computer Science & Engineering graduate (2023). I’m obsessed with understanding how technology ticks and love bypassing logic to uncover hidden vulnerabilities. 🔍💻

Mehboob khan, on systemweakness.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 the faculty parameter was concatenated into a SQL query without parameterisation, and admin passwords were stored in plaintext.

Impact

An attacker could read student, faculty and contact data, obtain admin credentials, and modify the website and records; the author also spoofed email and caused a 500 error with a long input.

What the attacker needed

Permission from college principal; no login needed for SQL injection; admin login page reachable

The fix

The vulnerabilities were fixed after about two months according to the author.

How it was found

  1. Run an automated scanner against the college URL and note a possible SQL injection alert.
  2. Use sqlmap on the faculty-profile parameter to list databases.
  3. Enumerate tables and find an admin credentials table with plaintext passwords.
  4. Find the admin login page from the scanner's spidered URLs and log in with the recovered credentials.

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.

A website took a number from the address bar and put it straight into a database query without checking it. By changing that number, the author could make the database reveal its contents, including admin usernames and passwords that were not scrambled. With those, he logged into the admin area and could change site content.

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 Mehboob khan

View all

3 more disclosed reports, 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.