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

Disassembly:
push ebp
mov ebp, esp
push 0xfffffffffffffffe
push 0x6068a8
push 0x570790
mov eax, dword fs:[0]
push eax
add esp, 0xffffff7c
push ebx
push esi
push edi
mov eax, dword [0x616738]
xor dword [ebp - 8], eax
xor eax, ebp
push eax
lea eax, [ebp - 0x10]
mov dword fs:[0], eax
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x64], 0
mov dword [ebp - 0x54], 0
mov dword [ebp - 0x84], 0
mov dword [ebp - 0x60], 0
mov dword [ebp - 0x3c], 0
mov dword [ebp - 0x5c], 0
mov dword [ebp - 0x4c], 0
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x28], 0
mov dword [ebp - 0x50], 0
mov dword [ebp - 0x48], 0
mov dword [ebp - 0x80], 4
mov dword [ebp - 0x7c], 0
mov dword [ebp - 4], 0
lea eax, [ebp - 0x44]
push eax
lea ecx, [ebp - 0x40]
push ecx
mov edx, dword [ebp - 0x2c]
push edx
lea eax, [ebp - 0x54]
push eax
mov ecx, dword [ebp - 0x64]
push ecx
mov edx, dword [ebp + 0xc]
push edx
push 0
call dword [sym.imp.ADVAPI32.dll_LookupAccountNameA]
mov dword [ebp - 0x58], eax
cmp dword [ebp - 0x58], 0
je 0x496dc6
jmp 0x49738c
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
je 0x496dea
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x5b48f0
call fcn.005771de
add esp, 8
jmp 0x49738c
mov eax, dword [ebp - 0x54]
push eax
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [ebp - 0x64], eax
cmp dword [ebp - 0x64], 0
jne 0x496e1f
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x5b4918
call fcn.005771de
add esp, 8
jmp 0x49738c
mov ecx, dword [ebp - 0x40]
push ecx
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [ebp - 0x2c], eax
cmp dword [ebp - 0x2c], 0
jne 0x496e54
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x5b4938
call fcn.005771de
add esp, 8
jmp 0x49738c
lea edx, [ebp - 0x44]
push edx
lea eax, [ebp - 0x40]
push eax
mov ecx, dword [ebp - 0x2c]
push ecx
lea edx, [ebp - 0x54]
push edx
mov eax, dword [ebp - 0x64]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
push 0
call dword [sym.imp.ADVAPI32.dll_LookupAccountNameA]
mov dword [ebp - 0x58], eax
cmp dword [ebp - 0x58], 0
jne 0x496e96
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.LookupAccountName___failed._Error__d_n
call fcn.005771de
add esp, 8
jmp 0x49738c
lea edx, [ebp - 0x60]
push edx
push 0
mov eax, dword [ebp - 0x84]
push eax
mov ecx, dword [ebp - 0x80]
push ecx
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.ADVAPI32.dll_GetFileSecurityA]
mov dword [ebp - 0x58], eax
cmp dword [ebp - 0x58], 0
je 0x496ec1
jmp 0x49738c
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x7a
je 0x496ee5
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x5b4980
call fcn.005771de
add esp, 8
jmp 0x49738c
mov eax, dword [ebp - 0x60]
push eax
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [ebp - 0x84], eax
cmp dword [ebp - 0x84], 0
jne 0x496f20
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x5b49a4
call fcn.005771de
add esp, 8
jmp 0x49738c
lea ecx, [ebp - 0x60]
push ecx
mov edx, dword [ebp - 0x60]
push edx
mov eax, dword [ebp - 0x84]
push eax
mov ecx, dword [ebp - 0x80]
push ecx
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.ADVAPI32.dll_GetFileSecurityA]
mov dword [ebp - 0x58], eax
cmp dword [ebp - 0x58], 0
jne 0x496f5f
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetFileSecurity___failed._Error__d_n
call fcn.005771de
add esp, 8
jmp 0x49738c
push 1
lea eax, [ebp - 0x78]
push eax
call dword [sym.imp.ADVAPI32.dll_InitializeSecurityDescriptor]
test eax, eax
jne 0x496f88
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.InitializeSecurityDescriptor___failed.Error__d_n
call fcn.005771de
add esp, 8
jmp 0x49738c
lea ecx, [ebp - 0x34]
push ecx
lea edx, [ebp - 0x3c]
push edx
lea eax, [ebp - 0x38]
push eax
mov ecx, dword [ebp - 0x84]
push ecx
call dword [sym.imp.ADVAPI32.dll_GetSecurityDescriptorDacl]
test eax, eax
jne 0x496fbe
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetSecurityDescriptorDacl___failed._Error__d_n
call fcn.005771de
add esp, 8
jmp 0x49738c
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x20], 8
cmp dword [ebp - 0x3c], 0
jne 0x496fe0
mov dword [ebp - 0x38], 0
cmp dword [ebp - 0x38], 0
je 0x497015
push 2
push 0xc
lea edx, [ebp - 0x24]
push edx
mov eax, dword [ebp - 0x3c]
push eax
call dword [sym.imp.ADVAPI32.dll_GetAclInformation]
test eax, eax
jne 0x497015
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetAclInformation___failed._Error__d_n
call fcn.005771de
add esp, 8
jmp 0x49738c
mov ecx, dword [ebp - 0x64]
push ecx
call dword [sym.imp.ADVAPI32.dll_GetLengthSid]
mov edx, dword [ebp - 0x20]
lea eax, [edx + eax + 8]
mov dword [ebp - 0x4c], eax
mov ecx, dword [ebp - 0x4c]
push ecx
push 8
call dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push eax
call dword [sym.imp.KERNEL32.dll_HeapAlloc]
mov dword [ebp - 0x5c], eax
cmp dword [ebp - 0x5c], 0
jne 0x49705e
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.HeapAlloc___failed._Error__d_n
call fcn.005771de
add esp, 8
jmp 0x49738c
push 2
mov edx, dword [ebp - 0x4c]
push edx
mov eax, dword [ebp - 0x5c]
push eax
call dword [sym.imp.ADVAPI32.dll_InitializeAcl]
test eax, eax
jne 0x49708b
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.InitializeAcl___failed._Error__d_n
call fcn.005771de
add esp, 8
jmp 0x49738c
mov dword [ebp - 0x50], 0
cmp dword [ebp - 0x38], 0
je 0x49715d
cmp dword [ebp - 0x24], 0
je 0x49715d
mov dword [ebp - 0x28], 0
jmp 0x4970b8
mov ecx, dword [ebp - 0x28]
add ecx, 1
mov dword [ebp - 0x28], ecx
mov edx, dword [ebp - 0x28]
cmp edx, dword [ebp - 0x24]
jae 0x49715d
lea eax, [ebp - 0x30]
push eax
mov ecx, dword [ebp - 0x28]
push ecx
mov edx, dword [ebp - 0x3c]
push edx
call dword [sym.imp.ADVAPI32.dll_GetAce]
test eax, eax
jne 0x4970f3
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x5b4ab4
call fcn.005771de
add esp, 8
jmp 0x49738c
mov eax, dword [ebp - 0x30]
movzx ecx, byte [eax + 1]
and ecx, 0x10
je 0x497101
jmp 0x49715d
mov edx, dword [ebp - 0x30]
add edx, 8
push edx
mov eax, dword [ebp - 0x64]
push eax
call dword [sym.imp.ADVAPI32.dll_EqualSid]
test eax, eax
je 0x497118
jmp 0x4970af
mov ecx, dword [ebp - 0x30]
movzx edx, word [ecx + 2]
push edx
mov eax, dword [ebp - 0x30]
push eax
push 0xffffffffffffffff
push 2
mov ecx, dword [ebp - 0x5c]
push ecx
call dword [sym.imp.ADVAPI32.dll_AddAce]
test eax, eax
jne 0x49714f
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push 0x5b4ad0
call fcn.005771de
add esp, 8
jmp 0x49738c
mov edx, dword [ebp - 0x50]
add edx, 1
mov dword [ebp - 0x50], edx
jmp 0x4970af
mov eax, dword [ebp - 0x64]
push eax
mov ecx, dword [ebp + 0x10]
push ecx
push 2
mov edx, dword [ebp - 0x5c]
push edx
call dword [sym.imp.ADVAPI32.dll_AddAccessAllowedAce]
test eax, eax
jne 0x49718e
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.AddAccessAllowedAce___failed._Error__d_n
call fcn.005771de
add esp, 8
jmp 0x49738c
cmp dword [ebp - 0x38], 0
je 0x497219
cmp dword [ebp - 0x24], 0
je 0x497219
jmp 0x4971a9
mov eax, dword [ebp - 0x28]
add eax, 1
mov dword [ebp - 0x28], eax
mov ecx, dword [ebp - 0x28]
cmp ecx, dword [ebp - 0x24]
jae 0x497219
lea edx, [ebp - 0x30]
push edx
mov eax, dword [ebp - 0x28]
push eax
mov ecx, dword [ebp - 0x3c]
push ecx
call dword [sym.imp.ADVAPI32.dll_GetAce]
test eax, eax
jne 0x4971e0
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetAce___failed._Error__d_n
call fcn.005771de
add esp, 8
jmp 0x49738c
mov edx, dword [ebp - 0x30]
movzx eax, word [edx + 2]
push eax
mov ecx, dword [ebp - 0x30]
push ecx
push 0xffffffffffffffff
push 2
mov edx, dword [ebp - 0x5c]
push edx
call dword [sym.imp.ADVAPI32.dll_AddAce]
test eax, eax
jne 0x497217
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.AddAce___failed._Error__d_n
call fcn.005771de
add esp, 8
jmp 0x49738c
jmp 0x4971a0
push 0
mov eax, dword [ebp - 0x5c]
push eax
push 1
lea ecx, [ebp - 0x78]
push ecx
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorDacl]
test eax, eax
jne 0x497248
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.SetSecurityDescriptorDacl___failed._Error__d_n
call fcn.005771de
add esp, 8
jmp 0x49738c
push str.SetSecurityDescriptorControl
push 0x5b4b9c
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [ebp - 0x7c], eax
cmp dword [ebp - 0x7c], 0
je 0x497359
xor edx, edx
mov word [ebp - 0x88], dx
xor eax, eax
mov word [ebp - 0x90], ax
xor ecx, ecx
mov word [ebp - 0x94], cx
mov dword [ebp - 0x8c], 0
lea edx, [ebp - 0x8c]
push edx
lea eax, [ebp - 0x94]
push eax
mov ecx, dword [ebp - 0x84]
push ecx
call dword [sym.imp.ADVAPI32.dll_GetSecurityDescriptorControl]
test eax, eax
jne 0x4972c9
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.GetSecurityDescriptorControl___failed.Error__d_n
call fcn.005771de
add esp, 8
jmp 0x49738c
movzx edx, word [ebp - 0x94]
and edx, 0x400
je 0x4972f4
mov eax, 0x500
mov word [ebp - 0x88], ax
mov cx, word [ebp - 0x88]
mov word [ebp - 0x90], cx
jmp 0x49731d
movzx edx, word [ebp - 0x94]
and edx, 0x1000
je 0x49731d
mov eax, 0x1000
mov word [ebp - 0x88], ax
mov cx, word [ebp - 0x88]
mov word [ebp - 0x90], cx
movzx edx, word [ebp - 0x88]
test edx, edx
je 0x497359
movzx eax, word [ebp - 0x90]
push eax
movzx ecx, word [ebp - 0x88]
push ecx
lea edx, [ebp - 0x78]
push edx
call dword [ebp - 0x7c]
test eax, eax
jne 0x497359
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.SetSecurityDescriptorControl___failed.Error__d_n
call fcn.005771de
add esp, 8
jmp 0x49738c
lea eax, [ebp - 0x78]
push eax
mov ecx, dword [ebp - 0x80]
push ecx
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.ADVAPI32.dll_SetFileSecurityA]
test eax, eax
jne 0x497385
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
push str.SetFileSecurity___failed._Error__d_n
call fcn.005771de
add esp, 8
jmp 0x49738c
mov dword [ebp - 0x48], 1
mov dword [ebp - 4], 0xfffffffe
call fcn.0049739a
jmp 0x497405
mov eax, dword [ebp - 0x48]
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret