Старый коммит (Old Commit)
Старый коммит (Old Commit)
Platform: CUSTOM | Category: Web | Type: Challenge | Difficulty: Easy | OS: N/A | **Author: XESXOR Techniques: git_directory_enumeration, git_repository_dumping, git_history_analysis
Summary
Walkthrough of the CUSTOM Web Старый коммит (Old Commit). Task: Web page with Matrix animation hides a flag in an exposed .git repository's old commit. Solution: Dump the .git directory with git-dumper, inspect git log to find an older commit containing the
Description
Чтобы найти флаг, нужно вернуться в прошлое. Адрес: https://old-commit.t1.bug-makers.ru
English summary: A web page is given at https://old-commit.t1.bug-makers.ru. The task name "Old Commit" and the hint "you need to go back in time" suggest examining version control history. The goal is to find a flag hidden in a previous version of the site.
Analysis
The target page displays a Matrix-style falling characters animation titled "БАГодельня" (a play on "bug" + Russian word). No visible flag or interesting content on the page itself.
Key discovery: The .git directory is publicly accessible on the web server.
$ curl -s https://old-commit.t1.bug-makers.ru/.git/HEAD
ref: refs/heads/main
Directory listing is disabled (returns 403 on /.git/), but individual git objects can be fetched directly — a classic exposed .git misconfiguration.
Solution
Step 1: Dump the Git Repository
Used git-dumper to reconstruct the full repository from the exposed .git directory:
bash read-only • copy allowedgit-dumper https://old-commit.t1.bug-makers.ru/.git tasks/bug-makers/old-commit/repo
Step 2: Examine Git History
Checked the commit log:
bash read-only • copy allowed$ git log --all --oneline c5cdaab The Matrix has you... 8db3e34 Flag
Two commits found. The older commit 8db3e34 is literally named "Flag" — a strong hint.
Step 3: Diff the Commits
bash read-only • copy allowed$ git diff 8db3e34 c5cdaab
The diff revealed:
- Old commit (
8db3e34— "Flag"): A simple HTML page with<h1>BugCTF{REDACTED}</h1> - New commit (
c5cdaab— "The Matrix has you..."): Replaced the flag page with a Matrix canvas animation
Old commit content:
html read-only • copy allowed<!DOCTYPE html> <html lang="ru"> <head> <meta charset="UTF-8"> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <title>Страница с флагом</title> </head> <body> <h1>BugCTF{REDACTED}</h1> </body>
The flag was committed in the first commit and then overwritten with the Matrix animation in the second commit. Since the .git directory was left exposed, the entire history — including the deleted flag — was recoverable.
Key Takeaways / Lessons
- Mastering git_directory_enumeration, git_repository_dumping, git_history_analysis was key to this challenge.
- Always check for common misconfigurations and verify assumptions.
Crafted by XESXOR Research • 2026-05-25 • CUSTOM • Старый коммит (Old Commit) • Difficulty: Easy