Function at 0x10002fb1
Capabilities:
Check os version
Compare security identifiers

Disassembly:
push ebp
lea ebp, [esp - 0xbc]
sub esp, 0x13c
mov eax, dword [0x1006d144]
xor eax, ebp
mov dword [ebp + 0xb8], eax
push ebx
xor ebx, ebx
cmp dword [ebp + 0xc4], 0xffffffff
push esi
mov esi, dword [ebp + 0xc8]
mov dword [ebp - 0x78], esi
mov dword [ebp - 0x6c], ebx
mov dword [ebp - 0x80], ebx
mov dword [ebp - 0x74], ebx
je 0x1000300d
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
cmp eax, dword [ebp + 0xc4]
je 0x1000300d
push dword [ebp + 0xc4]
push ebx
push 0x410
call dword [sym.imp.KERNEL32.dll_OpenProcess]
jmp 0x10003013
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov dword [ebp - 0x70], eax
cmp eax, ebx
je 0x10003184
lea eax, [ebp - 0x6c]
push eax
push 8
push dword [ebp - 0x70]
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x10003184
push 0x110
lea eax, [ebp - 0x60]
push ebx
push eax
mov dword [ebp - 0x64], 0x114
call fcn.1003c230
add esp, 0xc
lea eax, [ebp - 0x64]
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
cmp dword [ebp - 0x60], 6
jb 0x100030a1
lea eax, [ebp - 0x68]
push eax
push 4
lea eax, [ebp - 0x78]
push eax
push 0x14
push dword [ebp - 0x6c]
mov dword [ebp - 0x68], ebx
mov dword [ebp - 0x78], ebx
call dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
test eax, eax
je 0x10003184
cmp dword [ebp - 0x68], 4
mov dword [ebp - 0x80], 1
jne 0x10003184
xor eax, eax
cmp dword [ebp - 0x78], ebx
setne al
mov dword [esi], eax
jmp 0x10003184
lea eax, [ebp - 0x74]
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0x220
push 0x20
push 2
lea eax, [ebp + 0xb0]
push eax
mov byte [ebp + 0xb0], bl
mov byte [ebp + 0xb1], bl
mov byte [ebp + 0xb2], bl
mov byte [ebp + 0xb3], bl
mov byte [ebp + 0xb4], bl
mov byte [ebp + 0xb5], 5
call dword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
test eax, eax
je 0x10003184
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
lea eax, [ebp - 0x7c]
push eax
push ebx
push ebx
push 2
push dword [ebp - 0x6c]
mov dword [ebp - 0x7c], ebx
call edi
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x10003183
push dword [ebp - 0x7c]
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov esi, eax
cmp esi, ebx
je 0x10003183
lea eax, [ebp - 0x7c]
push eax
push dword [ebp - 0x7c]
push esi
push 2
push dword [ebp - 0x6c]
call edi
test eax, eax
je 0x10003174
xor edi, edi
mov dword [ebp - 0x80], 1
cmp dword [esi], ebx
jbe 0x10003174
lea eax, [esi + 4]
mov dword [ebp - 0x68], eax
mov eax, dword [ebp - 0x68]
push dword [eax]
push dword [ebp - 0x74]
call dword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
jne 0x1000316b
add dword [ebp - 0x68], 8
inc edi
cmp edi, dword [esi]
jb 0x1000314e
jmp 0x10003174
mov eax, dword [ebp - 0x78]
mov dword [eax], 1
push esi
push ebx
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapFree]
pop edi
cmp dword [ebp - 0x74], ebx
je 0x10003192
push dword [ebp - 0x74]
call dword [sym.imp.ADVAPI32.dll_FreeSid]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp dword [ebp - 0x6c], ebx
je 0x100031a2
push dword [ebp - 0x6c]
call esi
cmp dword [ebp - 0x70], ebx
je 0x100031ac
push dword [ebp - 0x70]
call esi
mov ecx, dword [ebp + 0xb8]
mov eax, dword [ebp - 0x80]
pop esi
xor ecx, ebp
pop ebx
call fcn.1003b874
add ebp, 0xbc
leave
ret 8