Function at 0x401c00
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, 0x354
mov eax, dword [0x41a038]
xor eax, ebp
mov dword [ebp - 4], eax
push esi
push edi
xor eax, eax
mov word [ebp - 0x2fc], ax
push 0x206
push 0
lea ecx, [ebp - 0x2fa]
push ecx
call fcn.00409320
add esp, 0xc
mov dword [ebp - 0x31c], 0
mov dword [ebp - 0x304], 0
mov dword [ebp - 0x300], 0x104
xor edx, edx
mov word [ebp - 0x2c], dx
xor eax, eax
mov dword [ebp - 0x2a], eax
mov dword [ebp - 0x26], eax
mov dword [ebp - 0x22], eax
mov dword [ebp - 0x1e], eax
mov dword [ebp - 0x1a], eax
mov dword [ebp - 0x16], eax
mov dword [ebp - 0x12], eax
mov dword [ebp - 0xe], eax
mov dword [ebp - 0xa], eax
mov word [ebp - 6], ax
mov dword [ebp - 0x318], 0x41cca8
mov ecx, dword [ebp - 0x318]
add ecx, 2
mov dword [ebp - 0x340], ecx
mov edx, dword [ebp - 0x318]
mov ax, word [edx]
mov word [ebp - 0x32c], ax
add dword [ebp - 0x318], 2
cmp word [ebp - 0x32c], 0
jne 0x401c92
mov ecx, dword [ebp - 0x318]
sub ecx, dword [ebp - 0x340]
sar ecx, 1
mov dword [ebp - 0x33c], ecx
je 0x401cf1
push 0x41cca8
push 0
push 0x20000
call dword [sym.imp.KERNEL32.dll_OpenEventW]
mov dword [ebp - 0x31c], eax
cmp dword [ebp - 0x31c], 0
je 0x401cf1
xor eax, eax
jmp 0x401ffb
lea edx, [ebp - 0x308]
push edx
push 0xf003f
push 0
push 0x418940
push connect
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x401d7e
lea eax, [ebp - 0x300]
push eax
lea ecx, [ebp - 0x2c]
push ecx
lea edx, [ebp - 0x304]
push edx
push 0
push 0x4189ac
mov eax, dword [ebp - 0x308]
push eax
call dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
test eax, eax
jne 0x401d71
lea ecx, [ebp - 0x2c]
push ecx
push 0
push 0x20000
call dword [sym.imp.KERNEL32.dll_OpenEventW]
mov dword [ebp - 0x31c], eax
cmp dword [ebp - 0x31c], 0
je 0x401d71
mov edx, dword [ebp - 0x308]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
jmp 0x401ffb
mov eax, dword [ebp - 0x308]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
lea ecx, [ebp - 0x2fc]
push ecx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
mov dword [ebp - 0x310], 0x41cca8
mov edx, dword [ebp - 0x310]
add edx, 2
mov dword [ebp - 0x344], edx
mov eax, dword [ebp - 0x310]
mov cx, word [eax]
mov word [ebp - 0x32e], cx
add dword [ebp - 0x310], 2
cmp word [ebp - 0x32e], 0
jne 0x401da9
mov edx, dword [ebp - 0x310]
sub edx, dword [ebp - 0x344]
sar edx, 1
mov dword [ebp - 0x34c], edx
jne 0x401e64
push 0x4189bc
push 0x4189c8
push 0x41c1a0
call fcn.00402500
add esp, 0xc
mov dword [ebp - 0x334], 0x4189d8
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x324], eax
mov ecx, dword [ebp - 0x324]
mov dword [ebp - 0x354], ecx
mov edx, dword [ebp - 0x334]
mov ax, word [edx]
mov word [ebp - 0x314], ax
mov ecx, dword [ebp - 0x324]
mov dx, word [ebp - 0x314]
mov word [ecx], dx
mov eax, dword [ebp - 0x334]
add eax, 2
mov dword [ebp - 0x334], eax
mov ecx, dword [ebp - 0x324]
add ecx, 2
mov dword [ebp - 0x324], ecx
cmp word [ebp - 0x314], 0
jne 0x401e1a
jmp 0x401ee2
push 0x41cca8
push 0x4189e4
push 0x41c1a0
call fcn.00402500
add esp, 0xc
mov dword [ebp - 0x328], 0x41cca8
lea edx, [ebp - 0x2c]
mov dword [ebp - 0x320], edx
mov eax, dword [ebp - 0x320]
mov dword [ebp - 0x350], eax
mov ecx, dword [ebp - 0x328]
mov dx, word [ecx]
mov word [ebp - 0x312], dx
mov eax, dword [ebp - 0x320]
mov cx, word [ebp - 0x312]
mov word [eax], cx
mov edx, dword [ebp - 0x328]
add edx, 2
mov dword [ebp - 0x328], edx
mov eax, dword [ebp - 0x320]
add eax, 2
mov dword [ebp - 0x320], eax
cmp word [ebp - 0x312], 0
jne 0x401e9a
push 0x41c1a0
push 0x104
lea ecx, [ebp - 0x2fc]
push ecx
call fcn.004058d6
add esp, 0xc
call fcn.00401bb0
test eax, eax
jne 0x401ff9
push 0x64
call dword [sym.imp.KERNEL32.dll_Sleep]
push 1
push 0
push 0x4189f4
lea edx, [ebp - 0x2fc]
push edx
push 0
push 0
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
mov ecx, 0x1a
mov esi, 0x4189f8
lea edi, [ebp - 0xf4]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
push 0x5e
push 0
lea eax, [ebp - 0x8a]
push eax
call fcn.00409320
add esp, 0xc
lea ecx, [ebp - 0x308]
push ecx
push 3
push 0
lea edx, [ebp - 0xf4]
push edx
push connect
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x401ff9
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x30c], eax
mov ecx, dword [ebp - 0x30c]
add ecx, 2
mov dword [ebp - 0x338], ecx
mov edx, dword [ebp - 0x30c]
mov ax, word [edx]
mov word [ebp - 0x32a], ax
add dword [ebp - 0x30c], 2
cmp word [ebp - 0x32a], 0
jne 0x401f8e
mov ecx, dword [ebp - 0x30c]
sub ecx, dword [ebp - 0x338]
sar ecx, 1
mov dword [ebp - 0x348], ecx
mov edx, dword [ebp - 0x348]
lea eax, [edx + edx + 2]
push eax
lea ecx, [ebp - 0x2c]
push ecx
push 1
push 0
push 0x418a64
mov edx, dword [ebp - 0x308]
push edx
call dword [sym.imp.ADVAPI32.dll_RegSetValueExW]
test eax, eax
jne 0x401ff9
mov eax, dword [ebp - 0x308]
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor eax, eax
pop edi
pop esi
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040565b
mov esp, ebp
pop ebp
ret