Function at 0x4914a0
Capabilities:
Check if file exists
Delete file
Move file
Set file attributes

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d0065
mov eax, dword fs:[0]
push eax
sub esp, 0x28
push esi
push edi
mov eax, dword [0x502054]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov byte [ebp - 0xd], 0
call fcn.00456f20
mov ecx, eax
test ecx, ecx
je 0x4917ca
mov eax, dword [ecx]
mov eax, dword [eax + 0xc]
call eax
add eax, 0x10
mov dword [ebp - 0x14], eax
mov dword [ebp - 4], 0
lea ecx, [ebp - 0x14]
mov esi, dword [ebp + 0x24]
push esi
call fcn.00460eb0
test al, al
jne 0x491529
test esi, esi
jne 0x491506
xor ecx, ecx
jmp 0x49151f
mov ecx, esi
lea edx, [ecx + 2]
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x491510
sub ecx, edx
sar ecx, 1
push ecx
push esi
lea ecx, [ebp - 0x14]
call fcn.00461210
mov dword [ebp - 4], 1
mov edi, dword [ebp + 0x14]
test edi, edi
je 0x491682
push ecx
mov esi, esp
mov dword [ebp - 0x1c], esp
cmp edi, 5
mov dword [ebp - 0x18], esi
mov eax, dword [ebp - 0x14]
seta byte [ebp + 0x28]
mov byte [ebp + 0x1b], 0
add eax, 0xfffffff0
push eax
call fcn.00461130
add eax, 0x10
add esp, 4
mov dword [esi], eax
mov byte [ebp - 4], 3
mov byte [ebp - 4], 1
mov dl, byte [ebp + 0x1b]
mov cl, byte [ebp + 0x28]
call fcn.00470d60
mov esi, esp
mov dword [ebp - 0x20], esp
mov dword [ebp - 0x24], esi
mov eax, dword [ebp - 0x14]
add eax, 0xfffffff0
mov byte [ebp + 0x1b], 1
push eax
call fcn.00461130
add eax, 0x10
add esp, 4
mov dword [esi], eax
mov byte [ebp - 4], 5
mov byte [ebp - 4], 1
mov dl, byte [ebp + 0x1b]
mov cl, byte [ebp + 0x28]
call fcn.00470d60
add esp, 4
cmp dword [ebp + 0x44], 1
sete al
mov byte [ebp + 0x48], al
call fcn.00456f20
mov ecx, eax
test ecx, ecx
je 0x4917d4
mov eax, dword [ecx]
mov eax, dword [eax + 0xc]
call eax
add eax, 0x10
mov dword [ebp + 0x18], eax
mov byte [ebp - 4], 6
lea eax, [ebp - 0x34]
xorps xmm0, xmm0
push eax
movups xmmword [ebp - 0x34], xmm0
call dword [sym.imp.OLEAUT32.dll_VariantClear]
mov byte [ebp - 4], 7
lea eax, [ebp + 0x2c]
push 8
push 0
push eax
lea eax, [ebp - 0x34]
push eax
call dword [sym.imp.OLEAUT32.dll_VariantTimeToDosDateTime]
test eax, eax
js 0x4917de
mov edx, dword [ebp - 0x2c]
test edx, edx
jne 0x491610
xor ecx, ecx
jmp 0x491624
mov ecx, edx
lea esi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x491615
sub ecx, esi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp + 0x18]
call fcn.00461210
mov byte [ebp - 4], 6
lea eax, [ebp - 0x34]
push eax
call dword [sym.imp.OLEAUT32.dll_VariantCopy]
mov byte [ebp - 4], 8
lea eax, [ebp + 0x18]
mov edx, dword [ebp - 0x14]
mov ecx, edi
push eax
push dword [ebp + 0x28]
push dword [ebp + 0x48]
call fcn.00472720
add esp, 0xc
test al, al
sete byte [ebp - 0xd]
mov byte [ebp - 4], 1
or edi, 0xffffffff
mov edx, dword [ebp + 0x18]
mov eax, edi
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x491792
mov ecx, dword [edx]
push edx
jmp 0x49178d
mov eax, dword [ebp - 0x14]
add eax, 0xfffffff0
push eax
call fcn.00461130
lea esi, [eax + 0x10]
mov dword [ebp + 0x28], esi
mov byte [ebp - 4], 0xb
push 0x5e
push esi
call fcn.004aba4e
add esp, 0xc
or edi, 0xffffffff
test eax, eax
je 0x491748
sub eax, esi
sar eax, 1
cmp eax, edi
je 0x491748
push eax
lea eax, [ebp - 0x1c]
push eax
lea ecx, [ebp + 0x28]
call fcn.0047ae10
mov byte [ebp - 4], 0xc
lea ecx, [esi - 0x10]
mov edx, dword [eax]
mov dword [ebp - 0x18], ecx
lea eax, [edx - 0x10]
mov dword [ebp + 0x48], eax
cmp eax, ecx
je 0x49172a
cmp dword [ecx + 0xc], 0
lea esi, [ecx + 0xc]
jl 0x49171b
mov eax, dword [eax]
cmp eax, dword [ecx]
jne 0x49171b
push dword [ebp + 0x48]
call fcn.00461130
add esp, 4
mov dword [ebp + 0x48], eax
mov ecx, edi
lock xadd dword [esi], ecx
dec ecx
test ecx, ecx
jg 0x491713
mov esi, dword [ebp - 0x18]
push esi
mov ecx, dword [esi]
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [ebp + 0x48]
lea esi, [eax + 0x10]
mov dword [ebp + 0x28], esi
jmp 0x49172a
push dword [edx - 0xc]
lea ecx, [ebp + 0x28]
push edx
call fcn.00461210
mov esi, dword [ebp + 0x28]
mov byte [ebp - 4], 0xb
mov eax, edi
mov edx, dword [ebp - 0x1c]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x491748
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
push 0x80
push esi
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
cmp dword [ebp + 0x14], 0
jne 0x491777
push esi
call dword [sym.imp.SHLWAPI.dll_PathFileExistsW]
test eax, eax
je 0x491777
push 4
push 0
push esi
call dword [sym.imp.KERNEL32.dll_MoveFileExW]
mov byte [ebp - 4], 1
add esi, 0xfffffff0
mov eax, edi
lock xadd dword [esi + 0xc], eax
dec eax
test eax, eax
jg 0x491792
mov ecx, dword [esi]
push esi
mov eax, dword [ecx]
call dword [eax + 4]
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x14]
movzx esi, byte [ebp - 0xd]
add eax, 0xfffffff0
lock xadd dword [eax + 0xc], edi
dec edi
test edi, edi
jg 0x4917b5
mov ecx, dword [eax]
push eax
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 0x44
push 0x80004005
call fcn.00456c70
push 0x80004005
call fcn.00456c70
push eax
call fcn.00456c70
int3