Function at 0x40df40
Capabilities:
Check if file exists
Delete file
Get file attributes
Move file

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
push 0xffffffffffffffff
push 0x49a210
mov eax, dword fs:[0]
push eax
sub esp, 0x20
push ebx
push esi
push edi
mov eax, dword [0x4cf500]
xor eax, esp
push eax
lea eax, [esp + 0x30]
mov dword fs:[0], eax
mov edi, dword [ebp + 8]
mov eax, dword [edi]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x40df81
test al, 0x10
je 0x40df99
mov eax, 1
mov ecx, dword [esp + 0x30]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, dword [edi]
mov ebx, 1
push eax
mov dword [esp + 0x1c], ebx
call dword [sym.imp.SHLWAPI.dll_PathFindFileNameW]
push eax
lea ecx, [esp + 0x20]
call fcn.00401c90
mov dword [esp + 0x38], 0
mov eax, dword [section..data]
mov edx, dword [eax + 0xc]
mov ecx, section..data
call edx
add eax, 0x10
mov dword [esp + 0x14], eax
push 0
mov byte [esp + 0x3c], bl
call fcn.00474040
mov ecx, dword [esp + 0x20]
push ecx
push edx
push eax
lea edx, [esp + 0x24]
push 0x4ab1b8
push edx
call fcn.0040bea0
lea esi, [esp + 0x38]
call fcn.0040cc70
lea ecx, [esp + 0x2c]
push ecx
lea edx, [esp + 0x2c]
push edx
mov ebx, eax
mov byte [esp + 0x58], 2
call fcn.0040b4f0
add esp, 0x20
mov byte [esp + 0x38], 4
mov eax, dword [esp + 0x20]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40e03b
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [esp + 0x10]
mov edi, dword [edi]
mov esi, dword [sym.imp.KERNEL32.dll_MoveFileExW]
push 1
push ecx
push edi
call esi
test eax, eax
jne 0x40e145
mov edx, dword [ebp + 0xc]
push edx
lea eax, [esp + 0x2c]
push eax
mov ebx, 0x4aaf74
call fcn.004066b0
lea ecx, [esp + 0x1c]
push ecx
lea edx, [esp + 0x30]
push edx
mov ebx, eax
mov byte [esp + 0x48], 5
call fcn.0040b4f0
add esp, 0x10
lea edi, [esp + 0x10]
mov byte [esp + 0x38], 6
call fcn.00404dc0
mov byte [esp + 0x38], 5
mov eax, dword [esp + 0x24]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40e0b4
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x38], 4
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40e0d9
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [ebp + 8]
mov edx, dword [esp + 0x10]
mov eax, dword [ecx]
push 1
push edx
push eax
call esi
test eax, eax
jne 0x40e0f0
mov dword [esp + 0x18], eax
mov eax, dword [esp + 0x10]
cmp dword [eax - 4], 1
jle 0x40e10b
mov eax, dword [eax - 0xc]
push eax
lea ecx, [esp + 0x14]
call fcn.004019d0
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, dword [esp + 0x10]
mov ecx, dword [eax - 8]
push ecx
push eax
call fcn.00475025
add esp, 8
test eax, eax
js 0x40e1e1
mov ecx, dword [esp + 0x10]
cmp eax, dword [ecx - 8]
jg 0x40e1e1
mov dword [ecx - 0xc], eax
mov edx, dword [esp + 0x10]
xor ecx, ecx
mov word [edx + eax*2], cx
mov eax, dword [esp + 0x10]
push 4
xor ebx, ebx
push ebx
push eax
call esi
test eax, eax
jne 0x40e159
mov dword [esp + 0x18], ebx
mov byte [esp + 0x38], 1
mov eax, dword [esp + 0x10]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40e17e
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [esp + 0x38], 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 0x40e1a2
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [esp + 0x38], 0xffffffff
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 0x40e1ca
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, dword [esp + 0x18]
mov ecx, dword [esp + 0x30]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0x80070057
call fcn.00401b40
int3