Function at 0x4013e0
Capabilities:
Acquire debug privileges
Create process on windows
Enumerate processes

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x4bc
mov eax, dword [0x539050]
xor eax, esp
mov dword [esp + 0x4b8], eax
mov eax, dword [ebp + 8]
push ebx
push esi
push edi
push 0x536280
mov dword [esp + 0x38], eax
call fcn.00402d10
mov ecx, eax
call fcn.00402e00
call fcn.00401370
lea ecx, [esp + 0x10]
xor ebx, ebx
mov edi, eax
push ecx
push edi
mov dword [esp + 0x38], ebx
mov dword [esp + 0x14], ebx
mov dword [esp + 0x18], ebx
mov dword [esp + 0x1c], ebx
call sub.WTSAPI32.dll_WTSQueryUserToken
test eax, eax
jne 0x4015bd
push str._wts
call fcn.00402d10
mov ecx, eax
call fcn.00402e00
push ebx
push 2
xor esi, esi
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x40148b
push str._INVALI
call fcn.00402d10
mov ecx, eax
call fcn.00402e00
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x4b8]
xor ecx, esp
call fcn.004047dd
mov esp, ebp
pop ebp
ret
lea edx, [esp + 0x88]
push edx
push ebx
mov dword [esp + 0x90], 0x22c
call sub.KERNEL32.dll_Process32FirstW
test eax, eax
je 0x401509
jmp 0x4014b0
lea eax, [esp + 0xac]
push str.explorer.exe
push eax
call fcn.00404f68
add esp, 8
test eax, eax
jne 0x4014f7
mov edx, dword [esp + 0x90]
lea ecx, [esp + 0xc]
push ecx
push edx
mov dword [esp + 0x14], eax
call dword [sym.imp.KERNEL32.dll_ProcessIdToSessionId]
test eax, eax
je 0x4014f7
cmp dword [esp + 0xc], edi
jne 0x4014f7
mov eax, dword [esp + 0x90]
mov esi, eax
test eax, eax
jne 0x401509
lea eax, [esp + 0x88]
push eax
push ebx
call sub.KERNEL32.dll_Process32NextW
test eax, eax
jne 0x4014b0
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
push ebx
call edi
test esi, esi
jne 0x40153e
push str.dwPid_0
call fcn.00402d10
mov ecx, eax
call fcn.00402e00
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x4b8]
xor ecx, esp
call fcn.004047dd
mov esp, ebp
pop ebp
ret
push esi
push 0
push 0x400
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov dword [esp + 0xc], eax
test eax, eax
jne 0x40157c
push str.OpenProcess_PROCESS_QUERY_INFORMATION
call fcn.00402d10
mov ecx, eax
call fcn.00402e00
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x4b8]
xor ecx, esp
call fcn.004047dd
mov esp, ebp
pop ebp
ret
lea ecx, [esp + 0x10]
push ecx
push 0xf00ff
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
jne 0x4015b9
mov eax, str.OpenProcess_TOKEN_ALL_ACCESS_P
call fcn.00403250
mov edx, dword [esp + 0xc]
push edx
call edi
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x4b8]
xor ecx, esp
call fcn.004047dd
mov esp, ebp
pop ebp
ret
xor ebx, ebx
jmp 0x4015c3
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x10]
cmp eax, ebx
jne 0x4015f3
push str.hPToken__NULL
call fcn.00402d10
mov ecx, eax
call fcn.00402e00
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x4b8]
xor ecx, esp
call fcn.004047dd
mov esp, ebp
pop ebp
ret
lea ecx, [esp + 0x30]
push ecx
push 4
lea edx, [esp + 0x24]
push edx
push 0x13
push eax
call dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
test eax, eax
jne 0x401639
lea eax, [esp + 0x38]
push eax
push str.SeDebugPrivilege
push ebx
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x14]
push ecx
push 1
push 1
push ebx
push 0x2000000
push edx
call dword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
jmp 0x401641
mov eax, dword [esp + 0x1c]
mov dword [esp + 0x14], eax
mov ecx, dword [esp + 0x14]
push 1
push ecx
lea edx, [esp + 0x20]
push edx
mov dword [esp + 0x24], ebx
mov esi, 0x2000000
call dword [sym.imp.USERENV.dll_CreateEnvironmentBlock]
test eax, eax
je 0x401667
mov esi, 0x2000400
jmp 0x40166b
mov dword [esp + 0x18], ebx
push 0x44
lea eax, [esp + 0x44]
push ebx
push eax
call fcn.00406000
add esp, 0xc
xor eax, eax
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], eax
mov dword [esp + 0x2c], eax
lea edx, [esp + 0x20]
push edx
mov edx, dword [esp + 0x38]
xor ecx, ecx
lea eax, [esp + 0x44]
push eax
mov eax, dword [esp + 0x1c]
push ebx
mov word [esp + 0x7c], cx
mov ecx, dword [esp + 0x24]
push ecx
push esi
push ebx
push ebx
push ebx
push edx
push ebx
push eax
mov dword [esp + 0x6c], 0x44
mov dword [esp + 0x98], 1
call dword [sym.imp.ADVAPI32.dll_CreateProcessAsUserW]
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, eax
test esi, esi
je 0x4016ed
push str.CreateProcessAsUser
call fcn.00402d10
mov ecx, eax
call fcn.00402e00
jmp 0x40172d
xor ecx, ecx
push 0x206
push ecx
lea edx, [esp + 0x2c2]
push edx
mov word [esp + 0x2c4], cx
call fcn.00406000
push ebx
lea eax, [esp + 0x2c8]
push 0x536338
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0x18
lea ebx, [esp + 0x2b8]
call fcn.00403150
cmp dword [esp + 0x20], 0
je 0x401742
mov ecx, dword [esp + 0x24]
push ecx
call edi
mov edx, dword [esp + 0x20]
push edx
call edi
mov eax, dword [esp + 0x14]
test eax, eax
je 0x40174d
push eax
call edi
mov eax, dword [esp + 0xc]
test eax, eax
je 0x401758
push eax
call edi
mov eax, dword [esp + 0x10]
test eax, eax
je 0x401763
push eax
call edi
mov eax, dword [esp + 0x18]
test eax, eax
je 0x401772
push eax
call dword [sym.imp.USERENV.dll_DestroyEnvironmentBlock]
mov ecx, dword [esp + 0x4c4]
pop edi
pop esi
pop ebx
xor ecx, esp
mov eax, 1
call fcn.004047dd
mov esp, ebp
pop ebp
ret