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

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x41fd2c
mov eax, dword fs:[0]
push eax
sub esp, 0x400
mov eax, dword [0x42bba8]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
xor esi, esi
push 0x40
mov dword [ebp - 0x280], eax
xor eax, eax
lea edx, [ebp - 0x2e8]
push esi
push edx
mov dword [ebp - 0x26c], ecx
mov dword [ebp - 0x2a8], esi
mov dword [ebp - 0x2a4], eax
mov dword [ebp - 0x2a0], eax
mov dword [ebp - 0x29c], eax
mov dword [ebp - 0x2ec], esi
call fcn.0040fbc0
mov eax, vtable.ATL::CAccessToken.0
xor ebx, ebx
mov dword [ebp - 0x250], esi
mov dword [ebp - 0x260], esi
mov dword [ebp - 0x27c], eax
mov dword [ebp - 0x278], esi
mov dword [ebp - 0x274], esi
mov dword [ebp - 0x270], esi
mov dword [ebp - 4], esi
mov dword [ebp - 0x290], eax
mov dword [ebp - 0x28c], esi
mov dword [ebp - 0x288], esi
mov dword [ebp - 0x284], esi
mov dword [ebp - 0x268], 0x30
mov dword [ebp - method.OSVersionInfo.virtual_0], vtable.OSVersionInfo.0
mov dword [ebp - 0x408], 0x11c
push 0x228
lea eax, [ebp - 0x248]
push esi
push eax
mov byte [ebp - 4], 2
mov dword [ebp - 0x24c], esi
call fcn.0040fbc0
add esp, 0x18
push esi
push 2
call sub.KERNEL32.dll_CreateToolhelp32Snapshot
mov edi, eax
cmp edi, 0xffffffff
jne 0x409e7e
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.hSnap_Failed___ld
push 0x42ce08
call fcn.004012d0
add esp, 0xc
jmp 0x40a182
lea ecx, [ebp - 0x24c]
push ecx
push edi
mov dword [ebp - 0x24c], 0x22c
call sub.KERNEL32.dll_Process32FirstW
test eax, eax
jne 0x409eb7
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.Process_First_Failed_Last_Error__ld
push 0x42ce08
call fcn.004012d0
add esp, 0xc
jmp 0x40a182
call fcn.004091a0
push eax
push str.session_ld
push 0x42ce08
mov dword [ebp - 0x264], eax
call fcn.004012d0
add esp, 0xc
jmp 0x409ee0
push str.winlogon.exe
lea edx, [ebp - 0x228]
push edx
call dword [sym.imp.KERNEL32.dll_lstrcmpiW]
test eax, eax
jne 0x409f22
mov ecx, dword [ebp - 0x244]
lea eax, [ebp - 0x254]
push eax
push ecx
mov dword [ebp - 0x254], esi
call dword [sym.imp.KERNEL32.dll_ProcessIdToSessionId]
test eax, eax
je 0x409f22
mov edx, dword [ebp - 0x264]
cmp dword [ebp - 0x254], edx
je 0x409f35
lea eax, [ebp - 0x24c]
push eax
push edi
call sub.KERNEL32.dll_Process32NextW
test eax, eax
jne 0x409ee0
jmp 0x409f3b
mov ebx, dword [ebp - 0x244]
push ebx
push esi
xor ecx, ecx
push 0x100440
mov dword [ebp - 0x2ec], 0x44
mov dword [ebp - 0x2e4], 0x42317c
mov word [ebp - 0x2bc], cx
mov dword [ebp - 0x2c0], 1
call dword [sym.imp.KERNEL32.dll_OpenProcess]
lea edx, [ebp - 0x260]
push edx
push 0x201eb
push eax
mov dword [ebp - 0x254], eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jne 0x409fa7
call ebx
push eax
push str.OpenProcessToken_Error:__ld
push 0x42ce08
call fcn.004012d0
add esp, 0xc
mov edi, dword [ebp - 0x260]
lea eax, [ebp - 0x298]
push eax
push str.SeDebugPrivilege
push esi
mov dword [ebp - 0x28c], edi
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
test eax, eax
jne 0x409fdf
call ebx
push eax
push str.LookupPrivilegeValue_Error:__ld
push 0x42ce08
call fcn.004012d0
add esp, 0xc
mov ecx, dword [ebp - 0x298]
mov edx, dword [ebp - 0x294]
lea eax, [ebp - 0x250]
push eax
push 1
push 1
push esi
push 0x2000000
push edi
mov dword [ebp - 0x20], 1
mov dword [ebp - 0x1c], ecx
mov dword [ebp - 0x18], edx
mov dword [ebp - 0x14], 2
call dword [sym.imp.ADVAPI32.dll_DuplicateTokenEx]
call ebx
mov edx, dword [ebp - 0x264]
mov ecx, dword [ebp - 0x250]
push 4
push edx
push 0xc
push edi
mov dword [ebp - 0x278], ecx
call dword [sym.imp.ADVAPI32.dll_SetTokenInformation]
mov ecx, dword [ebp - 0x250]
push esi
push esi
push 0x10
lea eax, [ebp - 0x20]
push eax
push esi
push ecx
call dword [sym.imp.ADVAPI32.dll_AdjustTokenPrivileges]
test eax, eax
jne 0x40a05b
call ebx
push eax
push str.AdjustTokenPrivileges_Error:__ld
jmp 0x40a06c
call ebx
cmp eax, 0x514
jne 0x40a079
call ebx
push eax
push str.AdjustTokenPrivileges_Success_Last_Error:__ld
push 0x42ce08
call fcn.004012d0
add esp, 0xc
mov edx, dword [ebp - 0x250]
push 1
push edx
lea eax, [ebp - 0x25c]
push eax
mov dword [ebp - 0x25c], esi
call sub.USERENV.dll_CreateEnvironmentBlock
test eax, eax
je 0x40a0a4
mov dword [ebp - 0x268], 0x430
jmp 0x40a0aa
mov dword [ebp - 0x25c], esi
mov ecx, dword [ebp - 0x280]
push ecx
lea ecx, [ebp - 0x258]
call fcn.00404400
push 0x422158
lea ecx, [ebp - 0x258]
mov byte [ebp - 4], 3
call fcn.00404c30
mov edx, dword [ebp - 0x26c]
cmp edx, esi
jne 0x40a0de
xor eax, eax
jmp 0x40a0f2
mov eax, edx
lea edi, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, si
jne 0x40a0e3
sub eax, edi
sar eax, 1
push eax
push edx
lea ecx, [ebp - 0x258]
call fcn.00403df0
mov ecx, dword [ebp - 0x25c]
lea edx, [ebp - 0x2a8]
push edx
mov edx, dword [ebp - 0x268]
lea eax, [ebp - 0x2ec]
push eax
mov eax, dword [ebp - 0x258]
push esi
push ecx
mov ecx, dword [ebp - 0x250]
push edx
push esi
push esi
push esi
push eax
push esi
push ecx
call dword [sym.imp.ADVAPI32.dll_CreateProcessAsUserW]
mov edi, eax
call ebx
cmp edi, esi
jne 0x40a14f
push eax
push str.CreateProcessAsUser_Failed_Last_Error__ld
push 0x42ce08
call fcn.004012d0
add esp, 0xc
mov edx, dword [ebp - 0x254]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 0x258]
add eax, 0xfffffff0
mov byte [ebp - 4], 2
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40a182
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea ecx, [ebp - 0x290]
call fcn.004080d0
lea ecx, [ebp - 0x27c]
call fcn.004080d0
mov eax, 1
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0040fba6
mov esp, ebp
pop ebp
ret