OPEN TARGET

Hack this server.
It says it can't be done.

This site is served by LeanNginx, a small web server that reads nginx's configuration language and is written in Lean. Its request parsing, routing and access checks come with machine-checked proofs: no path leaves the web root, no file under a password-protected location is served without the password, no request is split or smuggled. Proofs are only as good as what they state, and the server around them is ordinary code. Find where they stop.

The flags

#WhereWhat stands in the way
1/vault/flag.txtauth_basic with a long random password
2flag.txt one directory above the web rootpath normalisation (.., %2e%2e, %252e, ..;, …)
3a page under /staff/a second auth_basic, next to a try_files /q/$args.html catalog: the pattern that let GET /?../staff/… read protected pages through stock nginx

Each flag is a line starting with FLAG{. A flag, or any other way to make the server misbehave (a crash, a hang, a response that breaks HTTP, a header you control), counts.

What is here

Rules

Report

Email support@beneficialaifoundation.org with the flag or the behaviour, and the exact request that produced it. Real findings are fixed in the open in the LeanNginx repository and credited there if you like.

What is proved, and what isn't

Proved (in Spec.lean, 108 theorems, checked by Lean's kernel): request-head parsing, percent-decoding exactly once, path normalisation, location selection, confinement of every file path to its root or alias, that a served file belongs to a location whose auth_basic passed, header rendering without line breaks, byte ranges, gzip round-trips, the path sent to a proxy.

Not proved, only tested: the socket loop, timeouts and connection limits, file reads, the TLS connection loop, the Lean runtime and libuv underneath, the Linux kernel and the machine.