Function at 0x404579
Capabilities:
Set registry value

Disassembly:
push ebp
mov eax, 0x211c
lea ebp, [esp - 0x209c]
call fcn.0040f370
mov eax, dword [0x413040]
and dword [ebp - 0x70], 0
xor eax, ebp
push ebx
mov ebx, dword [ebp + 0x20a4]
mov dword [ebp + 0x2098], eax
mov eax, dword [ebp + 0x20a8]
push esi
push edi
mov esi, ecx
mov edi, edx
mov dword [ebp - 0x80], eax
lea eax, [ebp + 0x98]
mov dword [ebp - 0x7c], esi
mov dword [ebp - 0x78], edi
mov dword [ebp - 0x74], ebx
call fcn.00403f47
test eax, eax
jl 0x4047e9
lea eax, [ebp - 0x70]
push eax
lea eax, [ebp + 0x98]
push eax
call fcn.00404803
test eax, eax
pop ecx
pop ecx
jne 0x4045ee
mov eax, 0x80020009
jmp 0x4047e9
call fcn.00404b77
mov ecx, dword [ebp - 0x7c]
lea eax, [ebp + 0x98]
call fcn.00403f47
test eax, eax
jl 0x4047e9
movzx eax, word [ebp - 0x70]
sub eax, 8
je 0x4047b9
sub eax, 9
je 0x404702
dec eax
dec eax
je 0x4046ca
sub eax, 0x3ff5
jne 0x4047d8
lea eax, [ebp + 0x98]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
and dword [ebp - 0x6c], 0
inc eax
add eax, eax
push eax
lea esi, [ebp - 0x6c]
call fcn.004048c0
mov esi, dword [ebp - 0x6c]
test esi, esi
je 0x4046ae
cmp word [ebp + 0x98], 0
lea edi, [ebp + 0x98]
je 0x404698
mov ebx, dword [sym.imp.USER32.dll_CharNextW]
push edi
call ebx
mov cx, word [edi]
cmp cx, 0x5c
jne 0x40468b
cmp word [eax], 0x30
jne 0x40468b
and word [esi], 0
inc esi
push eax
inc esi
call ebx
mov edi, eax
jmp 0x404692
mov word [esi], cx
inc esi
inc esi
inc edi
inc edi
cmp word [edi], 0
jne 0x40466c
and word [esi], 0
push dword [ebp - 0x6c]
push dword [ebp - 0x74]
push dword [ebp - 0x78]
call fcn.004048e0
mov edi, eax
jmp 0x4046b1
push 0xe
pop edi
lea eax, [ebp - 0x68]
cmp dword [ebp - 0x6c], eax
je 0x4047cb
lea eax, [ebp - 0x6c]
call fcn.00404938
jmp 0x4047cb
call dword [0x413078]
and dword [ebp - 0x78], 0
lea eax, [ebp - 0x74]
push eax
push 0
push 0
lea eax, [ebp + 0x98]
push eax
call dword [sym.imp.OLEAUT32.dll_VarUI4FromDisp]
push dword [ebp - 0x74]
push ebx
push edi
call fcn.0040491a
lea esi, [ebp - 0x78]
mov edi, eax
call fcn.004037bf
jmp 0x4047cb
lea eax, [ebp + 0x98]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
test al, 1
mov dword [ebp - 0x70], eax
jne 0x40473e
cdq
sub eax, edx
mov ebx, eax
sar ebx, 1
xor edi, edi
push ebx
lea esi, [ebp - 0x6c]
mov dword [ebp - 0x6c], edi
call fcn.004048c0
cmp dword [ebp - 0x6c], edi
jne 0x404748
lea eax, [ebp - 0x68]
test eax, eax
je 0x40473e
mov eax, esi
call fcn.00404938
mov eax, 0x80004005
jmp 0x4047e9
push ebx
push edi
push dword [ebp - 0x6c]
call sub.MSVCRT.dll_memset
add esp, 0xc
cmp dword [ebp - 0x70], 0
jle 0x40478e
mov ecx, dword [ebp - 0x6c]
mov eax, edi
cdq
sub eax, edx
sar eax, 1
lea esi, [eax + ecx]
mov ax, word [ebp + edi*2 + 0x98]
call fcn.00404942
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 - 0x70]
jl 0x40475b
mov eax, dword [ebp - 0x78]
mov eax, dword [eax]
push ebx
push dword [ebp - 0x6c]
push 3
push 0
push dword [ebp - 0x74]
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
mov edi, eax
lea eax, [ebp - 0x68]
cmp dword [ebp - 0x6c], eax
je 0x4047cb
lea eax, [ebp - 0x6c]
call fcn.00404938
jmp 0x4047cb
push 1
lea eax, [ebp + 0x98]
push eax
push ebx
push edi
call fcn.00404895
mov edi, eax
test edi, edi
je 0x4047d8
mov eax, edi
call fcn.00404b68
jmp 0x4047e9
mov eax, dword [ebp - 0x80]
mov ecx, dword [ebp - 0x7c]
call fcn.00403f47
test eax, eax
jl 0x4047e9
xor eax, eax
mov ecx, dword [ebp + 0x2098]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0040f143
add ebp, 0x209c
leave
ret 8