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

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x8c
mov eax, dword [0x62e040]
xor eax, esp
mov dword [esp + 0x88], eax
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, dword [ebp + 0xc]
push esi
mov dword [esp + 0x34], eax
mov eax, dword [ebp + 0x14]
push edi
mov edi, dword [ebp + 8]
mov dword [esp + 0x34], eax
mov eax, dword [ebp + 0x18]
push 0x40
mov dword [esp + 0x34], eax
lea eax, [esp + 0x48]
push 0
push eax
mov dword [esp + 0x20], 0
mov dword [esp + 0x4c], 0x44
call fcn.00582250
mov edx, ebx
mov byte [esp + 0x1c], 0
and edx, 0x3000
add esp, 0xc
cmp edx, 0x3000
jne 0x4f744b
mov eax, 0xc00000f0
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x88]
xor ecx, esp
call fcn.005802ef
mov esp, ebp
pop ebp
ret 0x14
cmp dword [edi], 0
jne 0x4f7472
cmp dword [edi + 4], 0
jne 0x4f7472
mov eax, 0xc0000030
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x88]
xor ecx, esp
call fcn.005802ef
mov esp, ebp
pop ebp
ret 0x14
mov dword [esp + 0x6c], 1
mov eax, 1
mov word [esp + 0x70], ax
mov eax, dword [edi + 0x10]
mov dword [esp + 0x48], eax
test ebx, 0x40000
je 0x4f76bf
test edx, edx
sete al
xor edx, edx
test ebx, 0x10000
movzx eax, al
cmove edx, eax
mov dword [esp + 0x88], edx
test ebx, 0x20000
je 0x4f74ee
push 0
push 4
lea eax, [esp + 0x94]
or esi, 0xffffffff
push eax
push 0x18
push 0xffffffffffffffff
call dword [sym.imp.ntdll.dll_NtQueryInformationProcess]
test eax, eax
mov eax, dword [esp + 0x88]
movzx edx, al
cmovns esi, dword [esp + 0x8c]
xor ecx, ecx
cmp dword [edi + 0x14], esi
cmovne edx, ecx
mov eax, dword [edi + 0x24]
test eax, eax
je 0x4f74fe
cmp eax, 2
jne 0x4f76bf
mov edi, edi
test dl, dl
je 0x4f76bf
xor eax, eax
mov dword [esp + 0x10], eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], eax
mov dword [esp + 0x24], eax
cmp dword [edi + 0x28], eax
jne 0x4f752c
mov dword [edi + 0x28], 1
mov eax, dword [edi + 4]
test eax, eax
je 0x4f753d
push eax
call sym.SystemInformer.exe_PhCreateString
mov dword [esp + 0x10], eax
mov esi, ebx
or esi, 2
cmp dword [edi + 0xc], 0
cmovne esi, ebx
mov ebx, dword [esp + 0x10]
mov ecx, esi
mov eax, esi
shr ecx, 5
and ecx, 1
mov edx, ecx
or edx, 2
test al, 0x40
cmove edx, ecx
mov ecx, edx
or ecx, 4
test al, 4
cmove ecx, edx
mov edx, ecx
or edx, 0x10
test al, 0x10
cmove edx, ecx
mov ecx, edx
or ecx, 0x400
test al, 2
cmove ecx, edx
mov edx, ecx
or edx, 0x80000
test al, 0x80
cmove edx, ecx
mov ecx, edx
or ecx, 0x1000000
test al, 8
cmove ecx, edx
mov edx, ecx
or edx, 0x4000000
test esi, 0x100
cmove edx, ecx
test ebx, ebx
je 0x4f75b6
mov eax, dword [ebx + 4]
jmp 0x4f75b8
xor eax, eax
lea ecx, [esp + 0x18]
push ecx
lea ecx, [esp + 0x44]
push ecx
push dword [edi + 8]
push dword [edi + 0xc]
push edx
push eax
push dword [edi]
push dword [edi + 0x28]
push dword [edi + 0x20]
push dword [edi + 0x18]
push dword [edi + 0x1c]
call dword [sym.imp.ADVAPI32.dll_CreateProcessWithLogonW]
mov edi, edi
test eax, eax
je 0x4f75e8
xor esi, esi
jmp 0x4f760e
cmp dword [0x62ebb0], 0xffffffff
jae 0x4f75fc
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x34]
jmp 0x4f7606
lea esp, [esp]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call sym.SystemInformer.exe_PhDosErrorToNtStatus
mov esi, eax
test ebx, ebx
je 0x4f7628
lea ecx, ds:[ebx - 8]
or edx, 0xffffffff
lock xadd dword [ecx + 4], edx
dec edx
jne 0x4f7628
call fcn.004fc020
test esi, esi
js 0x4f7683
mov ecx, dword [esp + 0x38]
test ecx, ecx
je 0x4f7641
mov eax, dword [esp + 0x20]
mov dword [ecx], eax
mov eax, dword [esp + 0x24]
mov dword [ecx + 4], eax
mov edx, dword [esp + 0x34]
mov eax, dword [esp + 0x18]
test edx, edx
je 0x4f7651
mov dword [edx], eax
jmp 0x4f765c
test eax, eax
je 0x4f765c
push eax
call dword [sym.imp.ntdll.dll_NtClose]
mov edx, dword [esp + 0x30]
mov eax, dword [esp + 0x1c]
test edx, edx
je 0x4f7696
mov dword [edx], eax
mov eax, esi
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x88]
xor ecx, esp
call fcn.005802ef
mov esp, ebp
pop ebp
ret 0x14
mov eax, dword [esp + 0x18]
test eax, eax
je 0x4f7692
push eax
call dword [sym.imp.ntdll.dll_NtClose]
mov eax, dword [esp + 0x1c]
test eax, eax
je 0x4f76a6
push eax
call dword [sym.imp.ntdll.dll_NtClose]
mov eax, esi
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x88]
xor ecx, esp
call fcn.005802ef
mov esp, ebp
pop ebp
ret 0x14
nop
test ebx, 0x1000
je 0x4f7796
push dword [edi + 0x18]
lea eax, [esp + 0x14]
push 0x1000
push eax
call sym.SystemInformer.exe_PhOpenProcess
mov edi, edi
test eax, eax
jns 0x4f76fe
lfence
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x88]
xor ecx, esp
call fcn.005802ef
mov esp, ebp
pop ebp
ret 0x14
mov ecx, dword [0x636e88]
mov eax, dword [esp + 0x10]
mov dword [esp + 0x88], ecx
lea ecx, [esp + 0xc]
push ecx
push 0xf01ff
push eax
mov dword [esp + 0x98], eax
call dword [sym.imp.ntdll.dll_NtOpenProcessToken]
mov esi, eax
cmp esi, 0xc0000022
jne 0x4f7753
cmp dword [esp + 0x88], 5
jne 0x4f7753
mov ecx, dword [esp + 0x8c]
lea eax, [esp + 0xc]
push eax
mov edx, 0xf01ff
call fcn.005246c0
mov esi, eax
push dword [esp + 0x10]
call dword [sym.imp.ntdll.dll_NtClose]
lea ecx, [ecx]
test esi, esi
jns 0x4f7783
lfence
mov eax, esi
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x88]
xor ecx, esp
call fcn.005802ef
mov esp, ebp
pop ebp
ret 0x14
mov eax, ebx
shr eax, 0x11
and eax, 0xffffff01
mov dword [esp + 0x10], eax
jmp 0x4f78fa
jmp 0x4f77a0
test ebx, 0x2000
je 0x4f7846
xor eax, eax
mov dword [esp + 0x18], eax
mov dword [esp + 0x1c], eax
mov dword [esp + 0x20], eax
lea eax, [esp + 0x88]
push eax
push 0xc
lea eax, [esp + 0x20]
push eax
push 0xe
push dword [edi + 0x18]
push 0
call dword [sym.imp.WINSTA.dll_WinStationQueryInformationW]
test al, al
jne 0x4f782e
cmp dword [0x62ebb0], 0xffffffff
jae 0x4f780b
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x34]
push eax
call sym.SystemInformer.exe_PhDosErrorToNtStatus
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x88]
xor ecx, esp
call fcn.005802ef
mov esp, ebp
pop ebp
ret 0x14
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
call sym.SystemInformer.exe_PhDosErrorToNtStatus
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x88]
xor ecx, esp
call fcn.005802ef
mov esp, ebp
pop ebp
ret 0x14
mov eax, dword [esp + 0x20]
mov dword [esp + 0xc], eax
mov eax, ebx
shr eax, 0x11
and al, 1
mov byte [esp + 0x10], al
jmp 0x4f78fa
mov esi, dword [edi + 0x24]
test esi, esi
jne 0x4f78db
mov ecx, dword ds:[edi + 0x18]
mov esi, 2
mov al, byte [ecx]
xor al, 0xe
test al, 0x1f
jne 0x4f78db
push str.NT_AUTHORITY
push ecx
call fcn.00583d9e
add esp, 8
test eax, eax
jne 0x4f78db
mov ecx, dword ds:[edi + 0x1c]
mov al, byte [ecx]
xor al, 0xf3
test al, 0x1f
jne 0x4f7896
push str.SYSTEM
push ecx
call fcn.00583d9e
add esp, 8
test eax, eax
je 0x4f78d6
mov ecx, dword ds:[edi + 0x1c]
mov al, byte [ecx]
xor al, 0xc
test al, 0x1f
jne 0x4f78b9
push str.LOCAL_SERVICE
push ecx
call fcn.00583d9e
add esp, 8
test eax, eax
je 0x4f78d6
mov ecx, dword [edi + 0x1c]
mov al, byte ds:[ecx]
xor al, 0xe
test al, 0x1f
jne 0x4f78db
push str.NETWORK_SERVICE
push ecx
call fcn.00583d9e
add esp, 8
test eax, eax
jne 0x4f78db
mov esi, 5
lea eax, [esp + 0xc]
push eax
push 0
push esi
push dword [edi + 0x20]
push dword [edi + 0x18]
push dword [edi + 0x1c]
call dword [sym.imp.ADVAPI32.dll_LogonUserW]
test eax, eax
je 0x4f77da
lea ebx, [ebx]
test ebx, 0x10000
je 0x4f7976
lea eax, [esp + 0x90]
push eax
push 4
lea eax, [esp + 0x90]
push eax
push 0x13
push dword [esp + 0x1c]
call dword [sym.imp.ntdll.dll_NtQueryInformationToken]
test eax, eax
js 0x4f7976
mov esi, dword [esp + 0x88]
lea eax, [esp + 0x3c]
push eax
push 4
lea eax, [esp + 0x94]
push eax
push 8
push esi
call dword [sym.imp.ntdll.dll_NtQueryInformationToken]
test eax, eax
js 0x4f796f
cmp dword [esp + 0x8c], 1
jne 0x4f796f
push dword ds:[esp + 0xc]
call dword [sym.imp.ntdll.dll_NtClose]
mov dword [esp + 0xc], esi
jmp 0x4f79f9
push esi
call dword [sym.imp.ntdll.dll_NtClose]
cmp byte ds:[esp + 0x10], 0
je 0x4f79f9
lea eax, [esp + 0x88]
mov dword [esp + 0x18], 0x18
push eax
push 1
push 0
lea eax, [esp + 0x24]
mov dword [esp + 0x28], 0
push eax
push 0xf01ff
push dword [esp + 0x20]
mov dword [esp + 0x3c], 0
mov dword [esp + 0x38], 0
mov dword [esp + 0x40], 0
mov dword [esp + 0x44], 0
call dword [sym.imp.ntdll.dll_NtDuplicateToken]
push dword ds:[esp + 0xc]
mov esi, eax
call dword [sym.imp.ntdll.dll_NtClose]
test esi, esi
js 0x4f7764
mov eax, dword [esp + 0x88]
mov dword [esp + 0xc], eax
lea esp, [esp]
test ebx, 0x20000
je 0x4f7a54
mov eax, dword [edi + 0x14]
push 4
mov dword [esp + 0x8c], eax
lea eax, [esp + 0x8c]
push eax
push 0xc
push dword [esp + 0x18]
call dword [sym.imp.ntdll.dll_NtSetInformationToken]
mov esi, eax
test esi, esi
jns 0x4f7a54
lfence
push dword [esp + 0xc]
call dword [sym.imp.ntdll.dll_NtClose]
mov eax, esi
pop edi
pop esi
pop ebx
mov ecx, dword [esp + 0x88]
xor ecx, esp
call fcn.005802ef
mov esp, ebp
pop ebp
ret 0x14
test ebx, 0x80000
je 0x4f7a84
push 4
lea eax, [esp + 0x8c]
mov dword [esp + 0x8c], 1
push eax
push 0x1a
push dword [esp + 0x18]
call dword [sym.imp.ntdll.dll_NtSetInformationToken]
mov esi, eax
test esi, esi
js 0x4f7a2e
cmp dword [edi + 0xc], 0
jne 0x4f7abb
call fcn.005216a0
test eax, eax
je 0x4f7abb
push 0
push dword [esp + 0x10]
lea eax, [esp + 0x1c]
push eax
call fcn.005216a0
mov esi, eax
mov ecx, eax
call dword [0x5a38f4]
call esi
cmp dword [esp + 0x14], 0
je 0x4f7abb
or ebx, 2
mov edx, dword [esp + 0x30]
mov eax, dword [edi + 0xc]
test eax, eax
mov ecx, dword [esp + 0x14]
push edx
mov edx, dword [esp + 0x38]
cmovne ecx, eax
push edx
push dword [esp + 0x40]
lea eax, [esp + 0x4c]
push dword [esp + 0x18]
push ebx
push eax
push dword [edi + 8]
push ecx
push dword [edi + 4]
push dword [edi]
call sym.SystemInformer.exe_PhCreateProcessWin32Ex
mov edi, eax
call fcn.005217c0
test eax, eax
je 0x4f7b16
mov ecx, dword ds:[esp + 0x14]
test ecx, ecx
je 0x4f7b16
push ecx
call fcn.005217c0
mov esi, eax
mov ecx, eax
call dword [0x5a38f4]
call esi
push dword ds:[esp + 0xc]
call dword [sym.imp.ntdll.dll_NtClose]
mov ecx, dword [esp + 0x94]
mov eax, edi
pop edi
pop esi
pop ebx
xor ecx, esp
call fcn.005802ef
mov esp, ebp
pop ebp
ret 0x14