Function at 0x101034c
Capabilities:
Set registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x80
mov eax, dword [0x1035f7c]
push ebx
push esi
push edi
xor ebx, ebx
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
mov edi, dword [sym.imp.ADVAPI32.dll_AllocateAndInitializeSid]
mov dword [ebp - 0x60], eax
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x5c], eax
lea eax, [ebp - 0x28]
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0x220
push 0x20
push 2
lea eax, [ebp - 0xc]
push eax
mov dword [ebp - 0x10], ebx
mov byte [ebp - 0xc], bl
mov byte [ebp - 0xb], bl
mov byte [ebp - 0xa], bl
mov byte [ebp - 9], bl
mov byte [ebp - 8], bl
mov byte [ebp - 7], 5
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x3c], ebx
mov dword [ebp - 0x20], ebx
call edi
test eax, eax
mov esi, dword [sym.imp.ADVAPI32.dll_CopySid]
je 0x1010400
push dword [ebp - 0x28]
call dword [sym.imp.ADVAPI32.dll_GetLengthSid]
mov dword [ebp - 0x14], eax
add eax, 8
mov dword [ebp - 0x20], eax
movzx eax, ax
push eax
call fcn.0100d87e
cmp eax, ebx
pop ecx
mov dword [ebp - 0x3c], eax
je 0x1010406
push dword [ebp - 0x28]
add eax, 8
push eax
push dword [ebp - 0x14]
call esi
mov eax, dword [ebp - 0x3c]
mov ecx, dword [ebp + 0x10]
mov dword [eax + 4], ecx
mov cx, word [ebp - 0x20]
mov byte [eax], bl
mov byte [eax + 1], 3
mov word [eax + 2], cx
jmp 0x101040d
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], 0x8007000e
lea eax, [ebp - 0x40]
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 4
push 1
lea eax, [ebp - 0xc]
push eax
mov dword [ebp - 0x40], ebx
mov dword [ebp - 0x34], ebx
mov dword [ebp - 0x48], ebx
call edi
test eax, eax
je 0x1010477
push dword [ebp - 0x40]
call dword [sym.imp.ADVAPI32.dll_GetLengthSid]
mov dword [ebp - 0x14], eax
add eax, 8
mov dword [ebp - 0x48], eax
movzx eax, ax
push eax
call fcn.0100d87e
cmp eax, ebx
pop ecx
mov dword [ebp - 0x34], eax
je 0x101047d
push dword [ebp - 0x40]
add eax, 8
push eax
push dword [ebp - 0x14]
call esi
mov eax, dword [ebp - 0x34]
mov ecx, dword [ebp + 0x10]
mov dword [eax + 4], ecx
mov cx, word [ebp - 0x48]
mov byte [eax], bl
mov byte [eax + 1], 3
mov word [eax + 2], cx
jmp 0x1010484
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], 0x8007000e
lea eax, [ebp - 0x24]
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0x12
push 1
lea eax, [ebp - 0xc]
push eax
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x2c], ebx
mov dword [ebp - 0x54], ebx
call edi
test eax, eax
je 0x10104ee
push dword [ebp - 0x24]
call dword [sym.imp.ADVAPI32.dll_GetLengthSid]
mov dword [ebp - 0x14], eax
add eax, 8
mov dword [ebp - 0x54], eax
movzx eax, ax
push eax
call fcn.0100d87e
cmp eax, ebx
pop ecx
mov dword [ebp - 0x2c], eax
je 0x10104f4
push dword [ebp - 0x24]
add eax, 8
push eax
push dword [ebp - 0x14]
call esi
mov eax, dword [ebp - 0x2c]
mov ecx, dword [ebp + 0x10]
mov dword [eax + 4], ecx
mov cx, word [ebp - 0x54]
mov byte [eax], bl
mov byte [eax + 1], 3
mov word [eax + 2], cx
jmp 0x10104fb
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], 0x8007000e
lea eax, [ebp - 0x38]
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0x13
push 1
lea eax, [ebp - 0xc]
push eax
mov dword [ebp - 0x38], ebx
mov dword [ebp - 0x44], ebx
mov dword [ebp - 0x4c], ebx
call edi
test eax, eax
je 0x1010565
push dword [ebp - 0x38]
call dword [sym.imp.ADVAPI32.dll_GetLengthSid]
mov dword [ebp - 0x14], eax
add eax, 8
mov dword [ebp - 0x4c], eax
movzx eax, ax
push eax
call fcn.0100d87e
cmp eax, ebx
pop ecx
mov dword [ebp - 0x44], eax
je 0x101056b
push dword [ebp - 0x38]
add eax, 8
push eax
push dword [ebp - 0x14]
call esi
mov eax, dword [ebp - 0x44]
mov ecx, dword [ebp + 0x10]
mov dword [eax + 4], ecx
mov cx, word [ebp - 0x4c]
mov byte [eax], bl
mov byte [eax + 1], 3
mov word [eax + 2], cx
jmp 0x1010572
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], 0x8007000e
lea eax, [ebp - 0x30]
push eax
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0x14
push 1
lea eax, [ebp - 0xc]
push eax
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x50], ebx
call edi
test eax, eax
je 0x10105db
push dword [ebp - 0x30]
call dword [sym.imp.ADVAPI32.dll_GetLengthSid]
mov dword [ebp - 0x1c], eax
add eax, 8
mov dword [ebp - 0x50], eax
movzx eax, ax
push eax
call fcn.0100d87e
mov edi, eax
cmp edi, ebx
pop ecx
mov dword [ebp - 0x14], edi
je 0x10105e1
push dword [ebp - 0x30]
lea eax, [edi + 8]
push eax
push dword [ebp - 0x1c]
call esi
mov eax, dword [ebp + 0x10]
mov dword [edi + 4], eax
mov ax, word [ebp - 0x50]
mov byte [edi], bl
mov byte [edi + 1], 3
mov word [edi + 2], ax
jmp 0x10105e8
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x10], 0x8007000e
movzx eax, word [ebp - 0x50]
movzx edi, word [ebp - 0x4c]
movzx edx, word [ebp - 0x54]
movzx esi, word [ebp - 0x48]
movzx ecx, word [ebp - 0x20]
mov dword [ebp - 0x58], eax
add eax, edi
add eax, edx
add eax, esi
mov dword [ebp - 0x6c], esi
lea esi, [eax + ecx + 8]
push esi
mov dword [ebp - 0x68], edx
mov dword [ebp - 0x64], ecx
call fcn.0100d87e
cmp eax, ebx
pop ecx
mov dword [ebp - 0x1c], eax
je 0x1010788
push 2
push esi
push eax
call dword [sym.imp.ADVAPI32.dll_InitializeAcl]
test eax, eax
je 0x101077d
cmp word [ebp - 0x48], bx
mov esi, dword [sym.imp.ADVAPI32.dll_AddAce]
mov dword [ebp - 0x18], ebx
je 0x101065e
push dword [ebp - 0x6c]
push dword [ebp - 0x34]
push ebx
push 2
push dword [ebp - 0x1c]
call esi
test eax, eax
je 0x101065e
mov dword [ebp - 0x18], 1
cmp word [ebp - 0x54], bx
je 0x101067b
push dword [ebp - 0x68]
push dword [ebp - 0x2c]
push dword [ebp - 0x18]
push 2
push dword [ebp - 0x1c]
call esi
test eax, eax
je 0x101067b
inc dword [ebp - 0x18]
cmp word [ebp - 0x4c], bx
je 0x1010696
push edi
push dword [ebp - 0x44]
push dword [ebp - 0x18]
push 2
push dword [ebp - 0x1c]
call esi
test eax, eax
je 0x1010696
inc dword [ebp - 0x18]
cmp word [ebp - 0x50], bx
je 0x10106b3
push dword [ebp - 0x58]
push dword [ebp - 0x14]
push dword [ebp - 0x18]
push 2
push dword [ebp - 0x1c]
call esi
test eax, eax
je 0x10106b3
inc dword [ebp - 0x18]
cmp word [ebp - 0x20], bx
je 0x10106c9
push dword [ebp - 0x64]
push dword [ebp - 0x3c]
push dword [ebp - 0x18]
push 2
push dword [ebp - 0x1c]
call esi
push 1
lea eax, [ebp - 0x80]
push eax
call dword [sym.imp.ADVAPI32.dll_InitializeSecurityDescriptor]
test eax, eax
je 0x1010776
push ebx
push dword [ebp - 0x1c]
lea eax, [ebp - 0x80]
push 1
push eax
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorDacl]
cmp eax, ebx
je 0x1010776
push ebx
push dword [ebp - 0x24]
lea eax, [ebp - 0x80]
push eax
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorOwner]
cmp eax, ebx
je 0x1010776
push ebx
push dword [ebp - 0x28]
lea eax, [ebp - 0x80]
push eax
call dword [sym.imp.ADVAPI32.dll_SetSecurityDescriptorGroup]
cmp eax, ebx
je 0x1010776
lea eax, [ebp - 0x80]
push eax
call dword [sym.imp.ADVAPI32.dll_GetSecurityDescriptorLength]
push eax
mov dword [ebp - 0x20], eax
call fcn.0100d87e
mov esi, eax
cmp esi, ebx
pop ecx
je 0x101076d
lea eax, [ebp - 0x20]
push eax
push esi
lea eax, [ebp - 0x80]
push eax
call dword [sym.imp.ADVAPI32.dll_MakeSelfRelativeSD]
test eax, eax
je 0x1010764
push dword [ebp - 0x20]
push esi
push 3
push ebx
push dword [ebp - 0x5c]
push dword [ebp - 0x60]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
je 0x1010764
mov dword [ebp - 0x10], 0x80004005
push esi
call fcn.0100d8a8
pop ecx
jmp 0x101077d
mov dword [ebp - 0x10], 0x8007000e
jmp 0x101077d
mov dword [ebp - 0x10], 0x80004005
push dword [ebp - 0x1c]
call fcn.0100d8a8
pop ecx
jmp 0x101078f
mov dword [ebp - 0x10], 0x8007000e
cmp dword [ebp - 0x3c], ebx
je 0x101079d
push dword [ebp - 0x3c]
call fcn.0100d8a8
pop ecx
cmp dword [ebp - 0x34], ebx
je 0x10107ab
push dword [ebp - 0x34]
call fcn.0100d8a8
pop ecx
cmp dword [ebp - 0x2c], ebx
je 0x10107b9
push dword [ebp - 0x2c]
call fcn.0100d8a8
pop ecx
cmp dword [ebp - 0x44], ebx
je 0x10107c7
push dword [ebp - 0x44]
call fcn.0100d8a8
pop ecx
cmp dword [ebp - 0x14], ebx
je 0x10107d5
push dword [ebp - 0x14]
call fcn.0100d8a8
pop ecx
cmp dword [ebp - 0x40], ebx
mov esi, dword [sym.imp.ADVAPI32.dll_FreeSid]
je 0x10107e5
push dword [ebp - 0x40]
call esi
cmp dword [ebp - 0x24], ebx
je 0x10107ef
push dword [ebp - 0x24]
call esi
cmp dword [ebp - 0x38], ebx
je 0x10107f9
push dword [ebp - 0x38]
call esi
cmp dword [ebp - 0x30], ebx
je 0x1010803
push dword [ebp - 0x30]
call esi
cmp dword [ebp - 0x28], ebx
je 0x101080d
push dword [ebp - 0x28]
call esi
mov ecx, dword [ebp - 4]
mov eax, dword [ebp - 0x10]
pop edi
pop esi
pop ebx
call fcn.0102451e
leave
ret 0xc