Function at 0x403dd0
Capabilities:
Compare security identifiers

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1cc
mov eax, dword [0x490274]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
mov dword [ebp - 0x1c0], eax
lea eax, [ebp - 0x13c]
mov dword [ebp - 0x17c], eax
lea eax, [ebp - 0x15c]
push eax
push 0
push 0
push 0xa
push esi
mov dword [ebp - 0x14c], esi
mov dword [ebp - 0x158], 0
mov dword [ebp - 0x13c], 0xc
mov dword [ebp - 0x138], 1
mov word [ebp - 0x134], 0
mov dword [ebp - 0x190], 0x18
mov dword [ebp - 0x18c], 0
mov dword [ebp - 0x188], 0
mov dword [ebp - 0x184], 0
mov dword [ebp - 0x180], 0
call edi
test eax, eax
jne 0x403e82
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x403eb8
push dword [ebp - 0x15c]
call fcn.00436157
add esp, 4
mov ebx, eax
lea eax, [ebp - 0x15c]
mov dword [ebp - 0x148], ebx
push eax
push dword [ebp - 0x15c]
push ebx
push 0xa
push esi
call edi
test eax, eax
jne 0x403ec0
push ebx
call fcn.00453d20
add esp, 4
xor ebx, ebx
mov dword [ebp - 0x148], ebx
mov eax, dword [ebx + 8]
mov dword [ebp - 0x128], eax
mov eax, dword [ebx + 0xc]
xor ebx, ebx
mov dword [ebp - 0x124], eax
lea eax, [ebp - 0x150]
push eax
push ebx
push ebx
push 2
push esi
mov dword [ebp - 0x150], 0
mov dword [ebp - 0x1b4], ebx
call edi
lea eax, [ebp - 0x154]
mov dword [ebp - 0x154], ebx
push eax
push str.S_1_5_32_544
call dword [sym.imp.ADVAPI32.dll_ConvertStringSidToSidW]
test eax, eax
je 0x404519
lea eax, [ebp - 0x16c]
mov dword [ebp - 0x16c], ebx
push eax
push str.S_1_16_12288
call dword [sym.imp.ADVAPI32.dll_ConvertStringSidToSidW]
test eax, eax
je 0x404519
lea eax, [ebp - 0x170]
mov dword [ebp - 0x170], ebx
push eax
push str.S_1_5_114
call dword [sym.imp.ADVAPI32.dll_ConvertStringSidToSidW]
test eax, eax
je 0x404519
mov eax, dword [ebp - 0x150]
test eax, eax
je 0x404086
push eax
call fcn.00453d3b
add esp, 4
mov ebx, eax
lea eax, [ebp - 0x150]
mov dword [ebp - 0x1b4], ebx
push eax
push dword [ebp - 0x150]
push ebx
push 2
push esi
call edi
xor edi, edi
mov byte [ebp - 0x144], 0
cmp dword [ebx], edi
jbe 0x404006
lea esi, [ebx + 8]
test byte [esi], 0x10
je 0x403f9f
mov dword [esi], 0xd
push dword [ebp - 0x170]
push dword [esi - 4]
call dword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
je 0x403fbf
mov dword [esi], 5
mov eax, 5
jmp 0x403fc1
mov eax, dword [esi]
test al, 0x20
je 0x403fce
mov eax, dword [ebp - 0x16c]
mov dword [esi - 4], eax
push dword [ebp - 0x154]
push dword [esi - 4]
call dword [sym.imp.ADVAPI32.dll_EqualSid]
mov ecx, dword [ebp - 0x144]
test eax, eax
movzx ecx, cl
mov eax, 1
cmovne ecx, eax
inc edi
add esi, 8
mov dword [ebp - 0x144], ecx
cmp edi, dword [ebx]
jb 0x403f94
test cl, cl
jne 0x404086
mov eax, dword [ebp - 0x150]
xor ecx, ecx
add eax, 8
setb cl
neg ecx
or ecx, eax
push ecx
call fcn.00453d3b
mov edi, eax
add esp, 4
mov eax, dword [ebx]
xor esi, esi
mov dword [ebp - 0x144], edi
test eax, eax
je 0x40405e
lea ecx, [edi + 4]
mov edi, ebx
sub edi, dword [ebp - 0x144]
lea edx, [ebx + 8]
nop
mov eax, dword [edi + ecx]
lea edx, [edx + 8]
mov dword [ecx], eax
lea ecx, [ecx + 8]
mov eax, dword [edx - 8]
inc esi
mov dword [ecx - 4], eax
mov eax, dword [ebx]
cmp esi, eax
jb 0x404040
mov edi, dword [ebp - 0x144]
inc eax
mov dword [edi], eax
mov ecx, dword [ebx]
mov eax, dword [ebp - 0x154]
push ebx
mov dword [edi + ecx*8 + 4], eax
mov eax, dword [ebx]
mov dword [edi + eax*8 + 8], 0xd
call fcn.00453d20
add esp, 4
mov dword [ebp - 0x1b4], edi
xor esi, esi
lea edi, [ebp - 0x118]
xorps xmm0, xmm0
movlpd qword [ebp - 0x130], xmm0
lea ebx, [esi + 3]
nop dword [eax]
lea eax, [ebp - 0x130]
push eax
push dword [esi + 0x490c80]
push 0
call dword [sym.imp.ADVAPI32.dll_LookupPrivilegeValueW]
test eax, eax
je 0x4040d8
mov eax, dword [ebp - 0x130]
mov dword [edi - 8], eax
mov eax, dword [ebp - 0x12c]
mov dword [edi - 4], eax
xor eax, eax
cmp byte [esi + 0x490c84], al
cmovne eax, ebx
mov dword [edi], eax
add esi, 8
add edi, 0xc
cmp esi, 0xb8
jb 0x4040a0
push 0x118
call fcn.00453d3b
add esp, 4
mov dword [ebp - 0x1c8], eax
mov ecx, 0x45
lea esi, [ebp - 0x120]
mov dword [eax], 0x17
lea edi, [eax + 4]
lea eax, [ebp - 0x160]
push eax
push 0
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [ebp - 0x154]
mov edi, dword [ebp - 0x14c]
mov esi, dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
push 0
push 6
push edi
mov dword [ebp - 0x178], ecx
call esi
mov ebx, dword [ebp - 0x1b4]
test eax, eax
jne 0x404156
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
je 0x404156
xor eax, eax
mov dword [ebp - 0x1b8], eax
jmp 0x40419f
push dword [ebp - 0x160]
call fcn.00436157
add esp, 4
mov dword [ebp - 0x1b8], eax
lea ecx, [ebp - 0x160]
push ecx
push dword [ebp - 0x160]
push eax
push 6
push edi
call esi
test eax, eax
jne 0x404199
push dword [ebp - 0x1b8]
call fcn.00453d20
add esp, 4
xor eax, eax
mov dword [ebp - 0x1b8], eax
jmp 0x40419f
mov eax, dword [ebp - 0x1b8]
mov esi, dword [eax]
xorps xmm0, xmm0
mov eax, dword [ebp - 0x154]
push 0
push esi
movlpd qword [ebp - 0x1a4], xmm0
mov dword [ebp - 0x198], 0
mov dword [ebp - 0x1b0], 0x10000000
mov dword [ebp - 0x1ac], 1
mov dword [ebp - 0x1a8], 0
mov dword [ebp - 0x19c], 0
mov dword [ebp - 0x194], eax
call dword [sym.imp.ADVAPI32.dll_DeleteAce]
lea eax, [ebp - 0x174]
push eax
lea eax, [ebp - 0x140]
push eax
push esi
call dword [sym.imp.ADVAPI32.dll_GetExplicitEntriesFromAclW]
mov esi, dword [sym.imp.ADVAPI32.dll_SetEntriesInAclW]
lea eax, [ebp - 0x164]
push eax
push 0
push dword [ebp - 0x174]
push 2
call esi
lea eax, [ebp - 0x164]
push eax
push dword [ebp - 0x164]
lea eax, [ebp - 0x1b0]
push eax
push 1
call esi
mov ecx, dword [ebp - 0x1b8]
mov eax, dword [ebp - 0x164]
mov dword [ecx], eax
mov ecx, dword [ebp - 0x1c0]
mov eax, dword [ecx + 4]
mov dword [ebp - 0x124], eax
mov eax, dword [ecx]
mov ecx, dword [0x495a74]
mov dword [ebp - 0x128], eax
mov dword [ebp - 0x1c0], ecx
test ecx, ecx
je 0x404277
mov eax, dword [0x495a70]
test eax, eax
jne 0x4042b6
push str.ntdll.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov edi, eax
push str.ZwCreateToken
push edi
call esi
push str.RtlNtStatusToDosError
push edi
mov dword [0x495a74], eax
call esi
mov ecx, dword [0x495a74]
mov edi, dword [ebp - 0x14c]
mov dword [0x495a70], eax
mov dword [ebp - 0x1c0], ecx
test ecx, ecx
je 0x404519
test eax, eax
je 0x404519
mov esi, dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
lea eax, [ebp - 0x168]
push eax
push 0
push 0
push 7
push edi
call esi
test eax, eax
jne 0x4042eb
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x404324
push dword [ebp - 0x168]
call fcn.00436157
add esp, 4
mov dword [ebp - 0x1bc], eax
lea ecx, [ebp - 0x168]
push ecx
push dword [ebp - 0x168]
push eax
push 7
push edi
call esi
test eax, eax
jne 0x40432e
push dword [ebp - 0x1bc]
call fcn.00453d20
add esp, 4
mov dword [ebp - 0x1bc], 0
lea eax, [ebp - 0x14c]
push eax
push 0
push 0
push 5
push edi
call esi
test eax, eax
jne 0x40434d
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x404386
push dword [ebp - 0x14c]
call fcn.00436157
add esp, 4
mov dword [ebp - 0x1b4], eax
lea ecx, [ebp - 0x14c]
push ecx
push dword [ebp - 0x14c]
push eax
push 5
push edi
call esi
test eax, eax
jne 0x404390
push dword [ebp - 0x1b4]
call fcn.00453d20
add esp, 4
mov dword [ebp - 0x1b4], 0
lea eax, [ebp - 0x144]
push eax
push 0
push 0
push 1
push edi
call esi
test eax, eax
jne 0x4043af
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x4043e9
push dword [ebp - 0x144]
call fcn.00436157
add esp, 4
mov dword [ebp - 0x1c4], eax
lea ecx, [ebp - 0x144]
push ecx
push dword [ebp - 0x144]
push eax
push 1
push edi
call esi
test eax, eax
mov eax, dword [ebp - 0x1c4]
jne 0x4043eb
push eax
call fcn.00453d20
add esp, 4
xor eax, eax
push dword [ebp - 0x1bc]
lea ecx, [ebp - 0x178]
push dword [ebp - 0x1b8]
push dword [ebp - 0x1b4]
push ecx
push dword [ebp - 0x1c8]
push ebx
push eax
mov eax, dword [ebp - 0x148]
add eax, 0x10
push eax
lea eax, [ebp - 0x128]
push eax
push 1
lea eax, [ebp - 0x190]
push eax
push 0xf01ff
lea eax, [ebp - 0x158]
push eax
call dword [ebp - 0x1c0]
mov ecx, dword [0x495a70]
mov esi, eax
push esi
call ecx
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
test esi, esi
js 0x40450c
cmp dword [ebp - 0x158], 0
je 0x40450c
test ebx, ebx
je 0x40446c
push ebx
call fcn.00453d20
add esp, 4
mov eax, dword [ebp - 0x16c]
test eax, eax
je 0x40447d
push eax
call dword [sym.imp.KERNEL32.dll_LocalFree]
push dword [ebp - 0x1c8]
call fcn.00453d20
mov ebx, dword [sym.imp.ADVAPI32.dll_GetTokenInformation]
lea eax, [ebp - 0x148]
add esp, 4
push eax
push 0
push 0
push 0x11
push edi
call ebx
test eax, eax
jne 0x4044b0
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
jne 0x4044e0
push dword [ebp - 0x148]
call fcn.00436157
add esp, 4
mov esi, eax
lea eax, [ebp - 0x148]
push eax
push dword [ebp - 0x148]
push esi
push 0x11
push edi
call ebx
test eax, eax
jne 0x4044e2
push esi
call fcn.00453d20
add esp, 4
xor esi, esi
push 8
push esi
push 0x11
push dword [ebp - 0x158]
call dword [sym.imp.ADVAPI32.dll_SetTokenInformation]
mov eax, dword [ebp - 0x158]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00435bdb
mov esp, ebp
pop ebp
ret 8
test ebx, ebx
je 0x404519
push ebx
call fcn.00453d20
add esp, 4
mov ecx, dword [ebp - 4]
xor eax, eax
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00435bdb
mov esp, ebp
pop ebp
ret 8