Function at 0x403650
Capabilities:
Compare security identifiers

Disassembly:
push 0xffffffffffffffff
push 0x4507d9
mov eax, dword fs:[0]
push eax
sub esp, 0xc0
push ebx
push ebp
push esi
push edi
mov eax, dword [0x468110]
xor eax, esp
push eax
lea eax, [esp + 0xd4]
mov dword fs:[0], eax
xor ebx, ebx
mov dword [esp + 0x1c], ebx
mov byte [esp + 0x20], bl
mov dword [esp + 0x24], 2
mov dword [esp + 0x18], vtable.ATL::CDacl.0
mov dword [esp + 0x28], ebx
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
mov eax, dword [esp + 0xe4]
lea esi, [esp + 0x18]
mov dword [esp + 0xdc], ebx
call fcn.00403420
mov dword [esp + 0x3c], ebx
mov dword [esp + 0x40], ebx
mov dword [esp + 0x44], ebx
mov dword [esp + 0x48], ebx
mov dword [esp + 0x4c], ebx
mov dword [esp + 0x50], ebx
mov dword [esp + 0x54], ebx
mov dword [esp + 0x58], ebx
mov dword [esp + 0x60], ebx
mov dword [esp + 0x64], ebx
mov dword [esp + 0x68], ebx
mov dword [esp + 0x6c], ebx
lea eax, [esp + 0x60]
push eax
lea ecx, [esp + 0x40]
push ecx
mov edx, esi
push edx
lea edi, [esp + 0x58]
mov byte [esp + 0xe8], 3
call fcn.00402550
xor ebp, ebp
cmp dword [esp + 0x40], ebx
jbe 0x4037e5
mov dword [esp + 0x38], ebx
lea esi, [esp + 0x70]
call fcn.004024f0
mov byte [esp + 0xdc], 4
cmp ebp, dword [esp + 0x40]
jae 0x40382d
mov ecx, dword [esp + 0x3c]
mov edx, dword [esp + 0x38]
lea esi, [eax + 4]
lea edi, [edx + ecx]
mov dword [esp + 0x5c], edi
cmp esi, ebx
je 0x403793
add edi, 4
cmp edi, ebx
je 0x403793
cmp byte [eax + 0x48], bl
je 0x403793
push esi
call dword [sym.imp.ADVAPI32.dll_IsValidSid]
test eax, eax
setne al
cmp al, bl
je 0x403793
mov eax, dword [esp + 0x5c]
cmp byte [eax + 0x48], bl
je 0x403793
push edi
call dword [sym.imp.ADVAPI32.dll_IsValidSid]
test eax, eax
setne al
cmp al, bl
je 0x403793
push edi
push esi
call dword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
setne byte [esp + 0x17]
jmp 0x403797
mov byte [esp + 0x17], bl
lea ecx, [esp + 0x70]
mov byte [esp + 0xdc], 3
call fcn.00402270
cmp byte [esp + 0x17], bl
je 0x4037d5
cmp ebp, dword [esp + 0x50]
jae 0x40382d
mov ecx, dword [esp + 0x4c]
test dword [ecx + ebp*4], 0x1f01ff
je 0x4037d5
cmp ebp, dword [esp + 0x64]
jae 0x40382d
mov edx, dword [esp + 0x60]
test byte [edx + ebp], 3
jne 0x4038ab
add dword [esp + 0x38], 0x60
inc ebp
cmp ebp, dword [esp + 0x40]
jb 0x40371c
mov edi, dword [esp + 0x28]
cmp edi, ebx
je 0x403837
mov eax, dword [esp + 0x2c]
xor esi, esi
mov ebp, eax
cmp eax, ebx
jbe 0x40381b
lea esp, [esp]
mov ecx, dword [edi + esi*4]
cmp ecx, ebx
je 0x40380f
mov eax, dword [ecx]
mov edx, dword [eax]
push 1
call edx
mov dword [edi + esi*4], ebx
inc esi
cmp esi, ebp
jb 0x403800
mov edi, dword [esp + 0x28]
mov ebp, dword [sym.imp.MSVCR90.dll_free]
push edi
call ebp
add esp, 4
mov dword [esp + 0x28], ebx
jmp 0x40383d
push 0x80070057
call fcn.00401070
mov ebp, dword [sym.imp.MSVCR90.dll_free]
mov eax, dword [esp + 0x1c]
push eax
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
call ebp
add esp, 4
lea esi, [esp + 0x70]
mov dword [esp + 0x1c], ebx
call fcn.004024f0
lea ecx, [esp + 0x18]
push ecx
mov ecx, eax
mov byte [esp + 0xe0], 5
call fcn.004028c0
mov ecx, esi
mov byte [esp + 0xdc], 3
call fcn.00402270
mov edi, dword [esp + 0xe4]
cmp edi, ebx
je 0x4038b1
push ebx
lea esi, [esp + 0x1c]
call fcn.004026a0
push eax
push ebx
push ebx
push 4
push 1
push edi
call dword [sym.imp.ADVAPI32.dll_SetNamedSecurityInfoW]
push eax
call dword [sym.imp.KERNEL32.dll_SetLastError]
jmp 0x4038b1
mov ebp, dword [sym.imp.MSVCR90.dll_free]
mov eax, dword [esp + 0x60]
cmp eax, ebx
je 0x4038bf
push eax
call ebp
add esp, 4
mov eax, dword [esp + 0x4c]
cmp eax, ebx
je 0x4038cd
push eax
call ebp
add esp, 4
mov byte [esp + 0xdc], bl
mov esi, dword [esp + 0x3c]
cmp esi, ebx
je 0x4038ff
mov edi, dword [esp + 0x40]
cmp edi, ebx
jbe 0x4038f9
mov edx, dword [esi]
mov eax, dword [edx]
push ebx
mov ecx, esi
call eax
add esi, 0x60
sub edi, 1
jne 0x4038e4
mov esi, dword [esp + 0x3c]
push esi
call ebp
add esp, 4
mov dword [esp + 0xdc], 0xffffffff
mov edi, dword [esp + 0x28]
mov dword [esp + 0x18], vtable.ATL::CDacl.0
cmp edi, ebx
je 0x403955
mov eax, dword [esp + 0x2c]
xor esi, esi
mov ebp, eax
cmp eax, ebx
jbe 0x403941
mov ecx, dword [edi + esi*4]
cmp ecx, ebx
je 0x403935
mov edx, dword [ecx]
mov eax, dword [edx]
push 1
call eax
mov dword [edi + esi*4], ebx
inc esi
cmp esi, ebp
jb 0x403926
mov edi, dword [esp + 0x28]
push edi
call dword [sym.imp.MSVCR90.dll_free]
mov ebp, dword [sym.imp.MSVCR90.dll_free]
add esp, 4
mov dword [esp + 0x28], ebx
mov ecx, dword [esp + 0x1c]
push ecx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
call ebp
mov edi, dword [esp + 0x2c]
add esp, 4
mov dword [esp + 0x1c], ebx
cmp edi, ebx
je 0x4039ab
mov eax, dword [esp + 0x2c]
xor esi, esi
mov ebp, eax
cmp eax, ebx
jbe 0x40399b
nop
mov ecx, dword [edi + esi*4]
cmp ecx, ebx
je 0x40398f
mov edx, dword [ecx]
mov eax, dword [edx]
push 1
call eax
mov dword [edi + esi*4], ebx
inc esi
cmp esi, ebp
jb 0x403980
mov edi, dword [esp + 0x28]
push edi
call dword [sym.imp.MSVCR90.dll_free]
mov ebp, dword [sym.imp.MSVCR90.dll_free]
add esp, 4
mov ecx, dword [esp + 0x1c]
push ecx
mov dword [esp + 0x1c], vtable.ATL::CAcl.0
call ebp
add esp, 4
mov ecx, dword [esp + 0xd4]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
add esp, 0xcc
ret 4