Skip to main content
Challenges Room: Web SQLi traces
Xonalar Medium Web log analysis: recovering the traces of a boolean-based blind SQL injection (bisection) Solves: 4

Room: Web SQLi traces

Author: CyberSamSU
Points
50

Room scenario. The online shop shop.example.uz noticed a strange increase in database queries at night. There is no WAF and the application log has been deleted — only the nginx access.log (combined format) remains. The attacker extracted data from the database through a boolean-based blind SQL injection in the product.php?id= parameter. Your task is to recover exactly what he took from the log itself.

You are given incident.zip: access.log (~3000 lines, a lot of noise) and the application's app_schema.sql schema (a list of tables and users, without keys).

In a blind SQLi the server does not return data directly: the attacker asks questions such as ORD(MID((SELECT ...),N,1))>K and tells "yes/no" apart by the response size (bytes). The character code is found by binary search (bisection).

Tasks (answers are not submitted, each builds on the previous one):

  1. Task 1. Find the attacker's IP and the tools used (User-Agent). What are the response sizes of a normal page and of the AND 1=1 and AND 1=2 requests? Which size is "true" and which is "false"?
  2. Task 2. How many different values did the attacker extract? What are the table, column and condition inside each SELECT? Using app_schema.sql, determine which one belongs to the api_key value of the admin user (note: admin_old is a different role).
  3. Task 3. For each position of the admin key, analyse the binary search requests (URL-encoded, a mix of +, /**/) and recover the character code. Only HTTP 200 responses whose size matches true/false are counted (watch out for rate-limit, "maintenance" pages and retries).
  4. Task 4. The recovered string is the admin's api_key value. It is the flag: BAYROQ{...} (the last 16 characters are lowercase hexadecimal).
Attached files
incident.zip Log in to download
Hints 3
Opening a hint reduces the points you get for solving this challenge.
Hint 1 −5 pts Log in
Hint 2 −10 pts Log in
Hint 3 −15 pts Log in
To submit a flag, log in.

First solvers

1. Mirjaxon Qaxxarov 24.11.2026
2. Asmaa Mottery 24.11.2026
3. Odam 25.11.2026
4. 𝖛𝖊𝖑𝖐𝖆𝖓 28.11.2026