Function at 0x401000
Capabilities:
Check if file exists
Delete file

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff8
sub esp, 0x5c
push ebx
push esi
push edi
call fcn.00402eb0
test eax, eax
je 0x401274
push 2
call dword [sym.imp.KERNEL32.dll_SetErrorMode]
cmp dword [section..share], 0
jne 0x401274
mov ecx, dword [ebp + 0x10]
test ecx, ecx
je 0x401274
lea eax, [esp + 0x14]
push eax
call fcn.004024a0
mov eax, dword [esp + 0x14]
cmp dword [eax - 0xc], 0
jne 0x401062
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jmp 0x401268
push eax
call dword [sym.imp.SHLWAPI.dll_PathFindFileNameW]
mov edx, eax
mov edi, 0x427ef8
call fcn.00402460
inc dword [section..share]
lea esi, [esp + 0x24]
call fcn.00401280
lea ecx, [esp + 0x14]
push ecx
mov ecx, esi
call fcn.00401340
lea esi, [esp + 0x10]
call fcn.00401f90
mov edx, dword [0x4272cc]
mov eax, dword [edx + 0xc]
mov ecx, 0x4272cc
call eax
mov edi, eax
add edi, 0x10
xor ebx, ebx
mov dword [esp + 0x18], edi
cmp dword [esp + 0x40], ebx
jbe 0x4011b4
push ebx
lea eax, [esp + 0x28]
call fcn.004012c0
mov eax, dword [eax]
sub eax, 0x10
call fcn.00401660
mov ecx, dword [esp + 0x10]
mov esi, eax
add esi, 0x10
push ecx
mov ecx, esi
call fcn.00406320
mov eax, dword [esp + 0x14]
add esp, 4
lea edx, [esp + 0x44]
push edx
push 0
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesExW]
test eax, eax
je 0x401118
mov ecx, dword [esp + 0x64]
mov eax, dword [esp + 0x60]
mov edx, ecx
or edx, eax
je 0x401118
test eax, eax
jl 0x40113d
jg 0x401118
cmp ecx, 0x186a0
jbe 0x40113d
lea eax, [esi - 0x10]
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x401134
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
inc ebx
cmp ebx, dword [esp + 0x40]
jb 0x4010be
jmp 0x4011b4
lea ebx, [esi - 0x10]
lea eax, [edi - 0x10]
mov dword [esp + 0x20], ebx
mov dword [esp + 0x1c], eax
cmp ebx, eax
je 0x40119b
cmp dword [eax + 0xc], 0
lea edi, [eax + 0xc]
jl 0x401186
mov ecx, dword [ebx]
cmp ecx, dword [eax]
jne 0x401186
mov eax, ebx
call fcn.00401660
mov esi, eax
or edx, 0xffffffff
lock xadd dword [edi], edx
dec edx
test edx, edx
jg 0x401181
mov eax, dword [esp + 0x1c]
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea edi, [esi + 0x10]
jmp 0x40119b
mov ebx, dword [esi - 0xc]
push esi
lea eax, [esp + 0x1c]
call fcn.004023c0
mov edi, dword [esp + 0x18]
mov ebx, dword [esp + 0x20]
lea ecx, [ebx + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4011b4
mov ecx, dword [ebx]
mov eax, dword [ecx]
mov edx, dword [eax + 4]
push ebx
call edx
push edi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x4011f1
mov eax, dword [esp + 0x10]
lea esi, [esp + 0x1c]
lea ebx, [esp + 0x20]
call fcn.00401f10
mov esi, dword [esp + 0x20]
test esi, esi
je 0x4011ea
mov eax, dword [esp + 0x10]
call fcn.00403180
push esi
call fcn.0040cd0f
add esp, 4
push edi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
dec dword [section..share]
lea eax, [edi - 0x10]
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40121e
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
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 0x40123e
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
lea esi, [esp + 0x24]
call fcn.004015c0
mov ecx, dword [esp + 0x24]
push ecx
call fcn.0040ca8c
mov eax, dword [esp + 0x18]
add eax, 0xfffffff0
add esp, 4
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x401274
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
pop edi
pop esi
xor eax, eax
pop ebx
mov esp, ebp
pop ebp
ret 0x10