Function at 0x491fc0
Capabilities:
Delete file
Read file via mapping

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x4ea0e0
mov eax, dword fs:[0]
push eax
sub esp, 0x30
push ebx
push esi
mov eax, dword [0x53d100]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov ebx, ecx
xor eax, eax
cmp ebx, 3
sete al
mov dword [ebp - 4], 1
push ecx
mov dword [ebp - 0x30], esp
mov esi, esp
mov dword [ebp - 0x10], eax
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
push eax
call fcn.0042541f
add esp, 4
push ebx
add eax, 0x10
push edi
mov dword [esi], eax
call fcn.00490640
mov ebx, eax
xor eax, eax
or esi, 0xffffffff
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x14], esi
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], eax
cmp ebx, eax
jne 0x49208b
mov byte [ebp - 4], al
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
mov edx, esi
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x492054
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [ebp - 4], esi
mov eax, dword [ebp + 0xc]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
lock xadd dword [ecx], esi
dec esi
test esi, esi
jg 0x492073
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 5
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
cmp dword [ebp - 0x10], eax
je 0x49213a
mov eax, dword [edi + 0x68]
add eax, dword [ebx]
mov ecx, dword [edi + 0x6c]
adc ecx, dword [ebx + 4]
mov dword [edi + 0x18], eax
mov dword [edi + 0x1c], ecx
mov esi, dword [ebx + 0x10]
mov ecx, dword [ebx + 0x14]
push esi
mov dword [ebp - 0x34], ecx
call fcn.004cb944
add esp, 4
mov dword [ebp - 0x24], eax
test eax, eax
jne 0x49211e
mov byte [ebp - 4], al
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x4920e0
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp + 0xc]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x492106
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 9
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
push eax
push edi
mov eax, esi
call fcn.00490370
test eax, eax
jne 0x49212e
mov dword [ebp - 0x10], eax
mov ecx, dword [ebp - 0x24]
push ecx
call fcn.004cb867
add esp, 4
mov eax, dword [ebp + 0xc]
lea edx, [ebp - 0x14]
push edx
push ecx
add eax, 0xfffffff0
mov dword [ebp - 0x24], esp
mov esi, esp
push eax
call fcn.0042541f
add eax, 0x10
add esp, 4
mov dword [esi], eax
call fcn.00478c60
add esp, 8
test eax, eax
jne 0x4921c4
mov byte [ebp - 4], al
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x492186
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp + 0xc]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x4921ac
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 7
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8
cmp dword [ebp - 0x10], 0
mov eax, dword [ebx + 0x10]
mov esi, dword [ebx + 0x14]
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x24], esi
je 0x4921e2
add eax, 0xfffffffc
adc esi, 0xffffffff
mov dword [ebp - 0x28], eax
mov dword [ebp - 0x24], esi
mov edx, dword [ebp - 0x14]
push 0
lea ecx, [ebp - 0x2c]
push ecx
push eax
push edx
mov dword [ebp - 0x2c], esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x492207
mov dword [ebp - 0x18], 0xc
jmp 0x492305
mov eax, dword [ebp - 0x14]
push eax
call dword [sym.imp.KERNEL32.dll_SetEndOfFile]
mov ecx, dword [ebp - 0x28]
mov edx, dword [ebp - 0x14]
push 0
push ecx
push esi
push 4
push 0
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
xor edx, edx
mov dword [ebp - 0x1c], eax
cmp eax, edx
je 0x4922fe
mov eax, dword [edi + 0x68]
add eax, dword [ebx]
mov ecx, dword [edi + 0x6c]
adc ecx, dword [ebx + 4]
mov dword [ebp - 0x38], edx
mov dword [ebp - 0x34], edx
mov dword [edi + 0x18], eax
mov dword [edi + 0x1c], ecx
cmp esi, edx
jb 0x492305
ja 0x492263
cmp dword [ebp - 0x28], edx
jbe 0x492305
jmp 0x492263
mov esi, dword [ebp - 0x24]
mov ebx, dword [edi + 0x64]
mov edx, dword [ebp - 0x34]
xor eax, eax
mov ecx, ebx
add ecx, dword [ebp - 0x38]
adc eax, edx
cmp eax, esi
ja 0x49227d
jb 0x492283
cmp ecx, dword [ebp - 0x28]
jb 0x492283
mov ebx, dword [ebp - 0x28]
sub ebx, dword [ebp - 0x38]
cmp dword [ebp - 0x10], 0
je 0x49228c
mov ebx, dword [ebp - 0x28]
mov eax, dword [ebp - 0x38]
mov ecx, dword [ebp - 0x1c]
push ebx
push eax
push edx
push 6
push ecx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov esi, eax
test esi, esi
je 0x4921fb
cmp dword [ebp - 0x10], 0
je 0x4922bd
mov edx, dword [ebp - 0x30]
mov eax, dword [edx + 0x10]
push esi
push edi
call fcn.00490370
jmp 0x4922c8
push 0
push ebx
push esi
mov eax, edi
call fcn.004900c0
push esi
test eax, eax
je 0x4922f8
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
add dword [ebp - 0x38], ebx
mov eax, dword [ebp - 0x34]
adc eax, 0
mov dword [ebp - 0x34], eax
cmp eax, dword [ebp - 0x24]
jb 0x492260
ja 0x492305
mov eax, dword [ebp - 0x28]
cmp dword [ebp - 0x38], eax
jb 0x492260
jmp 0x492305
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov dword [ebp - 0x18], 8
mov eax, dword [ebp - 0x14]
mov esi, dword [sym.imp.KERNEL32.dll_CloseHandle]
cmp eax, 0xffffffff
je 0x492316
push eax
call esi
mov eax, dword [ebp - 0x1c]
test eax, eax
je 0x492320
push eax
call esi
mov esi, dword [ebp - 0x18]
test esi, esi
je 0x492331
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov byte [ebp - 4], 0
mov eax, dword [ebp + 8]
add eax, 0xfffffff0
lea edx, [eax + 0xc]
or ecx, 0xffffffff
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x492354
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp + 0xc]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x49237a
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop esi
pop ebx
mov esp, ebp
pop ebp
ret 8