Analytics
Personal Rating: Medium
Last updated
Personal Rating: Medium
Last updated
I started a full nmap scan and a vhost scan in the background.
sudo nmap -oA nmap-analytics -p- -A 10.10.11.233
ffuf -u http://10.10.11.233/ -H 'Host: FUZZ.analytical.htb' -w /usr/share/seclists/Discovery/DNS/dns-Jhaddix.txt -mc 200 -t 64
There is a webserver on port 80 -> analytical.htb
A login page references data.analytical.htb
According to Wappalyzer, there is Leaflet, React, Emotion, nginx, PWA, webpack, D3, HSTS, Ace and Lodash
So the webserver is based on Metabase. There is nothing in Hacktricks about it, so I will poke around for a bit by myself. The only exploit for it I could find online is CVE-2023-38646.
I could identify the setup-token to be 249fa03d-fd94-4d5b-b94f-b4ebf3df681f
This might show the request required for exploitation:
Following the guide above, I got a reverse shell with this request after getting the token and encoding the shell:
In the reverse shell, most commands show “command not found”
LinEnum gave me this:
This did allow for ssh login
It looks like we are inside an alpine docker container!
which nmap aws nc ncat netcat nc.traditional wget curl ping gcc g++ make gdb base64 socat python python2 python3 python2.7 python2.6 python3.6 python3.7 perl php ruby xterm doas sudo fetch docker lxc ctr runc rkt kubectl 2>/dev/null
We have some binaries, but really not many:
Running LinPEAS:
is modprobe present ............ lrwxrwxrwx 1 root root 12 Jun 14 15:03 /sbin/modprobe -> /bin/busybox
Following this guide, it seems promising:
I found a database file at /metabase.db/metabase.db.mv.db , which turns out to be a H2 database, according to this
After running LinPeas and googling for a while, I found this post
After some more googling I found this PoC, which worked to get a root shell: