Function at 0x40b13e
Capabilities:
Set registry value

Disassembly:
push ebp
mov eax, 0x201c
lea ebp, [esp - 0x1fa0]
call fcn.00414500
mov eax, dword [0x418894]
and dword [ebp - 0x70], 0
push ebx
push esi
mov esi, dword [sym.imp.msvcrt.dll_malloc]
push edi
mov ebx, ecx
mov edi, 0x2000
push edi
mov dword [ebp + 0x1f9c], eax
mov dword [ebp - 0x78], ebx
call esi
test eax, eax
pop ecx
mov dword [ebp - 0x74], eax
jne 0x40b187
mov esi, 0x8007000e
jmp 0x40b3f3
push eax
mov ecx, ebx
call fcn.00409c27
test eax, eax
jge 0x40b19a
mov esi, eax
jmp 0x40b3e9
lea eax, [ebp - 0x66]
push eax
push dword [ebp - 0x74]
call fcn.00409a0a
test eax, eax
jne 0x40b1b4
mov esi, 0x80020009
jmp 0x40b3e9
push edi
call esi
mov edi, eax
test edi, edi
pop ecx
mov dword [ebp - 0x6c], edi
jne 0x40b1cb
mov esi, 0x8007000e
jmp 0x40b3e9
mov ecx, ebx
call fcn.00409c05
push edi
mov ecx, ebx
call fcn.00409c27
test eax, eax
jge 0x40b1e5
mov esi, eax
jmp 0x40b3e1
movzx eax, word [ebp - 0x66]
sub eax, 8
je 0x40b2f5
sub eax, 9
je 0x40b227
dec eax
dec eax
jne 0x40b3c9
lea eax, [ebp - 0x7c]
push eax
push 0
push 0
push edi
call dword [sym.imp.OLEAUT32.dll_VarUI4FromDisp]
push dword [ebp + 0x1fac]
mov ecx, dword [ebp + 0x1fa8]
push dword [ebp - 0x7c]
call fcn.004097e1
jmp 0x40b3c9
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
test al, 1
mov dword [ebp + 0x1fb4], eax
je 0x40b242
mov esi, 0x80004005
jmp 0x40b3e1
cdq
sub eax, edx
mov esi, eax
sar esi, 1
cmp esi, 0x400
mov dword [ebp - 0x68], esi
ja 0x40b26f
push esi
call fcn.0040964e
test al, al
je 0x40b26f
mov eax, esi
add eax, 3
and eax, 0xfffffffc
call fcn.00414500
mov ebx, esp
jmp 0x40b27a
push esi
lea ecx, [ebp - 0x70]
call fcn.0040b085
mov ebx, eax
test ebx, ebx
je 0x40b238
mov ecx, esi
mov edx, ecx
shr ecx, 2
xor eax, eax
mov edi, ebx
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
xor edi, edi
cmp dword [ebp + 0x1fb4], edi
jle 0x40b2d2
mov eax, edi
cdq
sub eax, edx
sar eax, 1
lea esi, [eax + ebx]
mov eax, dword [ebp - 0x6c]
movzx eax, word [eax + edi*2]
push eax
call fcn.00409a8b
mov ecx, edi
and ecx, 1
shl ecx, 2
mov edx, ecx
push 4
pop ecx
sub ecx, edx
shl al, cl
or byte [esi], al
inc edi
cmp edi, dword [ebp + 0x1fb4]
jl 0x40b29c
mov esi, dword [ebp - 0x68]
mov eax, dword [ebp + 0x1fa8]
mov eax, dword [eax]
push esi
push ebx
push 3
push 0
push dword [ebp + 0x1fac]
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov edi, dword [ebp - 0x6c]
jmp 0x40b3c9
cmp byte [ebp + 0x1fb4], 0
mov esi, edi
je 0x40b3b7
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
cmp eax, 0xffe
jle 0x40b31c
mov esi, 0x80004005
jmp 0x40b3f3
mov ecx, dword [ebx + 4]
and dword [ebp + 0x1fb4], 0
push 0x401eb8
call fcn.0040a49e
test eax, eax
mov dword [ebp - 0x68], eax
je 0x40b3ac
push eax
push edi
call fcn.00409b4c
mov ebx, eax
test ebx, ebx
je 0x40b3ac
cmp ebx, dword [ebp + 0x1fb0]
je 0x40b35a
push ebx
push edi
call dword [sym.imp.USER32.dll_CharPrevW]
cmp word [eax], 0x22
je 0x40b3ac
and word [ebp - 0x64], 0
mov eax, ebx
sub eax, edi
sar eax, 1
push eax
push edi
lea eax, [ebp - 0x64]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
mov esi, dword [sym.imp.KERNEL32.dll_lstrcatW]
mov edi, 0x401eb4
push edi
lea eax, [ebp - 0x64]
push eax
call esi
push dword [ebp - 0x68]
lea eax, [ebp - 0x64]
push eax
call esi
push edi
lea eax, [ebp - 0x64]
push eax
call esi
push dword [ebp - 0x68]
call dword [sym.imp.KERNEL32.dll_lstrlenW]
lea eax, [ebx + eax*2]
push eax
lea eax, [ebp - 0x64]
push eax
call esi
mov edi, dword [ebp - 0x6c]
lea esi, [ebp - 0x64]
lea ecx, [ebp + 0x1fb4]
call fcn.0040a23d
push dword [ebp + 0x1fac]
mov ecx, dword [ebp + 0x1fa8]
push esi
call fcn.004097fb
push dword [ebp + 0x1fb0]
mov ecx, dword [ebp - 0x78]
call fcn.00409c27
test eax, eax
jl 0x40b1de
xor esi, esi
push edi
call dword [sym.imp.msvcrt.dll_free]
pop ecx
push dword [ebp - 0x74]
call dword [sym.imp.msvcrt.dll_free]
pop ecx
lea ecx, [ebp - 0x70]
call fcn.0040a23d
mov eax, esi
lea esp, [ebp - 0x88]
mov ecx, dword [ebp + 0x1f9c]
call fcn.00414118
pop edi
pop esi
pop ebx
add ebp, 0x1fa0
leave
ret 0x10