80

curl -i http://superpass.htb
HTTP/1.1 200 OK
Server: nginx/1.18.0 (Ubuntu)
Date: Thu, 13 Feb 2025 23:59:21 GMT
Content-Type: text/html; charset=utf-8
Content-Length: 6128
Connection: keep-alive

It seems like during login. Sometimes the server looses connection with the DB and outputs these errors

We can register.

Looks like we can add creds in the vault and export it. When exporting it makes a GET request to /vault/export, which creates the .csv file on the backend, every time with a different name with the scheme username_export_randomnumber.csv. And on the next request it redirects us to /uploads?fn=username_export_randomnumber.csv.

The /download is vulnerable to arbitrary file read.

Going through the browser we see that it throws an error.

Its running Werkzeug. And it asks for a PIN to access the console. I found this post that explains how to exploit LFI to crack the PIN.

First we need to know the user who is running this application.

We also need the MAC address, machine_id, and cgroup.

Checking the MAC address of eth0.

We have to convert it to decimal.

Next is machine_id

Next, cgroup

Concating them together

I used this script with the values I found here

Running it gives us a bunch of PIN numbers to use against the apps in the error pages console PIN input. And we get a python interpreter.

The system doesn't have nc, so I used bash rev shell.

Last updated