Function at 0x4612d2
Capabilities:
Create process on windows
Impersonate user

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x64
push ebx
push esi
push edi
push ecx
push ecx
lea ecx, [ebp - 0x44]
call fcn.00461145
push ecx
lea ecx, [ebp - 0x44]
call fcn.00461794
test al, al
jne 0x4612f9
xor bl, bl
jmp 0x46158e
xor ecx, ecx
lea eax, [ebp - 0x64]
push 0x20
push ecx
mov edi, ecx
mov byte [ebp - 1], cl
push eax
mov dword [ebp - 8], ecx
mov esi, ecx
mov ebx, ecx
mov dword [ebp - 0x10], edi
mov dword [ebp - 0x18], ecx
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0xc], ecx
call fcn.00422390
mov ecx, dword [ebp + 8]
add esp, 0xc
mov eax, dword [ebp + 0x14]
and eax, 1
mov dword [ebp - 0x64], 0x20
mov dword [ebp + 8], eax
mov eax, dword [ebp + 0x14]
push 2
pop edx
and eax, edx
mov dword [ebp - 0x5c], ecx
mov dword [ebp - 0x1c], eax
lea eax, [ebp - 8]
push eax
push edi
push edi
pop eax
setne al
add eax, edx
push eax
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push ecx
call dword [sym.imp.ADVAPI32.dll_LogonUserW]
test eax, eax
je 0x461520
cmp dword [ebp - 0x1c], ebx
je 0x461396
lea eax, [ebp + 0x10]
push eax
push 1
push 2
pop eax
push eax
push edi
push edi
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
test eax, eax
je 0x461520
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp + 0x10]
mov dword [ebp - 8], eax
push 0x60000
push 0
push str.winsta0
call dword [sym.imp.USER32.dll_OpenWindowStationW]
mov esi, eax
test esi, esi
je 0x461520
cmp esi, 0xffffffff
je 0x461520
call dword [sym.imp.USER32.dll_GetProcessWindowStation]
push esi
mov dword [ebp - 0x18], eax
call dword [sym.imp.USER32.dll_SetProcessWindowStation]
test eax, eax
je 0x461520
push 0x60081
push 0
push 0
push str.default
call dword [sym.imp.USER32.dll_OpenDesktopW]
mov ebx, eax
test ebx, ebx
je 0x461520
cmp ebx, 0xffffffff
je 0x461520
lea eax, [ebp - 0x10]
push eax
push dword [ebp - 8]
call fcn.0046182e
mov edi, dword [ebp - 0x10]
test al, al
je 0x461520
push ecx
lea eax, [ebp - 0x34]
mov word [ebp - 0x34], 0xb00
push eax
push edi
push esi
mov dword [ebp - 0x30], 0xf0000000
mov word [ebp - 0x28], 0x400
mov dword [ebp - 0x24], 0xf037f
call fcn.00460e5c
test al, al
je 0x461520
push ecx
lea eax, [ebp - 0x28]
mov word [ebp - 0x28], 0
push eax
push edi
push ebx
mov dword [ebp - 0x24], 0xf01ff
call fcn.00460c33
test al, al
je 0x461520
mov eax, dword [ebp + 0x28]
mov dword [eax + 8], str.winsta0default
mov eax, dword [eax + 0x2c]
and eax, 0x100
cmp dword [ebp + 0x1c], 0
mov dword [ebp + 0x10], eax
je 0x4614a7
push dword [ebp + 0x1c]
call fcn.004249b3
xor ecx, ecx
inc eax
push 2
pop edx
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0041fe5b
push dword [ebp + 0x1c]
mov dword [ebp - 0x14], eax
push eax
call fcn.004249d3
add esp, 0x10
cmp byte [ebp + 8], 0
je 0x4614be
lea eax, [ebp - 0x64]
push eax
push dword [ebp - 8]
call dword [sym.imp.USERENV.dll_LoadUserProfileW]
test eax, eax
je 0x461520
test byte [ebp + 0x14], 4
jne 0x4614d7
push 0
push dword [ebp - 8]
lea eax, [ebp - 0xc]
push eax
call dword [sym.imp.USERENV.dll_CreateEnvironmentBlock]
test eax, eax
je 0x461520
push dword [ebp + 0x2c]
mov eax, dword [ebp + 0x20]
push dword [ebp + 0x28]
or eax, 0x400
push dword [ebp + 0x24]
push dword [ebp - 0xc]
push eax
push dword [ebp + 0x10]
xor eax, eax
push eax
push eax
push dword [ebp - 0x14]
push eax
push dword [ebp - 8]
call dword [sym.imp.ADVAPI32.dll_CreateProcessAsUserW]
test eax, eax
je 0x461520
cmp byte [ebp + 8], 0
je 0x46151a
lea eax, [ebp - 8]
push eax
lea eax, [ebp - 0x48]
push eax
push dword [ebp + 0x2c]
call fcn.004618d4
mov byte [ebp - 1], 1
jmp 0x461532
cmp dword [ebp - 0x48], 0
je 0x461532
push dword [ebp - 0x48]
push dword [ebp - 8]
call dword [sym.imp.USERENV.dll_UnloadUserProfile]
test edi, edi
je 0x461546
push edi
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
test esi, esi
je 0x461551
push esi
call dword [sym.imp.USER32.dll_CloseWindowStation]
test ebx, ebx
je 0x46155c
push ebx
call dword [sym.imp.USER32.dll_CloseDesktop]
mov eax, dword [ebp - 0x18]
test eax, eax
je 0x46156a
push eax
call dword [sym.imp.USER32.dll_SetProcessWindowStation]
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 0x14]
call fcn.0041fe64
cmp dword [ebp - 0xc], 0
pop ecx
je 0x46158b
push dword [ebp - 0xc]
call dword [sym.imp.USERENV.dll_DestroyEnvironmentBlock]
mov bl, byte [ebp - 1]
lea ecx, [ebp - 0x44]
call fcn.00461190
pop edi
pop esi
mov al, bl
pop ebx
leave
ret 0x28