Function at 0x40dad0
Capabilities:
Check if file exists
Copy file
Get file attributes
Set file attributes

Disassembly:
push 0xffffffffffffffff
push 0x4610b8
mov eax, dword fs:[0]
push eax
sub esp, 0x84
mov eax, dword [0x478424]
xor eax, esp
mov dword [esp + 0x80], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x478424]
xor eax, esp
push eax
lea eax, [esp + 0x98]
mov dword fs:[0], eax
mov esi, ecx
mov eax, dword [esi + 0x174]
xor edi, edi
cmp eax, edi
mov dword [esp + 0x1c], esi
jne 0x40db23
mov dword [esp + 0x14], edi
jmp 0x40db32
mov ecx, dword [esi + 0x178]
sub ecx, eax
sar ecx, 2
mov dword [esp + 0x14], ecx
cmp dword [esp + 0x14], edi
mov dword [esp + 0x18], edi
ja 0x40db55
mov dword [esi + 0x90], 4
mov eax, dword [esi + 0x90]
jmp 0x40de26
mov edi, dword [esp + 0x18]
mov ecx, dword [esi + 0x174]
test ecx, ecx
je 0x40db6e
mov eax, dword [esi + 0x178]
sub eax, ecx
sar eax, 2
cmp edi, eax
jb 0x40db73
call fcn.00446328
mov eax, dword [esi + 0x174]
mov eax, dword [eax + edi*4]
mov ecx, dword [esi + 0x174]
add eax, 0x40
test ecx, ecx
mov dword [esp + 0x20], eax
je 0x40db9c
mov eax, dword [esi + 0x178]
sub eax, ecx
sar eax, 2
cmp edi, eax
jb 0x40dba1
call fcn.00446328
mov ecx, dword [esi + 0x174]
mov ebp, dword [ecx + edi*4]
add ebp, 8
push ebp
lea esi, [esp + 0x28]
call fcn.00401300
mov ebx, 0x10
mov dword [esp + 0xa0], 0
cmp dword [eax + 0x18], ebx
jb 0x40dbd1
mov edx, dword [eax + 4]
jmp 0x40dbd4
lea edx, [eax + 4]
mov edi, 0xf
mov eax, edx
mov dword [esp + 0x90], edi
mov dword [esp + 0x8c], 0
mov byte [esp + 0x7c], 0
lea esi, [eax + 1]
mov cl, byte [eax]
add eax, 1
test cl, cl
jne 0x40dbf5
sub eax, esi
push eax
push edx
lea ecx, [esp + 0x80]
call fcn.00401d40
mov byte [esp + 0xa0], 2
cmp dword [esp + 0x3c], ebx
jb 0x40dc29
mov edx, dword [esp + 0x28]
push edx
call fcn.0042a2ef
add esp, 4
cmp dword [esp + 0x90], ebx
mov dword [esp + 0x3c], edi
mov edi, dword [esp + 0x7c]
mov dword [esp + 0x38], 0
mov byte [esp + 0x28], 0
jae 0x40dc4b
lea edi, [esp + 0x7c]
lea esi, [esp + 0x5c]
call fcn.004109b0
push 0xffffffffffffffff
push 0
push eax
lea ecx, [esp + 0x84]
mov byte [esp + 0xac], 3
call fcn.00401bb0
mov byte [esp + 0xa0], 2
cmp dword [esp + 0x74], ebx
jb 0x40dc88
mov eax, dword [esp + 0x60]
push eax
call fcn.0042a2ef
add esp, 4
cmp dword [esp + 0x90], ebx
mov eax, dword [esp + 0x7c]
jae 0x40dc99
lea eax, [esp + 0x7c]
push 0
push eax
call fcn.00447517
add esp, 8
test eax, eax
je 0x40dcbf
cmp dword [esp + 0x90], ebx
mov eax, dword [esp + 0x7c]
jae 0x40dcb9
lea eax, [esp + 0x7c]
push eax
call fcn.0040dee0
push ebp
lea esi, [esp + 0x60]
call fcn.00401300
mov byte [esp + 0xa0], 4
cmp dword [eax + 0x18], ebx
jb 0x40dcdb
mov esi, dword [eax + 4]
jmp 0x40dcde
lea esi, [eax + 4]
push esi
call dword [sym.imp.KERNEL32.dll_GetFileAttributesA]
cmp eax, 0xffffffff
je 0x40dd14
test al, 1
je 0x40dd14
and eax, 0xfffffffe
push eax
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
test eax, eax
jne 0x40dd14
push esi
push str._COMEBACK_:set__s_not_readonly_failed_n
push 2
call fcn.00411a20
mov ecx, eax
call fcn.00411cc0
add esp, 0xc
mov eax, dword [esp + 0x20]
cmp dword [eax + 0x18], ebx
jb 0x40dd22
mov eax, dword [eax + 4]
jmp 0x40dd25
add eax, 4
push 0
push esi
push eax
call dword [sym.imp.KERNEL32.dll_CopyFileA]
cmp eax, 1
mov edi, 0x10
setne bl
mov byte [esp + 0xa0], 2
cmp dword [esp + 0x74], edi
jb 0x40dd55
mov ecx, dword [esp + 0x60]
push ecx
call fcn.0042a2ef
add esp, 4
test bl, bl
je 0x40ddbd
push ebp
lea esi, [esp + 0x44]
call fcn.00401300
mov byte [esp + 0xa0], 5
cmp dword [eax + 0x18], edi
jb 0x40dd75
mov eax, dword [eax + 4]
jmp 0x40dd78
add eax, 4
mov edx, dword [esp + 0x20]
push edx
mov ecx, eax
call fcn.004015b0
test al, al
sete bl
mov byte [esp + 0xa0], 2
cmp dword [esp + 0x58], edi
jb 0x40dda4
mov eax, dword [esp + 0x44]
push eax
call fcn.0042a2ef
add esp, 4
test bl, bl
mov dword [esp + 0x58], 0xf
mov dword [esp + 0x54], 0
mov byte [esp + 0x44], 0
jne 0x40ddfc
mov dword [esp + 0xa0], 0xffffffff
cmp dword [esp + 0x90], edi
jb 0x40ddde
mov ecx, dword [esp + 0x7c]
push ecx
call fcn.0042a2ef
add esp, 4
mov eax, dword [esp + 0x18]
mov esi, dword [esp + 0x1c]
add eax, 1
cmp eax, dword [esp + 0x14]
mov dword [esp + 0x18], eax
jb 0x40db51
jmp 0x40db3c
cmp dword [esp + 0x90], edi
jb 0x40de12
mov edx, dword [esp + 0x7c]
push edx
call fcn.0042a2ef
add esp, 4
mov eax, dword [esp + 0x1c]
mov dword [eax + 0x90], 5
mov eax, dword [eax + 0x90]
mov ecx, dword [esp + 0x98]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x80]
xor ecx, esp
call fcn.00445276
add esp, 0x90
ret