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

Disassembly:
push ebp
lea ebp, [esp - 0xbc]
sub esp, 0x13c
mov eax, dword [0x1006c144]
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 0x10002fd5
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
cmp eax, dword [ebp + 0xc4]
je 0x10002fd5
push dword [ebp + 0xc4]
push ebx
push 0x410
call dword [sym.imp.KERNEL32.dll_OpenProcess]
jmp 0x10002fdb
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
mov dword [ebp - 0x70], eax
cmp eax, ebx
je 0x1000314c
lea eax, [ebp - 0x6c]
push eax
push 8
push dword [ebp - 0x70]
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
je 0x1000314c
push 0x110
lea eax, [ebp - 0x60]
push ebx
push eax
mov dword [ebp - 0x64], 0x114
call fcn.1003af40
add esp, 0xc
lea eax, [ebp - 0x64]
push eax
call dword [sym.imp.KERNEL32.dll_GetVersionExW]
cmp dword [ebp - 0x60], 6
jb 0x10003069
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 0x1000314c
cmp dword [ebp - 0x68], 4
mov dword [ebp - 0x80], 1
jne 0x1000314c
xor eax, eax
cmp dword [ebp - 0x78], ebx
setne al
mov dword [esi], eax
jmp 0x1000314c
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 0x1000314c
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 0x1000314b
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 0x1000314b
lea eax, [ebp - 0x7c]
push eax
push dword [ebp - 0x7c]
push esi
push 2
push dword [ebp - 0x6c]
call edi
test eax, eax
je 0x1000313c
xor edi, edi
mov dword [ebp - 0x80], 1
cmp dword [esi], ebx
jbe 0x1000313c
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 0x10003133
add dword [ebp - 0x68], 8
inc edi
cmp edi, dword [esi]
jb 0x10003116
jmp 0x1000313c
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 0x1000315a
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 0x1000316a
push dword [ebp - 0x6c]
call esi
cmp dword [ebp - 0x70], ebx
je 0x10003174
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.1003a584
add ebp, 0xbc
leave
ret 8