Skip to main content
Challenges Comment board
Web Medium Stored XSS Solves: 5

Comment board

Author: CyberSamSU
Points
35

The public guestbook of SamCorp company has been found — anyone can leave a comment here. The admin opens this page every minute with their special token, and there is a cookie named FLAG_COOKIE in their browser — the flag is exactly inside this cookie.

The comment text seems to be properly sanitized on the page with htmlspecialchars() — a simple <script>alert(1)</script> will not work. But there is another place on the page: a quick preview block called "latest comment" inserts it again into the page in a different way.

Goal: write such a comment that when the admin views it, your JavaScript code runs in the admin's browser and sends the document.cookie value to the /?action=leak&c=... address. Then read the stolen flag from the /?action=leaks page.

To start this challenge's lab, log in.
Hints 3
Opening a hint reduces the points you get for solving this challenge.
Hint 1 −3 pts Log in
Hint 2 −7 pts Log in
Hint 3 −10 pts Log in
To submit a flag, log in.

First solvers

1. Behruz Rashidov 06.11.2026
2. B.E.O.Otabek 11.11.2026
3. Odam 20.11.2026
4. Asmaa Mottery 26.11.2026
5. Mirjaxon Qaxxarov 27.11.2026