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

Disassembly:
push 0x68
push 0x4e9d30
call fcn.00440b98
xor ebx, ebx
mov dword [ebp - 0x44], ebx
mov dword [ebp - 0x3c], ebx
mov dword [ebp - 0x20], ebx
mov dword [ebp - 0x40], ebx
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x34], ebx
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x4c], ebx
mov dword [ebp - 4], ebx
lea eax, [ebp - 0x50]
push eax
lea eax, [ebp - 0x3c]
push eax
push ebx
lea eax, [ebp - 0x40]
push eax
push ebx
push dword [ebp + 0xc]
push ebx
mov edi, dword [sym.imp.ADVAPI32.dll_LookupAccountNameW]
call edi
cmp eax, ebx
jne 0x42b9b0
mov esi, dword [sym.imp.KERNEL32.dll_GetLastError]
call esi
cmp eax, 0x7a
je 0x42b604
call esi
push eax
push str.LookupAccountName___failed._Error__d_n
call fcn.00444dbc
pop ecx
pop ecx
jmp 0x42b9b0
push dword [ebp - 0x40]
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
mov esi, dword [sym.imp.KERNEL32.dll_HeapAlloc]
call esi
mov dword [ebp - 0x20], eax
cmp eax, ebx
jne 0x42b62d
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.HeapAlloc___failed._Error__d_n
jmp 0x42b5f8
mov eax, dword [ebp - 0x3c]
add eax, eax
push eax
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call esi
mov dword [ebp - 0x44], eax
cmp eax, ebx
je 0x42b61f
lea ecx, [ebp - 0x50]
push ecx
lea ecx, [ebp - 0x3c]
push ecx
push eax
lea eax, [ebp - 0x40]
push eax
push dword [ebp - 0x20]
push dword [ebp + 0xc]
push ebx
call edi
cmp eax, ebx
jne 0x42b667
call dword [sym.imp.KERNEL32.dll_GetLastError]
jmp 0x42b5f2
lea eax, [ebp - 0x34]
push eax
push ebx
push ebx
push 4
push dword [ebp + 8]
mov edi, dword [sym.imp.ADVAPI32.dll_GetFileSecurityW]
call edi
cmp eax, ebx
jne 0x42b9b0
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
je 0x42b69e
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetFileSecurity___failed._Error__d_n
jmp 0x42b5f8
push dword [ebp - 0x34]
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call esi
mov dword [ebp - 0x30], eax
cmp eax, ebx
je 0x42b61f
lea ecx, [ebp - 0x34]
push ecx
push dword [ebp - 0x34]
push eax
push 4
push dword [ebp + 8]
call edi
cmp eax, ebx
je 0x42b68d
push 1
lea eax, [ebp - 0x78]
push eax
call dword [sym.imp.ADVAPI32.dll_InitializeSecurityDescriptor]
test eax, eax
jne 0x42b6eb
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.InitializeSecurityDescriptor___failed.Error__d_n
jmp 0x42b5f8
lea eax, [ebp - 0x58]
push eax
lea eax, [ebp - 0x28]
push eax
lea eax, [ebp - 0x38]
push eax
push dword [ebp - 0x30]
call dword [sym.imp.ADVAPI32.dll_GetSecurityDescriptorDacl]
test eax, eax
jne 0x42b715
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetSecurityDescriptorDacl___failed._Error__d_n
jmp 0x42b5f8
mov dword [ebp - 0x64], ebx
mov dword [ebp - 0x5c], ebx
mov dword [ebp - 0x60], 8
cmp dword [ebp - 0x28], ebx
jne 0x42b72a
mov dword [ebp - 0x38], ebx
cmp dword [ebp - 0x38], ebx
je 0x42b755
push 2
push 0xc
lea eax, [ebp - 0x64]
push eax
push dword [ebp - 0x28]
call dword [sym.imp.ADVAPI32.dll_GetAclInformation]
test eax, eax
jne 0x42b755
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetAclInformation___failed._Error__d_n
jmp 0x42b5f8
push dword [ebp - 0x20]
call dword [sym.imp.ADVAPI32.dll_GetLengthSid]
mov ecx, dword [ebp - 0x60]
lea edi, [eax + ecx + 8]
push edi
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call esi
mov esi, eax
mov dword [ebp - 0x24], esi
cmp esi, ebx
je 0x42b61f
push 2
push edi
push esi
call dword [sym.imp.ADVAPI32.dll_InitializeAcl]
test eax, eax
jne 0x42b79d
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.InitializeAcl___failed._Error__d_n
jmp 0x42b5f8
mov dword [ebp - 0x48], ebx
cmp dword [ebp - 0x38], ebx
je 0x42b829
cmp dword [ebp - 0x64], ebx
je 0x42b829
mov dword [ebp - 0x1c], ebx
mov eax, dword [ebp - 0x64]
cmp dword [ebp - 0x1c], eax
jae 0x42b829
lea eax, [ebp - 0x2c]
push eax
push dword [ebp - 0x1c]
push dword [ebp - 0x28]
call dword [sym.imp.ADVAPI32.dll_GetAce]
test eax, eax
jne 0x42b7de
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetAce___failed._Error__d_n
jmp 0x42b5f8
mov eax, dword [ebp - 0x2c]
test byte [eax + 1], 0x10
jne 0x42b829
add eax, 8
push eax
push dword [ebp - 0x20]
call dword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
jne 0x42b824
mov eax, dword [ebp - 0x2c]
movzx ecx, word [eax + 2]
push ecx
push eax
push 0xffffffffffffffff
push 2
push esi
call dword [sym.imp.ADVAPI32.dll_AddAce]
test eax, eax
jne 0x42b821
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.AddAce___failed._Error__d_n
jmp 0x42b5f8
inc dword [ebp - 0x48]
inc dword [ebp - 0x1c]
jmp 0x42b7b1
push str.AddAccessAllowedAceEx
push 0x4caafc
mov edi, dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
call edi
push eax
mov esi, dword [sym.imp.KERNEL32.dll_GetProcAddress]
call esi
push dword [ebp - 0x20]
push dword [ebp + 0x10]
cmp eax, ebx
je 0x42b86c
push 3
push 2
push dword [ebp - 0x24]
call eax
test eax, eax
jne 0x42b88c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.AddAccessAllowedAceEx___failed._Error__d_n
jmp 0x42b5f8
push 2
push dword [ebp - 0x24]
call dword [sym.imp.ADVAPI32.dll_AddAccessAllowedAce]
test eax, eax
jne 0x42b88c
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.AddAccessAllowedAce___failed._Error__d_n
jmp 0x42b5f8
cmp dword [ebp - 0x38], ebx
je 0x42b8d7
cmp dword [ebp - 0x64], ebx
je 0x42b8d7
mov eax, dword [ebp - 0x1c]
cmp eax, dword [ebp - 0x64]
jae 0x42b8d7
lea ecx, [ebp - 0x2c]
push ecx
push eax
push dword [ebp - 0x28]
call dword [sym.imp.ADVAPI32.dll_GetAce]
test eax, eax
je 0x42b7cd
mov eax, dword [ebp - 0x2c]
movzx ecx, word [eax + 2]
push ecx
push eax
push 0xffffffffffffffff
push 2
push dword [ebp - 0x24]
call dword [sym.imp.ADVAPI32.dll_AddAce]
test eax, eax
je 0x42b810
inc dword [ebp - 0x1c]
jmp 0x42b896
push ebx
push dword [ebp - 0x24]
push 1
lea eax, [ebp - 0x78]
push eax
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorDacl]
test eax, eax
jne 0x42b8fc
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.SetSecurityDescriptorDacl___failed._Error__d_n
jmp 0x42b5f8
push str.SetSecurityDescriptorControl
push 0x4caafc
call edi
push eax
call esi
mov dword [ebp - 0x54], eax
cmp eax, ebx
je 0x42b983
xor esi, esi
xor edi, edi
mov dword [ebp + 0xc], ebx
mov dword [ebp + 0x10], ebx
lea eax, [ebp + 0x10]
push eax
lea eax, [ebp + 0xc]
push eax
push dword [ebp - 0x30]
call dword [sym.imp.ADVAPI32.dll_GetSecurityDescriptorControl]
test eax, eax
jne 0x42b942
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetSecurityDescriptorControl___failed.Error__d_n
jmp 0x42b5f8
test word [ebp + 0xc], 0x400
je 0x42b951
mov eax, 0x500
jmp 0x42b95c
mov eax, 0x1000
test word [ebp + 0xc], ax
je 0x42b960
mov edi, eax
mov esi, eax
cmp si, bx
je 0x42b983
push edi
push esi
lea eax, [ebp - 0x78]
push eax
call dword [ebp - 0x54]
test eax, eax
jne 0x42b983
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.SetSecurityDescriptorControl___failed.Error__d_n
jmp 0x42b5f8
lea eax, [ebp - 0x78]
push eax
push 4
pop eax
push eax
push dword [ebp + 8]
call dword [sym.imp.ADVAPI32.dll_SetFileSecurityW]
test eax, eax
jne 0x42b9a9
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.SetFileSecurity___failed._Error__d_n
jmp 0x42b5f8
mov dword [ebp - 0x4c], 1
mov dword [ebp - 4], 0xfffffffe
call fcn.0042b9c9
mov eax, dword [ebp - 0x4c]
call fcn.00440bdd
ret 0xc