Function at 0x1002cae0
Capabilities:
Compare security identifiers
Get user security identifier

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2ac
mov eax, dword [0x101120a8]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
xorps xmm0, xmm0
push ebx
mov ebx, dword [ebp + 8]
add eax, 4
push esi
xor esi, esi
mov dword [ebp - 0x28c], 0xc8
push edi
xor edi, edi
mov dword [ebp - 0x288], 0xc8
cmp dword [eax + 0x14], 8
mov dword [ebp - 0x27c], 0
mov dword [ebp - 0x274], 0
movq qword [ebp - 0x268], xmm0
mov dword [ebp - 0x260], edi
movups xmmword [ebp - 0x2ac], xmm0
mov dword [ebp - 0x29c], edi
mov dword [ebp - 0x278], edi
mov dword [ebp - 0x26c], edi
mov dword [ebp - 0x290], edi
mov dword [ebp - 0x270], edi
mov dword [ebp - 0x280], esi
mov dword [ebp - 0x298], esi
mov dword [ebp - 0x284], 8
jb 0x1002cb7f
mov eax, dword [eax]
lea ecx, [ebp - 0x284]
push ecx
lea ecx, [ebp - 0x288]
push ecx
lea ecx, [ebp - 0x25c]
push ecx
lea ecx, [ebp - 0x28c]
push ecx
lea ecx, [ebp - 0xcc]
push ecx
push eax
push 0
call dword [sym.imp.ADVAPI32.dll_LookupAccountNameW]
test eax, eax
jne 0x1002cbc5
pop edi
pop esi
mov eax, 0xfffffffe
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1008bffe
mov esp, ebp
pop ebp
ret
push 1
lea eax, [ebp - 0x2ac]
push eax
call dword [sym.imp.ADVAPI32.dll_InitializeSecurityDescriptor]
test eax, eax
jne 0x1002cbee
pop edi
pop esi
mov eax, 0xfffffffd
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1008bffe
mov esp, ebp
pop ebp
ret
add ebx, 4
mov eax, ebx
cmp dword [ebx + 0x14], 8
jb 0x1002cbfb
mov eax, dword [ebx]
lea ecx, [ebp - 0x274]
push ecx
push 0
push 0
push 4
push eax
call dword [sym.imp.ADVAPI32.dll_GetFileSecurityW]
test eax, eax
jne 0x1002cc9a
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
je 0x1002cc38
pop edi
pop esi
mov eax, 0xfffffffc
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1008bffe
mov esp, ebp
pop ebp
ret
push dword [ebp - 0x274]
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov ecx, eax
mov dword [ebp - 0x27c], ecx
test ecx, ecx
jne 0x1002cc6d
pop edi
pop esi
lea eax, [ecx - 5]
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.1008bffe
mov esp, ebp
pop ebp
ret
cmp dword [ebx + 0x14], 8
mov eax, ebx
jb 0x1002cc77
mov eax, dword [ebx]
lea edx, [ebp - 0x274]
push edx
push dword [ebp - 0x274]
push ecx
push 4
push eax
call dword [sym.imp.ADVAPI32.dll_GetFileSecurityW]
test eax, eax
jne 0x1002cc9a
lea esi, [eax - 6]
jmp 0x1002cf0a
lea eax, [ebp - 0x290]
push eax
lea eax, [ebp - 0x278]
push eax
lea eax, [ebp - 0x26c]
push eax
push dword [ebp - 0x27c]
call dword [sym.imp.ADVAPI32.dll_GetSecurityDescriptorDacl]
test eax, eax
jne 0x1002ccc7
lea esi, [eax - 7]
jmp 0x1002cf0a
mov eax, dword [ebp - 0x278]
mov dword [ebp - 0x264], 8
test eax, eax
jne 0x1002cd1d
mov dword [ebp - 0x26c], esi
lea eax, [ebp - 0xcc]
push eax
call dword [sym.imp.ADVAPI32.dll_GetLengthSid]
mov ecx, dword [ebp - 0x264]
add ecx, 8
add eax, ecx
push eax
push 8
mov dword [ebp - 0x294], eax
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov edi, eax
test edi, edi
jne 0x1002cd43
lea esi, [eax - 9]
jmp 0x1002cf0a
cmp dword [ebp - 0x26c], esi
je 0x1002cce1
push 2
push 0xc
lea ecx, [ebp - 0x268]
push ecx
push eax
call dword [sym.imp.ADVAPI32.dll_GetAclInformation]
test eax, eax
jne 0x1002cce1
lea esi, [eax - 8]
jmp 0x1002cf0a
push 2
push dword [ebp - 0x294]
push edi
call dword [sym.imp.ADVAPI32.dll_InitializeAcl]
test eax, eax
jne 0x1002cd5e
lea esi, [eax - 0xa]
jmp 0x1002cf0a
cmp dword [ebp - 0x26c], esi
je 0x1002cdd3
mov eax, dword [ebp - 0x268]
test eax, eax
je 0x1002cdd3
xor esi, esi
test eax, eax
je 0x1002cdd3
lea eax, [ebp - 0x270]
push eax
push esi
push dword [ebp - 0x278]
call dword [sym.imp.ADVAPI32.dll_GetAce]
test eax, eax
je 0x1002cdfe
mov eax, dword [ebp - 0x270]
test byte [eax + 1], 0x10
jne 0x1002cdd3
add eax, 8
push eax
lea eax, [ebp - 0xcc]
push eax
call dword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
jne 0x1002cdca
mov ecx, dword [ebp - 0x270]
movzx eax, word [ecx + 2]
push eax
push ecx
push 0xffffffffffffffff
push 2
push edi
call dword [sym.imp.ADVAPI32.dll_AddAce]
test eax, eax
je 0x1002cdf4
inc esi
cmp esi, dword [ebp - 0x268]
jb 0x1002cd76
lea eax, [ebp - 0xcc]
push eax
push dword [ebp + 0x10]
push 3
push 2
push edi
call dword [sym.imp.ADVAPI32.dll_AddAccessAllowedAceEx]
test eax, eax
jne 0x1002ce08
lea esi, [eax - 0xd]
jmp 0x1002cf0a
mov esi, 0xfffffff4
jmp 0x1002cf0a
mov esi, 0xfffffff5
jmp 0x1002cf0a
cmp dword [ebp - 0x26c], 0
je 0x1002ce5c
mov eax, dword [ebp - 0x268]
test eax, eax
je 0x1002ce5c
cmp esi, eax
jae 0x1002ce5c
nop
lea eax, [ebp - 0x270]
push eax
push esi
push dword [ebp - 0x278]
call dword [sym.imp.ADVAPI32.dll_GetAce]
test eax, eax
je 0x1002ce84
mov ecx, dword [ebp - 0x270]
movzx eax, word [ecx + 2]
push eax
push ecx
push 0xffffffffffffffff
push 2
push edi
call dword [sym.imp.ADVAPI32.dll_AddAce]
test eax, eax
je 0x1002ce7a
inc esi
cmp esi, dword [ebp - 0x268]
jb 0x1002ce20
push 0
push edi
push 1
lea eax, [ebp - 0x2ac]
push eax
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorDacl]
test eax, eax
jne 0x1002ce8b
lea esi, [eax - 0x10]
jmp 0x1002cf0a
mov esi, 0xfffffff1
jmp 0x1002cf0a
mov esi, 0xfffffff2
jmp 0x1002cf0a
lea eax, [ebp - 0x298]
push eax
lea eax, [ebp - 0x280]
push eax
push dword [ebp - 0x27c]
call dword [sym.imp.ADVAPI32.dll_GetSecurityDescriptorControl]
test eax, eax
jne 0x1002ceae
lea esi, [eax - 0x11]
jmp 0x1002cf0a
mov eax, dword [ebp - 0x280]
test eax, 0x400
je 0x1002cec2
mov eax, 0x500
jmp 0x1002cece
test eax, 0x1000
je 0x1002cee6
mov eax, 0x1000
push eax
push eax
lea eax, [ebp - 0x2ac]
push eax
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorControl]
test eax, eax
jne 0x1002cee6
lea esi, [eax - 0x12]
jmp 0x1002cf0a
cmp dword [ebx + 0x14], 8
jb 0x1002ceee
mov ebx, dword [ebx]
lea eax, [ebp - 0x2ac]
push eax
push 4
push ebx
call dword [sym.imp.ADVAPI32.dll_SetFileSecurityW]
mov esi, eax
neg esi
sbb esi, esi
and esi, 0x13
add esi, 0xffffffed
mov eax, dword [ebp - 0x27c]
mov ebx, dword [sym.imp.KERNEL32.dll_HeapFree]
test eax, eax
je 0x1002cf26
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call ebx
test edi, edi
je 0x1002cf36
push edi
push 0
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call ebx
mov ecx, dword [ebp - 4]
mov eax, esi
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1008bffe
mov esp, ebp
pop ebp
ret