Function at 0x1059beb
Capabilities:
Create directory
Query or enumerate registry value
Set registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x42c
mov eax, dword [0x107fa78]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 8]
push esi
xor esi, esi
cmp eax, esi
mov dword [ebp - 0x42c], eax
mov dword [ebp - 0x418], esi
mov dword [ebp - 0x420], 1
jne 0x1059c27
xor eax, eax
jmp 0x1059fc0
push ebx
mov ebx, dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
push edi
push esi
lea eax, [ebp - 0x418]
push eax
push esi
push 3
push esi
push esi
push esi
push 0x100a4a8
mov edi, reloc.OLEAUT32.dll_SysReAllocString
push edi
call ebx
test eax, eax
je 0x1059c75
push esi
lea eax, [ebp - 0x418]
push eax
push esi
push 1
push esi
push esi
push esi
push 0x100a4a8
push edi
mov dword [ebp - 0x420], esi
call ebx
test eax, eax
je 0x1059c75
xor eax, eax
jmp 0x1059fbe
mov ebx, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
lea eax, [ebp - 0x428]
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x424]
push eax
push esi
push 0x100a478
push dword [ebp - 0x418]
xor edi, edi
inc edi
mov dword [ebp - 0x428], 0x208
mov dword [ebp - 0x424], edi
call ebx
cmp dword [ebp - 0x424], edi
mov edi, dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov dword [ebp - 0x41c], eax
jne 0x1059ccd
cmp eax, esi
je 0x1059df0
lea eax, [ebp - 0x428]
push eax
lea eax, [ebp - 0x20c]
push eax
lea eax, [ebp - 0x424]
push eax
push esi
push 0x100a460
push dword [ebp - 0x418]
mov dword [ebp - 0x428], 0x208
call ebx
cmp dword [ebp - 0x424], 1
mov dword [ebp - 0x41c], eax
mov word [ebp - 6], si
jne 0x1059d11
cmp eax, esi
je 0x1059d76
mov ebx, 0x104
push ebx
lea eax, [ebp - 0x20c]
push eax
call fcn.01067cfe
test eax, eax
jne 0x1059d6a
lea eax, [ebp - 0x20c]
push eax
call fcn.01056bba
push ebx
lea eax, [ebp - 0x414]
push eax
push 0x26fd
push dword [0x1081390]
call dword [sym.imp.USER32.dll_LoadStringW]
test eax, eax
je 0x1059d6a
lea eax, [ebp - 0x414]
push eax
push ebx
lea eax, [ebp - 0x20c]
push eax
call fcn.01034cee
mov dword [ebp - 0x41c], esi
cmp dword [ebp - 0x41c], esi
jne 0x1059fa7
cmp dword [ebp - 0x420], esi
je 0x1059de4
lea eax, [ebp - 0x20c]
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
cmp cx, si
jne 0x1059d87
sub eax, edx
sar eax, 1
lea eax, [eax + eax + 2]
push eax
lea eax, [ebp - 0x20c]
push eax
push 1
push esi
push 0x100a478
push dword [ebp - 0x418]
call edi
lea eax, [ebp - 0x20c]
lea ecx, [eax + 2]
mov dx, word [eax]
inc eax
inc eax
cmp dx, si
jne 0x1059dba
sub eax, ecx
sar eax, 1
lea eax, [eax + eax + 2]
push eax
lea eax, [ebp - 0x20c]
push eax
push 1
push esi
push 0x100a42c
push dword [ebp - 0x418]
call edi
cmp dword [ebp - 0x41c], esi
jne 0x1059fa7
lea eax, [ebp - 0x20c]
push 0x100a2b8
push eax
mov word [ebp - 6], si
call dword [sym.imp.msvcrt.dll_wcsstr]
test eax, eax
pop ecx
pop ecx
je 0x1059ee7
mov ebx, 0x104
push ebx
lea eax, [ebp - 0x20c]
push eax
call fcn.01067cfe
test eax, eax
jne 0x1059ee7
lea eax, [ebp - 0x20c]
push eax
call fcn.01056bba
push 0x100
lea eax, [ebp - 0x40c]
push eax
push 0x26fd
push dword [0x1081390]
call dword [sym.imp.USER32.dll_LoadStringW]
test eax, eax
je 0x1059ee7
lea eax, [ebp - 0x40c]
push eax
push ebx
lea eax, [ebp - 0x20c]
push eax
call fcn.01034cee
test eax, eax
jl 0x1059ee7
cmp dword [ebp - 0x420], esi
mov dword [ebp - 0x41c], esi
je 0x1059ee7
lea eax, [ebp - 0x20c]
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
cmp cx, si
jne 0x1059e8a
sub eax, edx
sar eax, 1
lea eax, [eax + eax + 2]
push eax
lea eax, [ebp - 0x20c]
push eax
push 1
push esi
push 0x100a478
push dword [ebp - 0x418]
call edi
lea eax, [ebp - 0x20c]
lea ecx, [eax + 2]
mov dx, word [eax]
inc eax
inc eax
cmp dx, si
jne 0x1059ebd
sub eax, ecx
sar eax, 1
lea eax, [eax + eax + 2]
push eax
lea eax, [ebp - 0x20c]
push eax
push 1
push esi
push 0x100a42c
push dword [ebp - 0x418]
call edi
lea eax, [ebp - 0x20c]
push eax
call fcn.0105970f
test eax, eax
jne 0x1059f3f
mov ebx, dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
push esi
lea eax, [ebp - 0x20c]
push eax
call ebx
test eax, eax
jne 0x1059f3f
lea eax, [ebp - 0x20c]
push eax
push 0x100a420
lea eax, [ebp - 0x414]
push 0x104
push eax
call fcn.01034d76
add esp, 0x10
push esi
lea eax, [ebp - 0x414]
push eax
call ebx
push esi
lea eax, [ebp - 0x20c]
push eax
call ebx
cmp dword [ebp - 0x420], esi
je 0x1059f7a
lea eax, [ebp - 0x20c]
lea edx, [eax + 2]
mov cx, word [eax]
inc eax
inc eax
cmp cx, si
jne 0x1059f50
sub eax, edx
sar eax, 1
lea eax, [eax + eax + 2]
push eax
lea eax, [ebp - 0x20c]
push eax
push 1
push esi
push 0x100a460
push dword [ebp - 0x418]
call edi
cmp dword [ebp + 0xc], esi
jne 0x1059f92
push 0x104
lea eax, [ebp - 0x20c]
push eax
push eax
call dword [sym.imp.KERNEL32.dll_GetShortPathNameW]
lea eax, [ebp - 0x20c]
push eax
push dword [ebp + 0x10]
push dword [ebp - 0x42c]
call fcn.01034c79
push dword [ebp - 0x418]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
cmp dword [ebp - 0x41c], esi
sete al
pop edi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
pop esi
call fcn.01047417
leave
ret 0xc