Function at 0x43ae8b
Capabilities:
Impersonate user

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x5c
push ebx
push esi
push edi
push ecx
push ecx
lea ecx, [ebp - 0x3c]
call fcn.0043acff
push ecx
lea ecx, [ebp - 0x3c]
call fcn.0043b2f9
test al, al
jne 0x43aeb2
xor bl, bl
jmp 0x43b119
xor ebx, ebx
push 0x20
lea eax, [ebp - 0x5c]
push ebx
push eax
mov dword [ebp - 4], ebx
mov esi, ebx
mov edi, ebx
mov dword [ebp - 8], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x10], ebx
mov dword [ebp - 0xc], ebx
call fcn.00420f20
mov eax, dword [ebp + 8]
add esp, 0xc
test byte [ebp + 0x14], 1
mov dword [ebp - 0x5c], 0x20
mov dword [ebp - 0x54], eax
mov byte [ebp + 0xb], bl
je 0x43aef0
mov byte [ebp + 0xb], 1
lea ecx, [ebp - 4]
push ecx
push ecx
push dword [ebp + 0x14]
push dword [ebp + 0x10]
push dword [ebp + 0xc]
push eax
call fcn.0043b2cb
test al, al
je 0x43b0bb
push 2
pop ecx
test byte [ebp + 0x14], cl
je 0x43af3d
lea eax, [ebp + 0x10]
push eax
push 1
push ecx
push ebx
push ebx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
test eax, eax
je 0x43b0bb
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp + 0x10]
mov dword [ebp - 4], eax
push 0x60000
push ebx
push str.winsta0
call dword [sym.imp.USER32.dll_OpenWindowStationW]
mov esi, eax
test esi, esi
je 0x43b0bb
cmp esi, 0xffffffff
je 0x43b0bb
call dword [sym.imp.USER32.dll_GetProcessWindowStation]
push esi
mov dword [ebp - 0x14], eax
call dword [sym.imp.USER32.dll_SetProcessWindowStation]
test eax, eax
je 0x43b0bb
push 0x60081
push ebx
push ebx
push str.default
call dword [sym.imp.USER32.dll_OpenDesktopW]
mov edi, eax
test edi, edi
je 0x43b0bb
cmp edi, 0xffffffff
je 0x43b0bb
lea eax, [ebp - 8]
push eax
push dword [ebp - 4]
call fcn.0043b391
test al, al
je 0x43b0bb
push ecx
lea eax, [ebp - 0x2c]
push eax
push dword [ebp - 8]
mov word [ebp - 0x2c], 0xb00
push esi
mov dword [ebp - 0x28], 0xf0000000
mov word [ebp - 0x20], 0x400
mov dword [ebp - 0x1c], 0xf037f
call fcn.0043aa2d
test al, al
je 0x43b0bb
push ecx
lea eax, [ebp - 0x20]
push eax
push dword [ebp - 8]
mov word [ebp - 0x20], bx
push edi
mov dword [ebp - 0x1c], 0xf01ff
call fcn.0043a832
test al, al
je 0x43b0bb
mov eax, dword [ebp + 0x28]
mov dword [eax + 8], str.winsta0default
mov eax, dword [eax + 0x2c]
and eax, 0x100
mov dword [ebp + 0x10], eax
cmp dword [ebp + 0x1c], ebx
je 0x43b049
push dword [ebp + 0x1c]
call fcn.00420eab
xor ecx, ecx
push 2
inc eax
pop edx
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.0041f6ba
push dword [ebp + 0x1c]
mov dword [ebp - 0x10], eax
push eax
call fcn.00420ef3
add esp, 0x10
cmp byte [ebp + 0xb], bl
je 0x43b05f
lea eax, [ebp - 0x5c]
push eax
push dword [ebp - 4]
call dword [sym.imp.USERENV.dll_LoadUserProfileW]
test eax, eax
je 0x43b0bb
test byte [ebp + 0x14], 4
jne 0x43b077
push ebx
push dword [ebp - 4]
lea eax, [ebp - 0xc]
push eax
call dword [sym.imp.USERENV.dll_CreateEnvironmentBlock]
test eax, eax
je 0x43b0bb
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]
push ebx
push ebx
push dword [ebp - 0x10]
push ebx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_CreateProcessAsUserW]
test eax, eax
je 0x43b0bb
cmp byte [ebp + 0xb], bl
je 0x43b0b7
lea eax, [ebp - 4]
push eax
lea eax, [ebp - 0x40]
push eax
push dword [ebp + 0x2c]
call fcn.0043b428
mov bl, 1
jmp 0x43b0cc
cmp dword [ebp - 0x40], ebx
je 0x43b0cc
push dword [ebp - 0x40]
push dword [ebp - 4]
call dword [sym.imp.USERENV.dll_UnloadUserProfile]
mov ecx, dword [ebp - 8]
call fcn.0043acea
test esi, esi
je 0x43b0df
push esi
call dword [sym.imp.USER32.dll_CloseWindowStation]
test edi, edi
je 0x43b0ea
push edi
call dword [sym.imp.USER32.dll_CloseDesktop]
mov eax, dword [ebp - 0x14]
test eax, eax
je 0x43b0f8
push eax
call dword [sym.imp.USER32.dll_SetProcessWindowStation]
push dword [ebp - 4]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push dword [ebp - 0x10]
call fcn.0041f72e
cmp dword [ebp - 0xc], 0
pop ecx
je 0x43b119
push dword [ebp - 0xc]
call dword [sym.imp.USERENV.dll_DestroyEnvironmentBlock]
lea ecx, [ebp - 0x3c]
call fcn.0043ad4a
pop edi
pop esi
mov al, bl
pop ebx
leave
ret 0x28