Scanning the target:
Checked the website, its source-code and robots.txt but didnt find anything. So lets do some directory busting:
Lets check these directories out:
Going through the files in /content/inc i found some interesting things, lets have a look at them:
cache.db doesnt seem to have anything for us, but the other db does. I have omitted some text out from the mysql backup file, as the important part is the lengthy part in the second image above.
"admin\\";s:7:\\"manager\\";s:6:\\"passwd\\";s:32:\\"42f749ade7f9e195bf475f37a44cafcb\\"This part clearly gives us admin user and password, but the password seems to be hashed, lets throw it on google:
We can now try this on /content/as:
My first instinct was to look for file upload feature so i can check /content/attachment for the uploaded file and get a reverse shell maybe:
IMPORTANT: I found the place to upload a file, but when i uploaded my php reverse shell, i couldn’t see the file being uploaded. BUT notice how there is a checkbox for extract zip archive? So i simply zipped my shell.php file and uploaded with, while checking the box. Then you can see the file, now just click to open it and you will get a connection back.
Now lets get the user flag:
EZ…
Get eXpl017’s stories in your inbox
Join Medium for free to get updates from this writer.
Lets move on the root flag:
Lets keep in mind the mysql creds, but i dont see a way to use it as of now (NOTE: i did try ssh to the machine using those creds but it failed). Now, we got sudo permission to run the backup.pl file, but what is in it? It is just a perl script which runs another file, a shell script. So lets have a look at that and its permissions.
I didnt know what that means, so i googled. Turns out, it is a reverse shell. But does it matter?We have write permissions on it, and with the previous sudo, we can do some devious stuff. But lets just spawn a root shell for now…
Aaaand here we have it. The root flag! EZ
Thank you!





![[IronHold] — Spring Boot Source Code Analysis: Finding Credentials, SQL Injection, PrivEsc, and…](https://miro.medium.com/v2/resize:fit:1358/format:webp/1*2yaTo73YRGo1GknAUJNfPg.jpeg)



