Function at 0x4085f0
Capabilities:
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
mov ebx, dword [ebp + 8]
push esi
xor esi, esi
mov dword [ebp - 4], 0
test ebx, ebx
je 0x408827
cmp dword [ebp + 0xc], esi
je 0x408827
push edi
push esi
lea eax, [ebp - 4]
push eax
push esi
push 0x2001f
push esi
push esi
push esi
push ebx
push reloc.SHLWAPI.dll_ParseURLW
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
mov edi, eax
test edi, edi
je 0x4086d9
mov ecx, dword [0x449ff8]
test ecx, ecx
je 0x4086c0
mov esi, dword [ecx]
mov eax, esi
mov edx, dword [ecx + 4]
or eax, edx
mov dword [ebp - 0xc], edx
je 0x4086c0
test byte [ecx + 8], 1
je 0x4086c0
cmp byte [ecx + 0xf], 9
jb 0x4086c0
movzx edx, word [ebx]
mov dword [ebp - 8], edi
test dx, dx
je 0x40868a
mov ecx, ebx
lea eax, [ecx + 2]
mov dword [ebp + 8], eax
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x408671
sub ecx, dword [ebp + 8]
sar ecx, 1
lea ecx, [ecx*2 + 2]
jmp 0x40868f
mov ecx, 0xe
push 0
push 4
test dx, dx
mov eax, str._NULL_
lea edx, [ebp - 8]
push edx
push ecx
cmovne eax, ebx
push eax
push 0x11
push str.WriteRegKeyDWORD
push 0x14
push 0x43d36c
push 0x2b
push dword [ebp - 0xc]
push esi
call fcn.0041bd20
add esp, 0x30
test edi, edi
jg 0x4086c8
mov esi, edi
jmp 0x4086d1
movzx esi, di
or esi, 0x80070000
test esi, esi
js 0x40881c
mov ebx, dword [ebp + 0xc]
lea eax, [ebp + 0x10]
push 4
push eax
push 4
push 0
push ebx
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov edi, eax
test edi, edi
je 0x4087a7
mov ecx, dword [0x449ff8]
test ecx, ecx
je 0x408796
mov edx, dword [ecx]
mov eax, edx
mov esi, dword [ecx + 4]
or eax, esi
je 0x408796
test byte [ecx + 8], 1
je 0x408796
cmp byte [ecx + 0xf], 9
jb 0x408796
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0xc], eax
movzx eax, word [ebx]
mov dword [ebp + 8], edi
test ax, ax
je 0x40875c
mov ecx, ebx
lea eax, [ecx + 2]
mov dword [ebp + 0xc], eax
nop dword [eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x408740
sub ecx, dword [ebp + 0xc]
movzx eax, word [ebx]
sar ecx, 1
lea ecx, [ecx*2 + 2]
jmp 0x408761
mov ecx, 0xe
push 0
push 4
test ax, ax
mov eax, str._NULL_
cmovne eax, ebx
lea ebx, [ebp + 8]
push ebx
push 4
lea ebx, [ebp - 0xc]
push ebx
push ecx
push eax
push 0x11
push str.WriteRegKeyDWORD
push 0x15
push 0x43d36c
push 0x2b
push esi
push edx
call fcn.0041bd20
add esp, 0x38
test edi, edi
jg 0x40879e
mov esi, edi
jmp 0x4087a7
movzx esi, di
or esi, 0x80070000
push dword [ebp - 4]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov edi, eax
test edi, edi
je 0x40881c
mov ecx, dword [0x449ff8]
test ecx, ecx
je 0x4087fc
mov esi, dword [ecx]
mov eax, esi
mov edx, dword [ecx + 4]
or eax, edx
je 0x4087fc
test byte [ecx + 8], 1
je 0x4087fc
cmp byte [ecx + 0xf], 9
jb 0x4087fc
push 0
push 4
lea eax, [ebp + 0xc]
mov dword [ebp + 0xc], edi
push eax
push 0x11
push str.WriteRegKeyDWORD
push 0x16
push 0x43d36c
push 0x2b
push edx
push esi
call fcn.0041bd20
add esp, 0x28
test edi, edi
jg 0x40880b
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
movzx eax, di
pop edi
pop esi
or eax, 0x80070000
pop ebx
mov esp, ebp
pop ebp
ret 0xc
pop edi
mov eax, esi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 0xc
mov ecx, dword [0x449ff8]
test ecx, ecx
je 0x408864
mov esi, dword [ecx]
mov eax, esi
mov edx, dword [ecx + 4]
or eax, edx
je 0x408864
test byte [ecx + 8], 1
je 0x408864
cmp byte [ecx + 0xf], 9
jb 0x408864
push 0
push 0x11
push str.WriteRegKeyDWORD
push 0x13
push 0x43d36c
push 0x2b
push edx
push esi
call fcn.0041bd20
add esp, 0x20
pop esi
mov eax, 0x80070057
pop ebx
mov esp, ebp
pop ebp
ret 0xc