Function at 0x10173860
Capabilities:
Enumerate processes
Get session user name

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x1023deb5
mov eax, dword fs:[0]
push eax
sub esp, 0x2b0
mov eax, dword [0x102e91c0]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, ecx
mov dword [ebp - 0x2b4], esi
xor ebx, ebx
mov dword [ebp - 0x48], 0
xor eax, eax
mov dword [ebp - 0x38], ebx
mov dword [ebp - 0x34], 7
mov word [ebp - 0x48], ax
mov dword [ebp - 4], eax
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x284]
mov dword [ebp - 0x18], 0x101
push eax
call dword [sym.imp.ADVAPI32.dll_GetUserNameW]
test eax, eax
je 0x101738f9
lea ecx, [ebp - 0x284]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x101738d7
sub ecx, edx
lea eax, [ebp - 0x284]
sar ecx, 1
push ecx
push eax
lea ecx, [ebp - 0x48]
call fcn.10010360
mov ebx, dword [ebp - 0x38]
xor edi, edi
push edi
push 0xf
mov dword [ebp - 0x2b8], edi
call dword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
lea ecx, [ebp - 0x2ac]
mov dword [ebp - 0x18], eax
push ecx
push eax
mov dword [ebp - 0x2ac], 0x22c
call dword [sym.imp.KERNEL32.dll_Process32FirstW]
test eax, eax
je 0x10173a9a
nop dword [eax]
cmp dword [esi + 0x14], 8
mov eax, esi
jb 0x1017393a
mov eax, dword [esi]
push eax
lea eax, [ebp - 0x288]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiW]
test eax, eax
jne 0x10173a82
test ebx, ebx
je 0x10173a7b
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x20], eax
mov dword [ebp - 0x1c], 7
mov word [ebp - 0x30], ax
mov dword [ebp - 0x60], eax
mov dword [ebp - 0x50], eax
mov dword [ebp - 0x4c], 7
mov word [ebp - 0x60], ax
push dword [ebp - 0x2a4]
push eax
push 0x400
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov edi, eax
test edi, edi
je 0x10173acf
lea eax, [ebp - 0x2b0]
mov dword [ebp - 0x2b0], 0
push eax
push 8
push edi
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
jne 0x101739c0
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x10173acf
xor eax, eax
mov dword [ebp - 0x78], 0
mov dword [ebp - 0x68], 0
mov dword [ebp - 0x64], 7
mov word [ebp - 0x78], ax
push ecx
lea eax, [ebp - 0x78]
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x2b0]
lea edx, [ebp - 0x30]
push eax
lea eax, [ebp - 0x60]
push eax
call fcn.10172ae0
add esp, 0xc
mov esi, eax
push dword [ebp - 0x2b0]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [ebp - 0x78]
call fcn.1000ae90
test esi, esi
je 0x10173ac9
cmp dword [ebp - 0x1c], 8
lea eax, [ebp - 0x30]
mov edi, dword [ebp - 0x20]
lea esi, [ebp - 0x48]
cmovae eax, dword [ebp - 0x30]
mov edx, ebx
cmp dword [ebp - 0x34], 8
cmovae esi, dword [ebp - 0x48]
cmp edi, ebx
cmovb edx, edi
test edx, edx
je 0x10173a55
sub esi, eax
mov cx, word [eax + esi]
cmp cx, word [eax]
jne 0x10173ac9
add eax, 2
sub edx, 1
jne 0x10173a44
cmp ebx, edi
jb 0x10173ac9
ja 0x10173ac9
lea ecx, [ebp - 0x60]
call fcn.1000ae90
lea ecx, [ebp - 0x30]
mov byte [ebp - 4], 0
call fcn.1000ae90
mov esi, dword [ebp - 0x2b4]
mov edi, dword [ebp - 0x2b8]
inc edi
mov dword [ebp - 0x2b8], edi
lea eax, [ebp - 0x2ac]
push eax
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_Process32NextW]
test eax, eax
jne 0x10173930
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [ebp - 0x48]
call fcn.1000ae90
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.101cff65
mov esp, ebp
pop ebp
ret
mov esi, dword [ebp - 0x2b4]
lea ecx, [ebp - 0x60]
call fcn.1000ae90
lea ecx, [ebp - 0x30]
mov byte [ebp - 4], 0
call fcn.1000ae90
mov edi, dword [ebp - 0x2b8]
jmp 0x10173a82