Ambassador
Enumeration
nmap -T4 -p- 10.10.11.183Ports found
PORT STATE SERVICE
22/tcp open ssh
80/tcp open http
3000/tcp open ppp
3306/tcp open mysqlSSH
Found a post with the following text
Hi there! This server exists to provide developers at Ambassador with a standalone development environment. When you start as a developer at Ambassador, you will be assigned a development server of your own to use.
Connecting to this machine
Use the developer account to SSH, DevOps will give you the password.Option number 1 brute force ssh with hydra and developer account
hydra -l developer -P /usr/share/wordlists/rockyou.txt 10.10.11.183 sshDEAD END
HTTP
Apache Version
Both nmap and metasploit point to version 2.4.41
List Dirs
DEAD END
MYSQL
Possible version MySQL 8.0.30-0ubuntu0.20.04.2
Default Credentials
Try to connect to db with root and developer credetial without password
No success.
Brute force
DEAD END
Grafana
Version: v8.2.0 (d7f71e9eae) found a CVE-2021-43798 on that version that affects Grafana 8.0.0-beta1 to 8.3.0
Try dump grafana.ini information
Interesting findings
Grafana interface
user: admin
pass: messageInABottle685427
Grafana DB
Dump DB
Try to find the DB user

Mysql with Grafana user
Inside the whackywidget database we can find the developer credential with base64
Decode the password

Post exploitation
Try to get root with the machine
LinPEAS
As always LinPEAS show A LOT of information, I try some CVEs like CVE-2021-3560 and CVE-2022-2588 however, none of them worked.
I also find an interesting git folder
Navigate to my-app and see history
Looking at the first commit we can see the consul authentication token
Consul
The best bet so far seems to use consul(port 8500) with a Metasploit method to root the machine, however, the service is not exposed
searchexploit
Service
Let's use chisel to create a tunnel between the developer user and the attacker machine
Remote machine
Attacker Machine
Attacker machine Metasploit
Flags
Last updated