Function at 0x40a710
Capabilities:
Set registry value

Disassembly:
mov eax, 0x211c
call fcn.00413820
mov eax, dword [0x42a718]
xor eax, esp
mov dword [esp + 0x2118], eax
mov eax, dword [esp + 0x2128]
push ebx
mov ebx, dword [esp + 0x2124]
push ebp
push esi
mov esi, ecx
push edi
mov edi, dword [esp + 0x2134]
lea ecx, [esp + 0x128]
push ecx
xor ebp, ebp
mov ecx, esi
mov dword [esp + 0x20], esi
mov dword [esp + 0x14], ebx
mov dword [esp + 0x18], edi
mov dword [esp + 0x24], eax
mov dword [esp + 0x1c], ebp
call fcn.00409380
cmp eax, ebp
jl 0x40a9ec
lea edx, [esp + 0x18]
push edx
lea eax, [esp + 0x12c]
push eax
call fcn.004091c0
add esp, 8
test eax, eax
jne 0x40a793
mov eax, 0x80020009
jmp 0x40a9ec
mov ecx, esi
call fcn.00409320
lea ecx, [esp + 0x128]
push ecx
mov ecx, esi
call fcn.00409380
cmp eax, ebp
jl 0x40a9ec
movzx eax, word [esp + 0x18]
cmp eax, 0x13
jg 0x40a911
je 0x40a8d8
cmp eax, 8
je 0x40a8c2
cmp eax, 0x11
jne 0x40a9d4
lea edx, [esp + 0x128]
push edx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov ebx, eax
test bl, 1
jne 0x40a81c
cdq
sub eax, edx
mov ebp, eax
sar ebp, 1
xor esi, esi
push ebp
lea ecx, [esp + 0x28]
mov dword [esp + 0x28], esi
call fcn.00409de0
mov eax, dword [esp + 0x24]
cmp eax, esi
jne 0x40a826
lea eax, [esp + 0x28]
test eax, eax
je 0x40a81c
lea ecx, [esp + 0x24]
call fcn.00409660
mov eax, 0x80004005
jmp 0x40a9ec
push ebp
push esi
push eax
call fcn.00412ba0
add esp, 0xc
cmp ebx, esi
jle 0x40a879
jmp 0x40a840
movzx eax, word [esp + esi*2 + 0x128]
mov edx, dword [esp + 0x24]
mov ecx, esi
shr ecx, 1
push eax
lea edi, [ecx + edx]
call fcn.00409270
mov ecx, esi
and ecx, 1
add ecx, ecx
add ecx, ecx
mov edx, ecx
mov ecx, 4
sub ecx, edx
shl al, cl
add esi, 1
add esp, 4
or byte [edi], al
cmp esi, ebx
jl 0x40a840
mov ecx, dword [esp + 0x24]
mov edx, dword [esp + 0x14]
mov eax, dword [esp + 0x10]
mov eax, dword [eax]
push ebp
push ecx
push 3
push 0
push edx
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov edi, eax
lea eax, [esp + 0x28]
cmp dword [esp + 0x24], eax
je 0x40a8aa
lea ecx, [esp + 0x24]
call fcn.00409660
xor ebp, ebp
cmp edi, ebp
je 0x40a9d0
push edi
call fcn.00408ea0
add esp, 4
jmp 0x40a9ec
push 1
lea ecx, [esp + 0x12c]
push ecx
push edi
mov ecx, ebx
call fcn.00409020
mov edi, eax
jmp 0x40a8ac
call dword [0x42a68c]
lea edx, [esp + 0x14]
push edx
push ebp
push ebp
lea eax, [esp + 0x134]
push eax
mov dword [esp + 0x20], ebp
call dword [sym.imp.OLEAUT32.dll_VarUI4FromDisp]
mov ecx, dword [esp + 0x14]
push ecx
push edi
mov ecx, ebx
call fcn.00409000
lea ecx, [esp + 0x10]
mov edi, eax
call fcn.004095f0
jmp 0x40a8ac
cmp eax, 0x4008
jne 0x40a9d4
lea edx, [esp + 0x128]
push edx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
add eax, 2
push eax
lea ecx, [esp + 0x28]
mov dword [esp + 0x28], ebp
call fcn.00409d90
mov esi, dword [esp + 0x24]
cmp esi, ebp
je 0x40a9b1
cmp word [esp + 0x128], bp
lea edi, [esp + 0x128]
je 0x40a991
mov ebx, dword [sym.imp.USER32.dll_CharNextW]
lea ebx, [ebx]
push edi
call ebx
movzx ecx, word [edi]
cmp cx, 0x5c
jne 0x40a97f
cmp word [eax], 0x30
jne 0x40a97f
mov word [esi], bp
push eax
add esi, 2
call ebx
mov edi, eax
jmp 0x40a988
mov word [esi], cx
add esi, 2
add edi, 2
cmp word [edi], bp
jne 0x40a960
mov ebx, dword [esp + 0x10]
mov ecx, dword [esp + 0x14]
mov word [esi], bp
mov word [esi + 2], bp
mov eax, dword [esp + 0x24]
push eax
push ecx
mov ecx, ebx
call fcn.00409060
mov esi, dword [esp + 0x24]
mov edi, eax
jmp 0x40a9b6
mov edi, 0xe
lea edx, [esp + 0x28]
cmp esi, edx
je 0x40a8ac
lea ecx, [esp + 0x24]
call fcn.00409660
jmp 0x40a8ac
mov esi, dword [esp + 0x1c]
mov eax, dword [esp + 0x20]
push eax
mov ecx, esi
call fcn.00409380
xor ecx, ecx
cmp eax, ebp
setge cl
sub ecx, 1
and eax, ecx
mov ecx, dword [esp + 0x2128]
pop edi
pop esi
pop ebp
pop ebx
xor ecx, esp
call fcn.00412b82
add esp, 0x211c
ret 0xc