Function at 0x405a7f
Capabilities:
Set registry value

Disassembly:
push ebp
lea ebp, [esp - 0x1108]
mov eax, 0x1108
call fcn.0040b390
push 0xffffffffffffffff
push 0x40c65f
mov eax, dword fs:[0]
push eax
sub esp, 0x1c
mov eax, dword [0x41228c]
xor eax, ebp
mov dword [ebp + 0x1104], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x10], esp
mov eax, dword [ebp + 0x1118]
mov ebx, dword [ebp + 0x1110]
mov esi, dword [ebp + 0x1114]
and dword [ebp - 0x14], 0
mov dword [ebp - 0x28], eax
lea eax, [ebp + 0x104]
mov edi, ecx
push eax
mov dword [ebp - 0x24], edi
mov dword [ebp - 0x1c], ebx
mov dword [ebp - 0x20], esi
call fcn.0040a0af
test eax, eax
js 0x405df5
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp + 0x104]
push eax
call fcn.00401801
pop ecx
pop ecx
test eax, eax
jne 0x405b17
mov eax, 0x80020009
jmp 0x405df5
mov ecx, edi
call fcn.0040193a
lea eax, [ebp + 0x104]
push eax
mov ecx, edi
call fcn.0040a0af
test eax, eax
js 0x405df5
movzx eax, word [ebp - 0x14]
sub eax, 8
je 0x405dc4
sub eax, 9
je 0x405cd8
dec eax
dec eax
je 0x405c2b
sub eax, 0x3ff5
jne 0x405de4
lea eax, [ebp + 0x104]
push eax
call dword [sym.imp.kernel32.dll_lstrlenA]
and dword [ebp], 0
add eax, 2
and dword [ebp - 4], 0
push 1
push eax
mov byte [ebp - 4], 1
call fcn.0040a0af
pop ecx
pop ecx
cmp eax, 0x100
jbe 0x405bc9
push eax
lea ecx, [ebp]
call fcn.004051ae
mov esi, dword [ebp]
test esi, esi
je 0x405c0f
cmp byte [ebp + 0x104], 0
lea edi, [ebp + 0x104]
je 0x405bf8
mov ebx, dword [sym.imp.USER32.dll_CharNextA]
push edi
call ebx
mov cl, byte [edi]
cmp cl, 0x5c
jne 0x405bd7
cmp byte [eax], 0x30
jne 0x405bd7
mov byte [esi], 0
push eax
inc esi
call ebx
mov edi, eax
jmp 0x405bf3
lea eax, [ebp + 4]
mov dword [ebp], eax
jmp 0x405b93
mov byte [esi], cl
movzx eax, byte [edi]
push eax
call dword [sym.imp.kernel32.dll_IsDBCSLeadByte]
test eax, eax
je 0x405bf1
inc esi
inc edi
mov al, byte [edi]
test al, al
je 0x405bf8
mov byte [esi], al
inc esi
inc edi
cmp byte [edi], 0
jne 0x405baf
mov ecx, dword [ebp - 0x1c]
mov word [esi], 0
push dword [ebp]
push dword [ebp - 0x20]
call fcn.004016e8
mov esi, eax
jmp 0x405c12
push 0xe
pop esi
lea eax, [ebp + 4]
cmp dword [ebp], eax
je 0x405dd7
lea ecx, [ebp]
call fcn.004051a4
jmp 0x405dd7
and dword [ebp - 0x14], 0
push 3
pop edi
lea eax, [ebp + 0x104]
push eax
mov dword [ebp - 4], edi
call dword [sym.imp.kernel32.dll_lstrlenA]
inc eax
push 2
push eax
mov dword [ebp - 0x18], eax
lea eax, [ebp - 0x18]
push eax
call fcn.00401009
add esp, 0xc
test eax, eax
js 0x405c9b
mov esi, dword [ebp - 0x18]
cmp esi, 0x400
jg 0x405c7d
push esi
call fcn.0040523c
pop ecx
test al, al
je 0x405c7d
mov eax, esi
call fcn.0040b460
mov dword [ebp - 0x10], esp
mov eax, esp
jmp 0x405c86
push esi
lea ecx, [ebp - 0x14]
call fcn.004053e8
push edi
shr esi, 1
push esi
lea ecx, [ebp + 0x104]
push ecx
push eax
call fcn.0040a0af
test eax, eax
jne 0x405cad
lea ecx, [ebp - 0x14]
call fcn.00405129
mov eax, 0x8007000e
jmp 0x405df5
lea ecx, [ebp - 0x1c]
push ecx
push 0
push 0
push eax
call dword [sym.imp.OLEAUT32.dll_VarUI4FromDisp]
push dword [ebp - 0x1c]
mov ecx, ebx
push dword [ebp - 0x20]
call fcn.0040169a
lea ecx, [ebp - 0x14]
mov esi, eax
call fcn.00405129
jmp 0x405dd7
lea eax, [ebp + 0x104]
push eax
call dword [sym.imp.kernel32.dll_lstrlenA]
mov dword [ebp - 0x18], eax
test al, 1
je 0x405cf6
mov eax, 0x80004005
jmp 0x405df5
and dword [ebp], 0
cdq
sub eax, edx
mov ebx, eax
sar ebx, 1
mov dword [ebp - 0x14], ebx
push 1
mov dword [ebp - 4], 4
push ebx
mov byte [ebp - 4], 5
call fcn.0040a0af
pop ecx
pop ecx
cmp eax, 0x100
jbe 0x405d2b
push eax
lea ecx, [ebp]
call fcn.004051ae
jmp 0x405d3c
lea eax, [ebp + 4]
mov dword [ebp], eax
jmp 0x405d3c
xor edi, edi
cmp dword [ebp], edi
jne 0x405d54
lea eax, [ebp + 4]
test eax, eax
je 0x405cec
lea ecx, [ebp]
call fcn.004051a4
jmp 0x405cec
push ebx
push edi
push dword [ebp]
call sub.MSVCR100.dll_memset
add esp, 0xc
cmp dword [ebp - 0x18], edi
jle 0x405d99
mov ecx, dword [ebp]
mov eax, edi
cdq
sub eax, edx
sar eax, 1
lea esi, [eax + ecx]
movzx eax, byte [ebp + edi + 0x104]
push eax
call fcn.00401895
pop ecx
mov edx, edi
and edx, 1
shl edx, 2
push 4
pop ecx
sub ecx, edx
shl al, cl
or byte [esi], al
inc edi
cmp edi, dword [ebp - 0x18]
jl 0x405d66
mov eax, dword [ebp - 0x1c]
mov eax, dword [eax]
push ebx
push dword [ebp]
push 3
push 0
push dword [ebp - 0x20]
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov esi, eax
lea eax, [ebp + 4]
cmp dword [ebp], eax
je 0x405dd7
lea ecx, [ebp]
call fcn.004051a4
jmp 0x405dd7
push 1
lea eax, [ebp + 0x104]
push eax
push esi
mov ecx, ebx
call fcn.0040a0af
mov esi, eax
test esi, esi
je 0x405de4
push esi
call fcn.004012b8
pop ecx
jmp 0x405df5
push dword [ebp - 0x28]
mov ecx, dword [ebp - 0x24]
call fcn.0040a0af
test eax, eax
js 0x405df5
xor eax, eax
lea esp, [ebp - 0x38]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x1104]
xor ecx, ebp
call fcn.0040b376
add ebp, 0x1108
leave
ret 0xc