Function at 0x10463fe
Capabilities:
Compare security identifiers
Get token privileges

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x24
mov eax, dword [ebp + 8]
push edi
xor edi, edi
mov dword [eax], edi
mov eax, dword [ebp + 0xc]
mov dword [eax], 1
mov eax, dword [ebp + 0x10]
mov dword [eax], edi
lea eax, [ebp - 0xc]
push eax
push 8
mov dword [ebp - 0xc], edi
mov dword [ebp - 0x14], edi
mov dword [ebp - 0x1c], edi
mov dword [ebp - 8], edi
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
jne 0x104644d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 4], eax
jmp 0x1046690
push ebx
push esi
mov esi, dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
lea eax, [ebp - 8]
push eax
push edi
push edi
push 2
push dword [ebp - 0xc]
mov dword [ebp - 8], edi
call esi
push dword [ebp - 8]
call sub.NMSUPP.dll_AllocMemory
mov ebx, eax
cmp ebx, edi
mov dword [ebp - 0x20], ebx
je 0x1046572
lea eax, [ebp - 8]
push eax
push dword [ebp - 8]
push ebx
push 2
push dword [ebp - 0xc]
call esi
test eax, eax
je 0x1046537
lea eax, [ebp - 0x10]
push eax
mov dword [ebp - 0x10], edi
call fcn.0104638e
cmp eax, edi
mov dword [ebp - 4], eax
jne 0x1046674
cmp dword [ebx], edi
mov dword [ebp - 0x24], edi
mov dword [ebp - 0x18], edi
jbe 0x10464e5
add ebx, 8
push dword [ebp - 0x10]
push dword [ebx - 4]
call dword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
je 0x10464d0
xor eax, eax
inc eax
test byte [ebx], 0x10
mov dword [ebp - 0x1c], eax
je 0x10464e2
inc dword [ebp - 0x18]
mov eax, dword [ebp - 0x20]
mov ecx, dword [ebp - 0x18]
add ebx, 8
cmp ecx, dword [eax]
jb 0x10464b5
jmp 0x10464e5
mov dword [ebp - 0x24], eax
push dword [ebp - 0x10]
call dword [sym.imp.ADVAPI32.dll_FreeSid]
mov eax, dword [ebp - 0x1c]
cmp eax, edi
mov ecx, dword [ebp + 0x10]
mov dword [ecx], eax
je 0x104654c
cmp dword [ebp - 0x24], edi
jne 0x1046674
lea eax, [ebp - 8]
push eax
push edi
push edi
push 3
push dword [ebp - 0xc]
mov dword [ebp - 8], edi
call esi
push dword [ebp - 8]
call sub.NMSUPP.dll_AllocMemory
mov ebx, eax
cmp ebx, edi
mov dword [ebp - 0x14], ebx
je 0x1046572
lea eax, [ebp - 8]
push eax
push dword [ebp - 8]
push ebx
push 3
push dword [ebp - 0xc]
call esi
test eax, eax
jne 0x1046545
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 4], eax
jmp 0x1046674
mov ebx, dword [ebx]
cmp ebx, 1
jae 0x1046556
mov eax, dword [ebp + 0xc]
mov dword [eax], edi
jmp 0x1046674
ja 0x1046674
push 0x20a
mov esi, 0x104
call sub.NMSUPP.dll_AllocMemory
cmp eax, edi
mov dword [ebp + 0x10], eax
jne 0x104657e
mov dword [ebp - 4], 0xe
jmp 0x1046674
mov eax, dword [ebp - 0x14]
cmp dword [eax], edi
mov dword [ebp - 0x1c], edi
jbe 0x1046652
mov ebx, dword [sym.imp.ADVAPI32.dll_LookupPrivilegeNameW]
add eax, 4
mov dword [ebp - 0x18], eax
mov edi, dword [ebp + 0x10]
lea ecx, [esi + esi + 2]
mov edx, ecx
shr ecx, 2
xor eax, eax
mov dword [ebp - 0x10], esi
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
lea eax, [ebp - 0x10]
push eax
push dword [ebp + 0x10]
push dword [ebp - 0x18]
push 0
call ebx
test eax, eax
jne 0x104662d
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
mov dword [ebp - 4], eax
jne 0x1046650
cmp dword [ebp - 0x10], esi
jbe 0x1046650
push dword [ebp + 0x10]
and dword [ebp - 4], 0
call sub.NMSUPP.dll_FreeMemory
mov eax, dword [ebp - 0x10]
lea eax, [eax + eax + 2]
push eax
call sub.NMSUPP.dll_AllocMemory
mov edx, eax
test edx, edx
mov dword [ebp + 0x10], edx
je 0x10466bd
mov ecx, dword [ebp - 0x10]
lea ecx, [ecx + ecx + 2]
mov esi, ecx
shr ecx, 2
xor eax, eax
mov edi, edx
rep stosd dword es:[edi], eax
mov ecx, esi
and ecx, 3
rep stosb byte es:[edi], al
mov esi, dword [ebp - 0x10]
lea eax, [ebp - 0x10]
push eax
push edx
push dword [ebp - 0x18]
push 0
call ebx
test eax, eax
je 0x10466c8
xor edi, edi
push dword [edi + 0x1004ea0]
push dword [ebp + 0x10]
call dword [sym.imp.KERNEL32.dll_lstrcmpiW]
test eax, eax
je 0x10466a6
add edi, 4
cmp edi, 4
jb 0x104662f
mov eax, dword [ebp + 0xc]
and dword [eax], 0
xor edi, edi
cmp dword [ebp + 0x10], edi
je 0x104665f
push dword [ebp + 0x10]
call sub.NMSUPP.dll_FreeMemory
cmp dword [ebp - 4], edi
jne 0x1046674
mov eax, dword [ebp + 0xc]
cmp dword [eax], edi
je 0x1046674
mov eax, dword [ebp + 8]
mov dword [eax], 1
cmp dword [ebp - 0x20], edi
pop esi
pop ebx
je 0x1046683
push dword [ebp - 0x20]
call sub.NMSUPP.dll_FreeMemory
cmp dword [ebp - 0x14], edi
je 0x1046690
push dword [ebp - 0x14]
call sub.NMSUPP.dll_FreeMemory
cmp dword [ebp - 0xc], edi
pop edi
je 0x104669f
push dword [ebp - 0xc]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [ebp - 4]
leave
ret 0xc
inc dword [ebp - 0x1c]
mov eax, dword [ebp - 0x14]
mov ecx, dword [ebp - 0x1c]
add dword [ebp - 0x18], 0xc
cmp ecx, dword [eax]
jb 0x1046598
jmp 0x1046650
mov dword [ebp - 4], 0xe
xor edi, edi
jmp 0x1046674
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 4], eax
jmp 0x1046650