Function at 0x10001000
Capabilities:
Get user security identifier
Inspect section memory permissions

Disassembly:
push ebp
lea ebp, [esp - 0x3fd0]
mov eax, 0x4050
call fcn.1000cf70
mov eax, dword [0x1003b040]
xor eax, ebp
mov dword [ebp + 0x3fcc], eax
mov eax, dword [ebp + 0x3fe0]
push ebx
push esi
xor esi, esi
mov dword [ebp - 0x58], eax
mov eax, dword [ebp + 0x3ffc]
inc esi
cmp byte [ebp + 0x3fe4], 0
push edi
mov dword [ebp - 0x3c], eax
push 4
pop eax
cmovne esi, eax
mov edi, dword [ebp + 0x3fd8]
xor ecx, ecx
mov ebx, dword [sym.imp.KERNEL32.dll_LocalFree]
cmp byte [ebp + 0x3fe8], cl
mov eax, SysReAllocString
mov dword [ebp - 0x4c], edi
cmove eax, ecx
mov dword [ebp - 0x5c], esi
mov ecx, eax
or ecx, 0x40000000
cmp byte [ebp + 0x3fec], 0
cmove ecx, eax
mov eax, ecx
or eax, 0x20000000
cmp byte [ebp + 0x3ff0], 0
cmove eax, ecx
mov ecx, eax
or ecx, 0x10000000
cmp byte [ebp + 0x3ff4], 0
cmove ecx, eax
xor edx, edx
cmp dword [ebp + 0x3ff8], 3
mov dword [ebp - 0x60], ecx
mov dword [ebp - 0x48], edx
jne 0x10001171
push str.advapi32.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
mov edi, eax
test edi, edi
je 0x10001136
push dword [ebp - 0x3c]
push dword [ebp - 0x4c]
call fcn.1000a99e
pop ecx
pop ecx
push str.ConvertStringSidToSidW
push edi
mov esi, eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x10001129
lea ecx, [ebp - 0x48]
push ecx
push esi
call eax
test eax, eax
jne 0x10001129
mov edi, 0x2000
push edi
push 0x40
mov dword [ebp - 0x54], edi
call dword [sym.imp.KERNEL32.dll_LocalAlloc]
lea ecx, [ebp - 0x44]
mov dword [ebp - 0x48], eax
push ecx
lea ecx, [ebp - 0x3c]
mov dword [ebp - 0x3c], edi
push ecx
lea ecx, [ebp - 0x34]
push ecx
lea ecx, [ebp - 0x54]
push ecx
push eax
push esi
push 0
call dword [sym.imp.ADVAPI32.dll_LookupAccountNameW]
test eax, eax
jne 0x10001129
push dword [ebp - 0x48]
call ebx
and dword [ebp - 0x48], 0
push 2
push esi
call fcn.1000cf4a
mov esi, dword [ebp - 0x5c]
pop ecx
pop ecx
mov edi, dword [ebp - 0x4c]
cmp dword [ebp - 0x48], 0
je 0x100011f0
push dword [ebp - 0x58]
push edi
call fcn.1000a99e
pop ecx
pop ecx
xor ecx, ecx
mov edi, eax
mov eax, dword [ebp - 0x48]
mov dword [ebp - 0x58], eax
mov dword [ebp - 0x3c], ecx
mov dword [ebp - 0x4c], ecx
mov dword [ebp - 0x54], ecx
test edi, edi
jne 0x1000120c
push 0x57
pop esi
jmp 0x100012cd
cmp dword [ebp + 0x3ff8], 5
mov eax, edx
mov dword [ebp - 0x44], edx
mov word [ebp - 0x40], pe_nt_image_headers32
jne 0x100011a7
push 6
lea eax, [ebp - 0x3c]
mov dword [ebp - 0x3c], edx
push eax
lea eax, [ebp - 0x44]
mov word [ebp - 0x38], 0x200
push eax
call fcn.1000df40
add esp, 0xc
mov eax, 0x223
jmp 0x100011ce
cmp dword [ebp + 0x3ff8], 1
jne 0x100011d0
push 6
lea eax, [ebp - 0x3c]
mov dword [ebp - 0x3c], edx
push eax
lea eax, [ebp - 0x44]
mov word [ebp - 0x38], 0x500
push eax
call fcn.1000df40
add esp, 0xc
push 0xb
pop eax
xor edx, edx
lea ecx, [ebp - 0x48]
push ecx
push edx
push edx
push edx
push edx
push edx
push edx
push edx
push eax
push 1
lea eax, [ebp - 0x44]
push eax
call dword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
test eax, eax
jne 0x10001139
xor al, al
mov ecx, dword [ebp + 0x3fcc]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1000cf58
add ebp, 0x3fd0
leave
ret 0x2c
lea eax, [ebp - 0x54]
push eax
push ecx
lea eax, [ebp - 0x3c]
push eax
push ecx
push ecx
push 4
push esi
push edi
call dword [sym.imp.ADVAPI32.dll_GetNamedSecurityInfoW]
mov esi, eax
test esi, esi
je 0x10001238
push edi
push esi
push str.GetNamedSecurityInfo_Error__u__S_n
call fcn.10001324
add esp, 0xc
jmp 0x100012b7
push 0x20
lea eax, [ebp - 0x80]
push 0
push eax
call fcn.1000e4c0
mov eax, dword [ebp - 0x60]
add esp, 0xc
and dword [ebp - 0x6c], 0
mov dword [ebp - 0x80], eax
mov eax, dword [ebp + 0x4000]
mov dword [ebp - 0x7c], eax
mov eax, dword [ebp - 0x58]
mov dword [ebp - 0x64], eax
lea eax, [ebp - 0x4c]
push eax
push dword [ebp - 0x3c]
lea eax, [ebp - 0x80]
mov dword [ebp - 0x78], 3
push eax
push 1
mov dword [ebp - 0x68], 5
call dword [sym.imp.ADVAPI32.dll_SetEntriesInAclW]
mov esi, eax
test esi, esi
je 0x10001290
push esi
push str.SetEntriesInAcl_Error__u_n
jmp 0x100012b0
xor eax, eax
push eax
push dword [ebp - 0x4c]
push eax
push eax
push 4
push dword [ebp - 0x5c]
push edi
call dword [sym.imp.ADVAPI32.dll_SetNamedSecurityInfoW]
mov esi, eax
test esi, esi
je 0x100012b7
push esi
push str.SetNamedSecurityInfo_Error__u_n
call fcn.10001324
pop ecx
pop ecx
cmp dword [ebp - 0x54], 0
je 0x100012c2
push dword [ebp - 0x54]
call ebx
cmp dword [ebp - 0x4c], 0
je 0x100012cd
push dword [ebp - 0x4c]
call ebx
test esi, esi
push 2
push edi
sete byte [ebp - 0x4d]
call fcn.1000cf4a
cmp dword [ebp + 0x3ff8], 3
pop ecx
pop ecx
push dword [ebp - 0x48]
jne 0x100012ed
call ebx
jmp 0x100012f3
call dword [sym.imp.ADVAPI32.dll_FreeSid]
mov al, byte [ebp - 0x4d]
jmp 0x100011f2