Function at 0x4aa840
Capabilities:
Delete file

Disassembly:
sub esp, 0x10
push ebx
push ebp
push esi
push edi
mov esi, ecx
lea edi, [esi + 0xa8]
push edi
mov dword [esp + 0x1c], edi
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [esi], 4
je 0x4aa88b
call fcn.00419310
cmp byte [esp + 0x24], 0
mov ebp, dword [eax + 0xac]
je 0x4aa915
mov eax, dword [esi + 0x54]
cmp dword [esi + 0x50], eax
jae 0x4aa880
mov dword [esi + 0x50], eax
mov eax, dword [esi + 0x44]
cmp dword [esi + 0x50], eax
jb 0x4aa89e
mov dword [esi + 0x50], eax
push edi
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10
ret 4
mov ebx, dword [esi + 0x50]
call fcn.00419310
mov ecx, eax
xor edx, edx
mov eax, ebx
div dword [ecx + 0xac]
movzx edi, al
call fcn.00419310
mov edx, dword [eax + 0xac]
mov ecx, dword [esi + 0x50]
imul edx, edi
mov eax, ebx
sub eax, edx
mov dword [esp + 0x10], eax
mov eax, dword [esi + 0x48]
cmp ecx, eax
jb 0x4aa8dc
xor ebp, ebp
jmp 0x4aa994
add ecx, ebp
cmp ecx, eax
jbe 0x4aa8f0
cmp eax, dword [esi + 0x44]
jne 0x4aa95c
sub eax, ebx
mov ebp, eax
jmp 0x4aa994
call fcn.00419310
mov eax, dword [eax + 0xac]
imul eax, edi
mov dword [esp + 0x14], eax
call fcn.00419310
mov ebp, dword [eax + 0xac]
sub ebp, ebx
add ebp, dword [esp + 0x14]
jmp 0x4aa994
cmp dword [esi], 3
jl 0x4aa925
mov eax, dword [esi + 0x50]
cmp dword [esi + 0x54], eax
jae 0x4aa925
mov dword [esi + 0x54], eax
mov ebx, dword [esi + 0x54]
call fcn.00419310
mov ecx, eax
xor edx, edx
mov eax, ebx
div dword [ecx + 0xac]
movzx edi, al
call fcn.00419310
mov edx, dword [eax + 0xac]
mov ecx, dword [esi + 0x54]
imul edx, edi
mov eax, ebx
sub eax, edx
mov dword [esp + 0x10], eax
mov eax, dword [esi + 0x48]
cmp ecx, eax
jb 0x4aa960
xor ebp, ebp
jmp 0x4aa994
add ecx, ebp
cmp ecx, eax
jbe 0x4aa971
cmp eax, dword [esi + 0x44]
jne 0x4aa95c
sub eax, ebx
mov ebp, eax
jmp 0x4aa994
call fcn.00419310
mov eax, dword [eax + 0xac]
imul eax, edi
mov dword [esp + 0x14], eax
call fcn.00419310
mov ebp, dword [eax + 0xac]
sub ebp, ebx
add ebp, dword [esp + 0x14]
call fcn.00419310
mov eax, dword [eax + 0xac]
mov dword [esp + 0x14], eax
call fcn.00419310
lea ecx, [edi + 1]
imul ecx, dword [eax + 0xac]
cmp ecx, dword [esi + 0x44]
jbe 0x4aa9cc
call fcn.00419310
mov edx, dword [eax + 0xac]
mov eax, dword [esi + 0x44]
imul edx, edi
sub eax, edx
jmp 0x4aa9d0
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x10]
add ecx, ebp
cmp ecx, eax
jae 0x4aa9dc
xor ebp, ebp
mov eax, dword [esp + 0x18]
mov edx, dword [esi + edi*4 + 0x80]
push eax
mov dword [esp + 0x20], edx
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
xor edx, edx
cmp ebp, edx
mov dword [esp + 0x14], edx
jbe 0x4aaac8
mov eax, dword [esp + 0x1c]
sub eax, edx
je 0x4aaac8
sub eax, 3
je 0x4aaa1f
sub eax, 1
jne 0x4aaa73
mov dword [esp + 0x14], ebp
jmp 0x4aaac8
cmp dword [esi + edi*4 + 0x58], edx
jne 0x4aaa33
push 1
call fcn.004abec0
add esp, 4
mov dword [esi + edi*4 + 0x58], eax
mov ecx, dword [esi + edi*4 + 0x58]
add ecx, dword [esp + 0x10]
push ecx
push ebp
call fcn.00419310
mov edx, dword [eax + 0xac]
imul edx, edi
add edx, dword [esp + 0x18]
push 0
push edx
sub esp, 0x1c
lea eax, [esi + 0x20]
mov ecx, esp
mov dword [esp + 0x48], esp
push eax
call fcn.00406510
mov ecx, esi
call fcn.004a9c90
test eax, eax
jle 0x4aaac8
mov ebp, eax
xor edx, edx
cmp ebp, edx
jbe 0x4aaac8
mov ecx, dword [esi + edi*4 + 0x58]
add ecx, dword [esp + 0x10]
push 0x80
push ecx
mov ecx, dword [esi + 0x40]
xor eax, eax
add ebx, dword [esi + 0x3c]
push ebp
adc ecx, eax
push ecx
push ebx
sub esp, 0x1c
mov ecx, esp
mov dword [esp + 0x4c], esp
push 0xffffffffffffffff
lea eax, [esi + 4]
push edx
mov dword [ecx + 0x18], 7
mov dword [ecx + 0x14], edx
push eax
mov word [ecx + 4], dx
call fcn.00401640
mov ecx, esi
call fcn.004a98e0
test eax, eax
jl 0x4aabc9
mov dword [esp + 0x14], eax
mov ebp, dword [esp + 0x18]
push ebp
call dword [sym.imp.KERNEL32.dll_EnterCriticalSection]
cmp dword [esi + edi*4 + 0x80], 3
jne 0x4aaaf6
mov eax, dword [esi + edi*4 + 0x58]
test eax, eax
je 0x4aaaf6
push eax
call fcn.004abf30
add esp, 4
mov dword [esi + edi*4 + 0x58], 0
cmp byte [esp + 0x24], 0
je 0x4aab2a
mov edx, dword [esp + 0x14]
add dword [esi + 0x50], edx
mov ecx, dword [esi + 0x50]
mov eax, dword [esi + 0x44]
cmp ecx, eax
jbe 0x4aabbe
push ebp
mov dword [esi + 0x50], eax
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, dword [esp + 0x14]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10
ret 4
mov eax, dword [esp + 0x14]
add dword [esi + 0x54], eax
mov ecx, dword [esi + 0x54]
mov eax, dword [esi + 0x44]
cmp ecx, eax
jbe 0x4aab3e
mov dword [esi + 0x54], eax
xor ebx, ebx
call fcn.00419310
mov ecx, eax
mov eax, dword [esi + 0x54]
xor edx, edx
div dword [ecx + 0xac]
test eax, eax
jle 0x4aab98
lea edi, [esi + 0x58]
lea esp, [esp]
mov eax, dword [edi]
test eax, eax
mov dword [edi + 0x28], 4
je 0x4aab7c
push eax
call fcn.004abf30
add esp, 4
mov dword [edi], 0
add ebx, 1
add edi, 4
call fcn.00419310
mov ecx, eax
mov eax, dword [esi + 0x54]
xor edx, edx
div dword [ecx + 0xac]
cmp ebx, eax
jl 0x4aab60
mov eax, dword [esi + 0x44]
cmp dword [esi + 0x54], eax
jb 0x4aabbe
mov dword [esi + 0x54], eax
mov dword [esi], 4
cmp dword [esi + 0x38], 8
jb 0x4aabb4
mov esi, dword [esi + 0x24]
jmp 0x4aabb7
add esi, 0x24
push esi
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
push ebp
call dword [sym.imp.KERNEL32.dll_LeaveCriticalSection]
mov eax, dword [esp + 0x14]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x10
ret 4