Function at 0x40595e
Capabilities:
Check if file exists
Create process on windows
Create thread
Delete directory
Delete file
Get file attributes
Read file on windows
Set file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x63c
mov eax, dword [ebp + 8]
push ebx
mov ebx, dword [sym.imp.KERNEL32.dll_lstrcpyW]
push esi
xor esi, esi
push edi
mov dword [ebp - 0x1c], 1
mov dword [ebp - 0x18], esi
mov edi, 0x416070
cmp word [eax], si
jne 0x405b71
push 0x104
push eax
push dword [0x416460]
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push 0x411844
push dword [ebp + 8]
call fcn.00402d20
pop ecx
pop ecx
mov dword [0x41eb6c], eax
cmp eax, esi
je 0x405bf1
push 2
push esi
push eax
call fcn.00407b37
push dword [0x41eb6c]
call fcn.004084dc
push dword [0x416460]
mov dword [ebp - 0xc], eax
call fcn.00402368
add esp, 0x14
mov dword [ebp - 4], eax
cmp dword [ebp - 0xc], eax
jbe 0x405c3d
push 0x3e4
call fcn.0040874c
push 0
push dword [ebp - 4]
mov esi, eax
push dword [0x41eb6c]
call fcn.00407b37
push dword [0x41eb6c]
push 0x3e4
push 1
push esi
call fcn.00407a90
add esp, 0x20
cmp eax, 0x3e4
jne 0x405b57
cmp byte [esi], 0x44
jne 0x405b57
cmp byte [esi + 1], 0x45
jne 0x405b57
cmp byte [esi + 2], 0x43
jne 0x405b57
cmp byte [esi + 3], 0x4c
jne 0x405b57
cmp byte [esi + 4], 0x48
jne 0x405b57
cmp byte [esi + 5], 0x41
jne 0x405b57
cmp byte [esi + 7], 0x55
jne 0x405b57
cmp word [esi + 0x210], 0
jne 0x405a83
and dword [esi + 0x318], 0
mov byte [esi + 6], 0x33
cmp byte [esi + 6], 0x36
jne 0x405ae6
push 0xffffffffffffffff
call fcn.0040546f
pop ecx
test eax, eax
jne 0x405adf
push esi
call fcn.00407408
push dword [0x41eb6c]
call fcn.0040884d
pop ecx
pop ecx
push 0x80
lea eax, [ebp - 0x13c]
push eax
push 0x16
push dword [0x416460]
call dword [sym.imp.USER32.dll_LoadStringW]
push 0x10
push str.LHA_SFX
lea eax, [ebp - 0x13c]
push eax
push 0
call dword [sym.imp.USER32.dll_MessageBoxW]
xor eax, eax
jmp 0x40608a
mov byte [0x41606e], 0x36
push dword [ebp + 8]
push esi
push edi
call fcn.004025e4
add esp, 0xc
mov dword [ebp - 0x18], eax
lea eax, [esi + 0x210]
push eax
push 0x416278
call ebx
mov eax, dword [esi + 0x310]
mov dword [0x416378], eax
mov eax, dword [esi + 0x314]
mov dword [0x41637c], eax
mov eax, dword [esi + 0x318]
mov dword [0x416380], eax
mov eax, dword [esi + 0x31c]
mov dword [0x416384], eax
mov eax, dword [esi + 0x320]
mov dword [0x416388], eax
lea eax, [esi + 0x324]
push eax
push 0x41638c
call ebx
lea eax, [esi + 0x364]
push eax
push 0x4163cc
call ebx
push esi
call fcn.00407408
push 0
push 0
push dword [0x41eb6c]
call fcn.00407b37
add esp, 0x10
xor esi, esi
mov dword [ebp - 4], esi
cmp dword [0x41eb6c], esi
jne 0x405bf9
push 0x411844
push dword [ebp + 8]
call fcn.00402d20
pop ecx
pop ecx
mov dword [0x41eb6c], eax
cmp eax, esi
je 0x405bc3
push 2
push esi
push eax
call fcn.00407b37
push dword [0x41eb6c]
call fcn.004084dc
push esi
push esi
push dword [0x41eb6c]
mov dword [ebp - 0xc], eax
call fcn.00407b37
add esp, 0x1c
cmp dword [0x41eb6c], esi
jne 0x405bf9
push 0x80
lea eax, [ebp - 0x13c]
push eax
push 0xc
push dword [0x416460]
call dword [sym.imp.USER32.dll_LoadStringW]
lea eax, [ebp - 0x13c]
push 0x10
push str.LHA_SFX
push eax
push esi
jmp 0x405ad2
mov dword [0x41eb6c], esi
jmp 0x405bc3
call fcn.00402fe6
lea eax, [ebp - 4]
push esi
push eax
call fcn.00404858
pop ecx
pop ecx
test eax, eax
jne 0x405c4e
push 0x80
lea eax, [ebp - 0x13c]
push eax
push 0xd
push dword [0x416460]
call dword [sym.imp.USER32.dll_LoadStringW]
push 0x10
push str.LHA_SFX
lea eax, [ebp - 0x13c]
push eax
push esi
call dword [sym.imp.USER32.dll_MessageBoxW]
push dword [0x41eb6c]
call fcn.0040884d
pop ecx
jmp 0x405ad8
cmp word [0x4163cc], si
je 0x405c6f
push 0x24
push 0x41638c
push 0x4163cc
push esi
call dword [sym.imp.USER32.dll_MessageBoxW]
cmp eax, 6
jne 0x405c3d
mov eax, dword [0x416388]
cmp eax, esi
je 0x405ca3
push dword [ebp + 8]
push dword [ebp - 4]
push dword [ebp - 0xc]
push eax
push dword [0x416460]
push dword [0x41eb6c]
call fcn.00402868
add esp, 0x18
test eax, eax
jne 0x405ca3
cmp word [0x416278], si
jne 0x405c3d
push esi
push dword [ebp - 4]
push dword [0x41eb6c]
call fcn.00407b37
lea eax, [ebp - 0x43c]
push eax
lea eax, [ebp - 0x23c]
push eax
push dword [ebp + 8]
call fcn.004022bd
add esp, 0x18
cmp word [0x416070], si
jne 0x405cde
lea eax, [ebp - 0x23c]
push eax
push edi
call ebx
lea eax, [ebp - 0x43c]
push 0x2e
push eax
call fcn.004073da
pop ecx
pop ecx
cmp eax, esi
je 0x405cf7
xor ecx, ecx
mov word [eax], cx
lea eax, [ebp - 0x43c]
push eax
call fcn.0040227b
pop ecx
cmp dword [0x416384], esi
jne 0x405d22
lea eax, [ebp - 0x43c]
push eax
call fcn.00401e16
pop ecx
cmp eax, 1
jne 0x405c3d
push edi
call fcn.0040229e
push edi
call fcn.0040225b
pop ecx
pop ecx
cmp word [0x416070], si
jne 0x405d48
lea eax, [ebp - 0x23c]
push eax
push edi
call ebx
jmp 0x405e56
push 0x5c
pop esi
push esi
push edi
call fcn.004073da
pop ecx
pop ecx
test eax, eax
jne 0x405d7a
push edi
call dword [sym.imp.KERNEL32.dll_lstrlenW]
cmp word [eax*2 + 0x41606e], 0x3a
je 0x405d7a
push edi
lea eax, [ebp - 0x23c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
jmp 0x405d39
mov ax, word [0x416070]
cmp ax, si
jne 0x405d95
cmp word [0x416072], si
je 0x405dab
push 0x416072
jmp 0x405d6b
cmp ax, 0x2e
jne 0x405dab
cmp word [0x416072], si
jne 0x405dab
push 0x416074
jmp 0x405d6b
push 0x41183c
push edi
call fcn.0040737a
pop ecx
pop ecx
cmp eax, edi
jne 0x405e56
and dword [ebp - 8], 0
push 0x41183c
push edi
jmp 0x405ddc
inc dword [ebp - 8]
add esi, 4
push esi
push edi
call ebx
push 0x41183c
push esi
call fcn.0040737a
mov esi, eax
pop ecx
pop ecx
test esi, esi
jne 0x405dcc
lea eax, [ebp - 0x23c]
push eax
call fcn.0040225b
lea eax, [ebp - 0x23c]
push eax
call fcn.00407442
and dword [ebp - 0x10], 0
cmp dword [ebp - 8], 0
pop ecx
pop ecx
mov esi, eax
jle 0x405e2d
push 0x5c
push esi
call fcn.004073da
pop ecx
pop ecx
test eax, eax
je 0x405e7c
xor ecx, ecx
inc dword [ebp - 0x10]
mov word [eax], cx
mov eax, dword [ebp - 0x10]
cmp eax, dword [ebp - 8]
jl 0x405e0f
push esi
lea eax, [ebp - 0x23c]
push eax
call ebx
push edi
lea eax, [ebp - 0x23c]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
lea eax, [ebp - 0x23c]
push eax
push edi
call ebx
push esi
call fcn.00407408
pop ecx
push str.____
push edi
call fcn.00407bb3
push edi
mov esi, eax
call fcn.00407497
add esp, 0xc
cmp esi, eax
je 0x405e94
lea eax, [ebp - 0x23c]
push eax
push edi
call ebx
jmp 0x405e8d
lea eax, [ebp - 0x23c]
push eax
push edi
call ebx
push esi
call fcn.00407408
pop ecx
xor esi, esi
jmp 0x405d04
push edi
call fcn.0040227b
push edi
call fcn.0040222e
pop ecx
pop ecx
push edi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
xor esi, esi
cmp eax, 0xffffffff
jne 0x405f46
mov ebx, dword [sym.imp.USER32.dll_LoadStringW]
cmp dword [0x416378], esi
jne 0x405f0e
push 0x80
lea eax, [ebp - 0x13c]
push eax
push 0xe
push dword [0x416460]
call ebx
push edi
lea eax, [ebp - 0x13c]
push eax
lea eax, [ebp - 0x63c]
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
push 0x21
push str.LHA_SFX
lea eax, [ebp - 0x63c]
push eax
push esi
call dword [sym.imp.USER32.dll_MessageBoxW]
cmp eax, 1
jne 0x405c3d
push edi
call fcn.004020dd
pop ecx
test eax, eax
jne 0x405f46
push dword [0x41eb6c]
call fcn.0040884d
pop ecx
push 0x80
lea eax, [ebp - 0x63c]
push eax
push 0x11
push dword [0x416460]
call ebx
lea eax, [ebp - 0x63c]
jmp 0x405be3
mov eax, dword [ebp - 0xc]
sub eax, dword [ebp - 4]
push esi
push eax
mov dword [0x41e36c], esi
call fcn.00401e84
or dword [ebp - 0x14], 0xffffffff
lea eax, [ebp - 0x20]
push eax
push esi
push dword [ebp + 8]
push 0x404ff5
push esi
push esi
call fcn.00408b09
mov ebx, dword [sym.imp.USER32.dll_GetMessageW]
add esp, 0x20
mov dword [ebp + 8], eax
jmp 0x405fa7
lea eax, [ebp - 0x3c]
push eax
push dword [0x416478]
call dword [sym.imp.USER32.dll_IsDialogMessageW]
test eax, eax
jne 0x405fa7
lea eax, [ebp - 0x3c]
push eax
call dword [sym.imp.USER32.dll_TranslateMessage]
lea eax, [ebp - 0x3c]
push eax
call dword [sym.imp.USER32.dll_DispatchMessageW]
push esi
push esi
push esi
lea eax, [ebp - 0x3c]
push eax
call ebx
test eax, eax
jne 0x405f7f
push 0xffffffffffffffff
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_WaitForSingleObject]
lea eax, [ebp - 0x14]
push eax
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetExitCodeThread]
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [0x41eb6c]
cmp eax, esi
je 0x405fe5
push eax
call fcn.0040884d
pop ecx
cmp dword [0x41647c], esi
je 0x405ff5
mov dword [ebp - 0x1c], esi
jmp 0x40607a
cmp word [0x416278], si
je 0x406054
push dword [0x416380]
push edi
push 0x416278
call fcn.00405617
add esp, 0xc
cmp dword [0x4169a0], esi
je 0x406087
call fcn.00401fe0
jmp 0x406039
push 0x80
push ebx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push ebx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
call fcn.00401ff2
mov ebx, eax
cmp ebx, esi
jne 0x406021
cmp dword [ebp - 0x18], esi
je 0x40607a
push edi
call fcn.00402e19
pop ecx
push edi
call dword [sym.imp.KERNEL32.dll_RemoveDirectoryW]
jmp 0x40607a
cmp dword [0x41637c], esi
je 0x40607a
cmp dword [ebp - 0x14], esi
jne 0x40607a
push 0x40
call dword [sym.imp.USER32.dll_MessageBeep]
push 0xa
push esi
push esi
push edi
push str.open
push esi
call dword [sym.imp.SHELL32.dll_ShellExecuteW]
cmp dword [0x4169a0], esi
je 0x406087
call fcn.00401f45
mov eax, dword [ebp - 0x1c]
pop edi
pop esi
pop ebx
leave
ret