Function at 0x496600
Capabilities:
Delete file

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4d43f0
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push esi
push edi
mov eax, dword [0x513b94]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
mov dword [ebp - 0x18], ebx
mov esi, dword [ebx + 0x4a8]
lea edi, [ebx + 0x3b0]
mov dword [ebp - 0x14], edi
test esi, esi
je 0x496937
lea ebx, [esi + 8]
lock inc dword [ebx]
mov edi, dword [esi]
push edi
call fcn.0049c580
push eax
push edi
call fcn.0049c710
mov dword [ebp - 0x10], eax
add esp, 0xc
or eax, 0xffffffff
lock xadd dword [ebx], eax
dec eax
jne 0x49669e
mov eax, dword [esi]
test eax, eax
je 0x49667c
push eax
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov dword [esi], 0
mov eax, dword [esi + 4]
test eax, eax
je 0x496693
push eax
call fcn.004a0e5f
add esp, 4
mov dword [esi + 4], 0
push 0xc
push esi
call fcn.004a0e51
add esp, 8
mov edi, dword [ebp - 0x14]
mov ebx, dword [ebp - 0x18]
mov eax, dword [ebx + 0x550]
test eax, eax
je 0x4966c9
push eax
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov dword [ebx + 0x550], 0
mov dword [ebx + 0x554], 0
mov ecx, edi
call fcn.0045f480
mov eax, dword [ebx + 0x568]
cmp eax, dword [ebx + 0x56c]
je 0x4966e4
mov dword [ebx + 0x56c], eax
cmp byte [ebx + 0x57c], 0
je 0x496708
lea ecx, [ebp - 0x10]
call fcn.0049c770
test eax, eax
je 0x496708
lea ecx, [ebp - 0x10]
call fcn.0049c120
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov ecx, dword [ebx + 0x580]
mov eax, dword [ecx + 4]
mov dword [eax], 0
mov eax, dword [ecx]
test eax, eax
je 0x496733
nop dword [eax]
mov esi, dword [eax]
push 0x20
push eax
call fcn.004a0e51
add esp, 8
mov eax, esi
test esi, esi
jne 0x496720
mov eax, dword [ebx + 0x580]
mov dword [eax], eax
mov eax, dword [ebx + 0x580]
mov dword [eax + 4], eax
mov dword [ebx + 0x584], 0
mov ecx, dword [ebp - 0x10]
mov dword [ebp - 4], 0
test ecx, ecx
je 0x496761
call fcn.0049c750
mov ecx, dword [ebx + 0x580]
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ecx + 4]
mov dword [eax], 0
mov eax, dword [ecx]
test eax, eax
je 0x496793
nop dword [eax]
mov esi, dword [eax]
push 0x20
push eax
call fcn.004a0e51
add esp, 8
mov eax, esi
test esi, esi
jne 0x496780
push 0x20
push dword [ebx + 0x580]
call fcn.004a0e51
mov esi, dword [ebx + 0x568]
add esp, 8
test esi, esi
je 0x49680e
mov ecx, dword [ebx + 0x570]
mov eax, 0x66666667
sub ecx, esi
imul ecx
sar edx, 1
mov eax, edx
shr eax, 0x1f
add eax, edx
lea ecx, [eax + eax*4]
cmp ecx, 0x1000
jb 0x4967e6
mov edx, dword [esi - 4]
add ecx, 0x23
sub esi, edx
lea eax, [esi - 4]
cmp eax, 0x1f
ja 0x496951
mov esi, edx
push ecx
push esi
call fcn.004a0e51
mov dword [ebx + 0x568], 0
add esp, 8
mov dword [ebx + 0x56c], 0
mov dword [ebx + 0x570], 0
lea edi, [ebx + 0x51c]
mov ecx, edi
mov dword [ebp - 4], 1
call fcn.0044fc10
mov eax, dword [edi + 0x24]
lea esi, [edi + 0x24]
mov ecx, esi
push dword [eax + 4]
push esi
call fcn.00429020
push 0x1c
push dword [esi]
call fcn.004a0e51
mov ecx, dword [edi + 0x18]
add esp, 8
test ecx, ecx
je 0x496892
mov eax, dword [edi + 0x20]
sub eax, ecx
sar eax, 3
lea edx, [eax*8]
cmp edx, 0x1000
jb 0x496873
mov esi, dword [ecx - 4]
add edx, 0x23
sub ecx, esi
lea eax, [ecx - 4]
cmp eax, 0x1f
ja 0x496951
mov ecx, esi
push edx
push ecx
call fcn.004a0e51
mov dword [edi + 0x18], 0
add esp, 8
mov dword [edi + 0x1c], 0
mov dword [edi + 0x20], 0
push edi
mov edi, dword [sym.imp.KERNEL32.dll_DeleteCriticalSection]
call edi
lea esi, [ebx + 0x4ec]
lea ecx, [esi + 0x18]
call fcn.00429a10
push esi
call edi
lea ecx, [ebx + 0x4b8]
call fcn.00420e20
mov ebx, dword [ebp - 0x14]
mov ecx, ebx
mov dword [ebp - 4], 2
call fcn.0045f480
mov esi, dword [ebx + 0xf8]
test esi, esi
je 0x49691c
or eax, 0xffffffff
lock xadd dword [esi + 8], eax
dec eax
jne 0x496912
mov eax, dword [esi]
test eax, eax
je 0x4968f0
push eax
call dword [sym.imp.OLEAUT32.dll_SysStringLen]
mov dword [esi], 0
mov eax, dword [esi + 4]
test eax, eax
je 0x496907
push eax
call fcn.004a0e5f
add esp, 4
mov dword [esi + 4], 0
push 0xc
push esi
call fcn.004a0e51
add esp, 8
mov dword [ebx + 0xf8], 0
lea eax, [ebx + 0xe0]
push eax
call edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push 0
call fcn.0049c580
push eax
push 0
call fcn.0049c710
add esp, 0xc
mov dword [ebp - 0x10], eax
jmp 0x4966a4
call fcn.004a851f
int3