Function at 0x4112a4
Capabilities:
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x433cd1
mov eax, dword fs:[0]
push eax
sub esp, 0xc4
mov eax, dword [0x462074]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x5c], edx
mov ebx, ecx
movzx ecx, word [ebx + 0x18]
xor eax, eax
mov dword [ebp - 0x7c], eax
mov dword [ebp - 0x54], eax
mov al, cl
shr al, 7
and al, 1
mov byte [ebp - 0x4d], al
call fcn.004111ee
test al, al
je 0x411302
and cl, 0x30
cmp cl, 0x20
jne 0x411790
cmp dword [0x4634b8], 0
jne 0x411790
mov dl, 1
mov ecx, ebx
call fcn.00411a5b
test al, al
jne 0x411790
xor eax, eax
push ecx
mov esi, eax
mov dword [ebp - 0x60], eax
push 0x463e78
lea ecx, [ebp - 0xd0]
mov dword [ebp - 0x6c], esi
mov dword [ebp - 0x68], eax
call fcn.0040f52e
mov edi, dword [ebp - 0x54]
xor edx, edx
mov dword [ebp - 0x58], edx
cmp byte [ebp - 0x4d], dl
jne 0x4114d2
mov eax, edx
mov dword [ebp - 0x64], eax
cmp eax, 4
jge 0x41143c
movzx eax, byte [ebx + 0x14]
lea ecx, [ebp - 0x78]
push edx
push eax
push edx
mov byte [ebp - 0x4d], dl
push edx
mov edx, dword [ebx + 0x10]
call fcn.00410686
lea ecx, [ebp - 0x58]
mov dword [ebp - 0x70], ecx
lea ecx, [ebp - 0x54]
mov dword [ebp - 0x6c], ecx
lea ecx, [ebp - 0x70]
push eax
call fcn.004124ef
mov ecx, dword [ebp - 0x74]
test ecx, ecx
je 0x411399
xor eax, eax
mov dword [ebp - 0x74], eax
mov eax, dword [ecx]
call dword [eax + 4]
mov edi, dword [ebp - 0x54]
test edi, edi
jne 0x411428
mov eax, dword [ebp - 0x58]
lea ecx, [ebp - 0x60]
push ecx
xor edx, edx
lea ecx, [ebp - 0x68]
push edx
push ecx
push edx
push dword [ebx]
push dword [eax + 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov edi, eax
mov dword [ebp - 0x54], edi
test edi, edi
jne 0x41140e
mov eax, dword [ebp - 0x60]
test eax, eax
je 0x41140e
push eax
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov edi, eax
pop ecx
test edi, edi
je 0x411408
test esi, esi
je 0x4113e8
push esi
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
pop ecx
mov eax, dword [ebp - 0x58]
lea ecx, [ebp - 0x60]
push ecx
push edi
lea ecx, [ebp - 0x68]
mov esi, edi
push ecx
xor ecx, ecx
push ecx
push dword [ebx]
push dword [eax + 8]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
mov edi, eax
jmp 0x41140b
push 8
pop edi
mov dword [ebp - 0x54], edi
mov ecx, edi
call fcn.004104e3
test eax, eax
je 0x411428
mov ecx, dword [ebx + 0x10]
call fcn.00410500
mov edi, dword [ebp - 0x54]
mov byte [ebp - 0x4d], 1
mov eax, dword [ebp - 0x64]
inc eax
cmp byte [ebp - 0x4d], 0
push 0
mov dword [ebp - 0x64], eax
pop edx
jne 0x411354
mov dword [ebp - 0x6c], esi
test edi, edi
jne 0x411569
test esi, esi
je 0x411569
movzx eax, word [ebx + 0x18]
and eax, 0xf
cmp dword [ebp - 0x68], eax
jne 0x4114d2
sub eax, 1
je 0x41148a
sub eax, 1
je 0x41148a
mov eax, dword [ebp - 0x60]
cmp eax, 4
jne 0x4114d2
push eax
push dword [ebp - 0x5c]
push esi
call sub.VCRUNTIME140.dll_memcmp
add esp, 0xc
xor edx, edx
test eax, eax
jne 0x4114d2
mov edi, edx
mov dword [ebp - 0x54], edi
jmp 0x411766
mov eax, dword [ebp - 0x60]
shr eax, 1
cmp word [esi + eax*2 - 2], dx
jne 0x4114d2
mov ecx, dword [ebp - 0x5c]
mov eax, esi
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x4114c3
test dx, dx
je 0x4114bd
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x4114c3
add eax, 4
add ecx, 4
test dx, dx
jne 0x41149b
xor edx, edx
mov eax, edx
jmp 0x4114ca
sbb eax, eax
or eax, 1
xor edx, edx
test eax, eax
je 0x411766
mov esi, dword [ebp - 0x5c]
mov eax, edx
mov dword [ebp - 0x64], eax
cmp eax, 4
jge 0x411763
movzx eax, byte [ebx + 0x14]
lea ecx, [ebp - 0x84]
push edx
push eax
push 4
mov byte [ebp - 0x4d], dl
push edx
mov edx, dword [ebx + 0x10]
call fcn.00410686
lea ecx, [ebp - 0x58]
mov dword [ebp - 0x78], ecx
lea ecx, [ebp - 0x54]
mov dword [ebp - 0x74], ecx
lea ecx, [ebp - 0x78]
push eax
call fcn.004124ef
mov ecx, dword [ebp - 0x80]
xor edi, edi
test ecx, ecx
je 0x411523
mov dword [ebp - 0x80], edi
mov eax, dword [ecx]
call dword [eax + 4]
mov eax, dword [ebp - 0x54]
test eax, eax
jne 0x411672
movzx ecx, word [ebx + 0x18]
mov eax, dword [ebp - 0x58]
and ecx, 0xf
push 4
push esi
push ecx
push edi
push dword [ebx]
push dword [eax + 8]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov edi, eax
mov ecx, edi
mov dword [ebp - 0x54], edi
call fcn.004104e3
test eax, eax
je 0x4115b5
mov ecx, dword [ebx + 0x10]
call fcn.00410500
mov byte [ebp - 0x4d], 1
jmp 0x41174c
mov ecx, dword [ebx + 8]
cmp ecx, 0xcccccccc
je 0x4114d2
movzx eax, word [ebx + 0x18]
and eax, 0xf
sub eax, 1
je 0x4115ad
sub eax, 1
je 0x4115ad
dec eax
sub eax, 1
je 0x4115a3
push edx
sub eax, 7
jne 0x4117ae
push 0x59948f
jmp 0x4117b3
mov eax, dword [ebp - 0x5c]
cmp dword [eax], ecx
jmp 0x41147e
cmp ecx, dword [ebp - 0x5c]
jmp 0x41147e
test edi, edi
je 0x41174f
mov edx, dword [ebx + 0x10]
lea ecx, [ebp - 0x28]
xor eax, eax
mov dword [ebp - 0x94], 0x438e1c
mov word [ebp - 0x88], ax
mov eax, dword [ebx]
mov dword [ebp - 0x9c], eax
xor eax, eax
mov byte [ebp - 0x5c], al
push dword [ebp - 0x5c]
mov dword [ebp - 0x90], str.Win32ErrorCode
mov dword [ebp - 0x8c], edi
mov dword [ebp - 0xa4], vtable.Mso::Logging::StructuredObject_wchar_t_const___1_.0
mov dword [ebp - 0xa0], str.RegistryValueName
mov word [ebp - 0x98], ax
call fcn.0040fccd
lea eax, [ebp - 0x28]
mov dword [ebp - 0x4c], 0x4395c0
push eax
lea ecx, [ebp - 0x44]
mov dword [ebp - 0x48], str.KeyPath
call fcn.0040deab
xor eax, eax
mov word [ebp - 0x2c], ax
lea eax, [ebp - 0x94]
push eax
lea eax, [ebp - 0xa4]
push eax
lea eax, [ebp - 0x4c]
push eax
push str.Failed_to_write_registry_value.
push ecx
mov ecx, 0x16928cc
call fcn.0041251e
lea ecx, [ebp - 0x44]
call fcn.0040a89a
lea ecx, [ebp - 0x28]
call fcn.0040a89a
mov edx, str.OrapiWriteFail:_RegSetValueExW
jmp 0x411744
mov dword [ebp - 0xac], eax
xor eax, eax
mov word [ebp - 0xa8], ax
mov eax, dword [ebx]
mov dword [ebp - 0xbc], eax
xor eax, eax
mov word [ebp - 0xb8], ax
mov eax, dword [ebx + 0x10]
mov dword [ebp - 0xb4], 0x438e1c
mov dword [ebp - 0xb0], str.Win32ErrorCode
mov dword [ebp - 0xc4], vtable.Mso::Logging::StructuredObject_wchar_t_const___1_.0
mov dword [ebp - 0xc0], str.RegistryValueName
mov edx, dword [eax]
mov ecx, edx
xor eax, eax
mov dword [ebp - 0x14], 7
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x18], eax
lea edi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, word [ebp - 0x7c]
jne 0x4116d3
sub ecx, edi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x28]
call fcn.0040a802
lea eax, [ebp - 0x28]
mov dword [ebp - 0x4c], 0x4395c0
push eax
lea ecx, [ebp - 0x44]
mov dword [ebp - 0x48], str.KeyName
call fcn.0040deab
xor eax, eax
mov word [ebp - 0x2c], ax
lea eax, [ebp - 0xb4]
push eax
lea eax, [ebp - 0xc4]
push eax
lea eax, [ebp - 0x4c]
push eax
push str.Failed_to_open_registry_key.
push ecx
mov ecx, 0x16928cd
call fcn.0041251e
lea ecx, [ebp - 0x44]
call fcn.0040a89a
lea ecx, [ebp - 0x28]
call fcn.0040a89a
mov edx, str.OrapiWriteFail:_TryOpenKey_in_WriteValue
mov ecx, dword [ebp - 0x54]
call fcn.0041127c
mov edi, dword [ebp - 0x54]
mov eax, dword [ebp - 0x64]
inc eax
cmp byte [ebp - 0x4d], 0
push 0
mov dword [ebp - 0x64], eax
pop edx
jne 0x4114da
mov esi, dword [ebp - 0x6c]
mov ecx, dword [ebp - 0x58]
test ecx, ecx
je 0x411775
mov dword [ebp - 0x58], edx
mov eax, dword [ecx]
call dword [eax + 4]
lea ecx, [ebp - 0xd0]
call fcn.0040f504
test esi, esi
je 0x41178c
push esi
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
pop ecx
mov eax, edi
jmp 0x411792
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0043182e
leave
ret 4
push 0x599491
call fcn.0040ecbf
int3