Function at 0x49d0c0
Capabilities:
Get file size
Read file on windows

Disassembly:
mov eax, 0x30044
call fcn.004a5b80
push ebx
mov eax, dword [esp + 0x30050]
push ebp
push esi
push edi
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
push eax
mov dword [esp + 0x3c], 0
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
mov dword [esp + 0x10], esi
jne 0x49d111
pop edi
pop esi
pop ebp
mov eax, 0xee
pop ebx
add esp, 0x30044
ret
lea ecx, [esp + 0x4c]
push ecx
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
jne 0x49d138
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0xee
pop ebx
add esp, 0x30044
ret
mov edi, dword [esp + 0x50]
mov ebx, dword [esp + 0x4c]
push 0
push 0x200
push edi
push ebx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], edi
mov dword [esp + 0x34], ebx
mov dword [esp + 0x38], edi
call fcn.004a5e00
push 0
push 0x80
push edx
push eax
call fcn.004a5e00
mov ebp, edx
push 0
push 0x10000
push ebp
push eax
mov dword [esp + 0x4c], eax
mov dword [esp + 0x50], ebp
call fcn.004a5da0
mov esi, ebx
push 0
sub esi, eax
mov eax, edi
sbb eax, edx
mov edx, dword [esp + 0x40]
push 0x80
push ebp
push edx
mov dword [esp + 0x54], esi
mov dword [esp + 0x58], eax
call fcn.004a5da0
mov ecx, dword [esp + 0x48]
add eax, esi
adc edx, ecx
push 0
push 0x200
push edx
push eax
call fcn.004a5da0
cmp edi, edx
jl 0x49d1d8
jg 0x49d1c6
cmp ebx, eax
jbe 0x49d1d8
mov eax, dword [esp + 0x48]
add esi, 1
adc eax, 0
mov dword [esp + 0x44], esi
mov dword [esp + 0x48], eax
mov edi, dword [esp + 0x10]
lea eax, [esp + 0x1c]
push 0
push eax
lea ecx, [esp + 0x34]
push 0x10
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x2c]
cmp al, 0x41
jne 0x49d217
cmp ah, 0x4c
jne 0x49d217
cmp byte [esp + 0x2e], 0x43
jne 0x49d217
cmp byte [esp + 0x2f], 0x4f
jne 0x49d217
cmp byte [esp + 0x30], 0x52
je 0x49d73f
push 0
push 0
push 0
push edi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
test ebp, ebp
jl 0x49d397
jg 0x49d23a
mov eax, dword [esp + 0x3c]
test eax, eax
jbe 0x49d397
push 0x10000
call dword [sym.imp.MSVCRT.dll_malloc]
mov ebx, eax
xor eax, eax
add esp, 4
cmp ebp, eax
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], eax
jl 0x49d2de
jg 0x49d266
mov eax, dword [esp + 0x3c]
test eax, eax
jbe 0x49d2de
xor eax, eax
mov ecx, 0x4000
mov edi, ebx
lea edx, [esp + 0x1c]
push eax
push edx
rep stosd dword es:[edi], eax
mov eax, dword [esp + 0x18]
push 0x10000
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov ecx, dword [esp + 0x20]
mov edx, dword [esp + 0x30058]
push ebx
push ecx
push 0x80
push edx
call fcn.0048f970
add esp, 0x10
test eax, eax
je 0x49d373
mov eax, dword [esp + 0x20]
mov edi, dword [esp + 0x24]
add eax, 0x80
add edi, 1
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x28]
adc eax, 0
mov dword [esp + 0x24], edi
cmp eax, ebp
mov dword [esp + 0x28], eax
jl 0x49d266
jg 0x49d2de
mov ecx, dword [esp + 0x3c]
mov eax, edi
cmp eax, ecx
jb 0x49d266
mov ecx, 0x4000
xor eax, eax
mov edi, ebx
rep stosd dword es:[edi], eax
mov eax, dword [esp + 0x48]
test eax, eax
jl 0x49d41a
jg 0x49d2ff
test esi, esi
jbe 0x49d41a
mov ecx, esi
xor eax, eax
shl ecx, 9
mov dword [esp + 0x14], ecx
mov edx, ecx
mov edi, ebx
push 0
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
lea eax, [esp + 0x20]
mov ecx, edx
mov edx, dword [esp + 0x14]
push eax
push ecx
push ebx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x30058]
push ebx
push eax
push esi
push ecx
call fcn.0048f970
add esp, 0x10
test eax, eax
jne 0x49d41a
push ebx
call sub.MFC42.DLL_operatordelete
add esp, 4
mov edx, dword [esp + 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0xee
pop ebx
add esp, 0x30044
ret
push ebx
call sub.MFC42.DLL_operatordelete
mov ecx, dword [esp + 0x14]
add esp, 4
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0xee
pop ebx
add esp, 0x30044
ret
mov ebx, esi
shl ebx, 9
push ebx
call dword [sym.imp.MSVCRT.dll_malloc]
mov ecx, ebx
mov edi, eax
mov edx, ecx
xor eax, eax
shr ecx, 2
mov dword [esp + 0x18], edi
add esp, 4
rep stosd dword es:[edi], eax
mov ecx, edx
mov edx, dword [esp + 0x10]
and ecx, 3
push 0
rep stosb byte es:[edi], al
mov ecx, dword [esp + 0x18]
lea eax, [esp + 0x20]
push eax
push ebx
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x14]
mov ecx, dword [esp + 0x30058]
push eax
push 0
push esi
push ecx
call fcn.0048f970
add esp, 0x10
test eax, eax
jne 0x49d41a
mov edx, dword [esp + 0x14]
push edx
call sub.MFC42.DLL_operatordelete
add esp, 4
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0xee
pop ebx
add esp, 0x30044
ret
mov ecx, dword [esp + 0x10]
push 0
push 0
push 0
push ecx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
test ebp, ebp
mov dword [esp + 0x20], 0
jl 0x49d640
jg 0x49d449
mov eax, dword [esp + 0x3c]
test eax, eax
jbe 0x49d640
mov edi, dword [sym.imp.MSVCRT.dll_malloc]
push 0x10000
call edi
push 0x10000
mov ebx, eax
call edi
mov ecx, dword [esp + 0x48]
mov ebp, eax
xor eax, eax
add esp, 8
cmp ecx, eax
mov dword [esp + 0x24], eax
mov dword [esp + 0x28], eax
jl 0x49d52c
jg 0x49d488
mov eax, dword [esp + 0x3c]
test eax, eax
jbe 0x49d52c
mov esi, dword [esp + 0x10]
mov ecx, 0x4000
xor eax, eax
mov edi, ebx
lea edx, [esp + 0x1c]
push eax
rep stosd dword es:[edi], eax
push edx
mov ecx, 0x4000
mov edi, ebp
push 0x10000
push ebx
push esi
rep stosd dword es:[edi], eax
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x30058]
push ebp
push eax
push 0x80
push ecx
call fcn.0048f830
add esp, 0x10
test eax, eax
je 0x49d5de
mov ecx, 0x4000
mov edi, ebp
mov esi, ebx
xor edx, edx
repe cmpsd dword [esi], dword es:[edi]
jne 0x49d616
mov edi, dword [esp + 0x20]
mov esi, dword [esp + 0x24]
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x40]
add edi, 0x80
add esi, 1
adc eax, edx
mov dword [esp + 0x20], edi
cmp eax, ecx
mov dword [esp + 0x24], esi
mov dword [esp + 0x28], eax
jl 0x49d488
jg 0x49d528
mov eax, dword [esp + 0x3c]
mov ecx, esi
cmp ecx, eax
jb 0x49d488
mov esi, dword [esp + 0x44]
mov ecx, 0x4000
xor eax, eax
mov edi, ebx
rep stosd dword es:[edi], eax
mov ecx, 0x4000
mov edi, ebp
rep stosd dword es:[edi], eax
mov eax, dword [esp + 0x48]
test eax, eax
jl 0x49d718
jg 0x49d556
test esi, esi
jbe 0x49d718
mov ecx, esi
xor eax, eax
shl ecx, 9
mov dword [esp + 0x14], ecx
mov edx, ecx
mov edi, ebx
push 0
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov ecx, edx
xor eax, eax
mov edi, ebp
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
lea eax, [esp + 0x20]
mov ecx, edx
mov edx, dword [esp + 0x14]
push eax
push ecx
push ebx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x20]
mov ecx, dword [esp + 0x30058]
push ebp
push eax
push esi
push ecx
call fcn.0048f830
add esp, 0x10
test eax, eax
jne 0x49d604
push ebx
call sub.MFC42.DLL_operatordelete
push ebp
call sub.MFC42.DLL_operatordelete
add esp, 8
mov edx, dword [esp + 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0xee1
pop ebx
add esp, 0x30044
ret
push ebx
call sub.MFC42.DLL_operatordelete
push ebp
call sub.MFC42.DLL_operatordelete
add esp, 8
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0xee1
pop ebx
add esp, 0x30044
ret
mov ecx, dword [esp + 0x14]
mov edi, ebp
mov esi, ebx
xor eax, eax
repe cmpsb byte [esi], byte es:[edi]
je 0x49d718
push ebx
call sub.MFC42.DLL_operatordelete
push ebp
call sub.MFC42.DLL_operatordelete
mov ecx, dword [esp + 0x18]
add esp, 8
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0xee2
pop ebx
add esp, 0x30044
ret
mov ebp, esi
shl ebp, 9
push ebp
mov dword [esp + 0x18], ebp
call dword [sym.imp.MSVCRT.dll_malloc]
mov ecx, ebp
mov ebx, eax
mov edx, ecx
xor eax, eax
mov edi, ebx
push ebp
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
call dword [sym.imp.MSVCRT.dll_malloc]
mov ecx, dword [esp + 0x1c]
mov ebp, eax
mov edx, ecx
xor eax, eax
mov edi, ebp
add esp, 8
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
push 0
and ecx, 3
rep stosb byte es:[edi], al
lea eax, [esp + 0x20]
mov ecx, edx
mov edx, dword [esp + 0x14]
push eax
push ecx
push ebx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov eax, dword [esp + 0x30058]
push ebp
push 0
push esi
push eax
call fcn.0048f830
add esp, 0x10
test eax, eax
jne 0x49d6e0
push ebx
call sub.MFC42.DLL_operatordelete
push ebp
call sub.MFC42.DLL_operatordelete
add esp, 8
mov ecx, dword [esp + 0x10]
push ecx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0xee1
pop ebx
add esp, 0x30044
ret
mov ecx, dword [esp + 0x14]
mov edi, ebp
mov esi, ebx
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
je 0x49d718
push ebx
call sub.MFC42.DLL_operatordelete
push ebp
call sub.MFC42.DLL_operatordelete
add esp, 8
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0xee2
pop ebx
add esp, 0x30044
ret
push ebx
call sub.MFC42.DLL_operatordelete
push ebp
call sub.MFC42.DLL_operatordelete
add esp, 8
mov ebx, dword [esp + 0x10]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x30044
ret
mov ebx, dword [esp + 0x10]
push 0
push 0
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
xor ecx, ecx
xor eax, eax
mov dword [esp + 0x2c], ecx
lea edi, [esp + 0x20054]
mov dword [esp + 0x30], ecx
mov dword [esp + 0x34], ecx
mov dword [esp + 0x38], ecx
mov ecx, 0x4000
rep stosd dword es:[edi], eax
mov eax, dword [esp + 0x18]
test eax, eax
jl 0x49d941
jg 0x49d78c
mov eax, dword [esp + 0x14]
test eax, eax
jbe 0x49d941
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
xor esi, esi
lea edx, [esp + 0x1c]
push 0
push edx
lea eax, [esp + 0x34]
push 0x10
push eax
push ebx
call edi
test eax, eax
jne 0x49d7b8
cmp esi, 2
je 0x49db20
inc esi
cmp esi, 3
jl 0x49d794
mov esi, dword [esp + 0x14]
mov edx, dword [esp + 0x18]
mov eax, dword [esp + 0x2c]
add esi, 0xfffffff0
adc edx, 0xffffffff
cmp al, 0x41
mov dword [esp + 0x14], esi
mov dword [esp + 0x18], edx
jne 0x49db26
cmp ah, 0x4c
jne 0x49db26
cmp byte [esp + 0x2e], 0x43
jne 0x49db26
cmp byte [esp + 0x2f], 0x4f
jne 0x49db26
cmp byte [esp + 0x30], 0x52
jne 0x49db26
mov esi, dword [esp + 0x31]
mov ecx, dword [esp + 0x32]
mov edx, dword [esp + 0x33]
mov eax, dword [esp + 0x36]
and esi, 0xff
and ecx, 0xff
shl esi, 8
or esi, ecx
mov ecx, dword [esp + 0x34]
shl esi, 8
and edx, 0xff
mov ebp, eax
or esi, edx
and ecx, 0xff
shl esi, 8
and ebp, 0xff
or esi, ecx
test ebp, ebp
je 0x49db26
test ah, ah
jne 0x49d8e8
mov ebx, ebp
xor eax, eax
shl ebx, 9
mov ecx, ebx
lea edi, [esp + 0x54]
mov edx, ecx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
xor edi, edi
mov edx, dword [esp + 0x10]
lea eax, [esp + 0x1c]
push 0
push eax
lea ecx, [esp + 0x5c]
push ebx
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x49d89f
cmp edi, 2
je 0x49d6c5
inc edi
cmp edi, 3
jl 0x49d874
xor edi, edi
mov ecx, dword [esp + 0x30058]
lea eax, [esp + 0x54]
push eax
push esi
push ebp
push ecx
call fcn.0048f970
add esp, 0x10
test eax, eax
jne 0x49d8cb
cmp edi, 2
je 0x49d358
inc edi
cmp edi, 3
jl 0x49d8a1
mov ecx, dword [esp + 0x14]
mov eax, ebx
cdq
mov ebx, dword [esp + 0x10]
sub ecx, eax
mov eax, dword [esp + 0x18]
mov dword [esp + 0x14], ecx
sbb eax, edx
mov dword [esp + 0x18], eax
jmp 0x49d927
cmp ah, 1
jne 0x49d91e
xor edi, edi
mov eax, dword [esp + 0x30058]
lea edx, [esp + 0x20054]
push edx
push esi
push ebp
push eax
call fcn.0048f970
add esp, 0x10
test eax, eax
jne 0x49d927
cmp edi, 2
je 0x49db26
inc edi
cmp edi, 3
jl 0x49d8ef
jmp 0x49d927
cmp ah, 2
jne 0x49db26
mov eax, dword [esp + 0x18]
test eax, eax
jg 0x49d78c
jl 0x49d941
mov eax, dword [esp + 0x14]
test eax, eax
ja 0x49d78c
push 0
push 0
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
xor eax, eax
mov ecx, 0x4000
mov dword [esp + 0x2c], eax
lea edi, [esp + 0x20054]
mov dword [esp + 0x30], eax
mov dword [esp + 0x34], eax
mov dword [esp + 0x38], eax
rep stosd dword es:[edi], eax
mov eax, dword [esp + 0x28]
mov ecx, dword [esp + 0x24]
test eax, eax
mov dword [esp + 0x14], ecx
mov dword [esp + 0x18], eax
jl 0x49d72b
jg 0x49d990
test ecx, ecx
jbe 0x49d72b
mov ebx, dword [esp + 0x10]
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
xor esi, esi
lea ecx, [esp + 0x1c]
push 0
push ecx
lea edx, [esp + 0x34]
push 0x10
push edx
push ebx
call edi
test eax, eax
jne 0x49d9c0
cmp esi, 2
je 0x49db20
inc esi
cmp esi, 3
jl 0x49d99c
mov esi, dword [esp + 0x14]
mov edx, dword [esp + 0x18]
mov eax, dword [esp + 0x2c]
add esi, 0xfffffff0
adc edx, 0xffffffff
cmp al, 0x41
mov dword [esp + 0x14], esi
mov dword [esp + 0x18], edx
jne 0x49db20
cmp ah, 0x4c
jne 0x49db20
cmp byte [esp + 0x2e], 0x43
jne 0x49db20
cmp byte [esp + 0x2f], 0x4f
jne 0x49db20
cmp byte [esp + 0x30], 0x52
jne 0x49db20
mov esi, dword [esp + 0x31]
mov ecx, dword [esp + 0x32]
mov edx, dword [esp + 0x33]
mov eax, dword [esp + 0x36]
and esi, 0xff
and ecx, 0xff
shl esi, 8
or esi, ecx
mov ecx, dword [esp + 0x34]
shl esi, 8
and edx, 0xff
mov ebx, eax
or esi, edx
and ecx, 0xff
shl esi, 8
and ebx, 0xff
or esi, ecx
test ebx, ebx
je 0x49dbd3
test ah, ah
jne 0x49db3d
mov ebp, ebx
xor eax, eax
shl ebp, 9
mov ecx, ebp
lea edi, [esp + 0x54]
mov edx, ecx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
mov ecx, ebp
xor eax, eax
lea edi, [esp + 0x10054]
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
xor edi, edi
mov edx, dword [esp + 0x10]
lea eax, [esp + 0x1c]
push 0
push eax
lea ecx, [esp + 0x5c]
push ebp
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x49dabe
cmp edi, 2
je 0x49d6c5
inc edi
cmp edi, 3
jl 0x49da93
xor edi, edi
mov ecx, dword [esp + 0x30058]
lea eax, [esp + 0x10054]
push eax
push esi
push ebx
push ecx
call fcn.0048f830
add esp, 0x10
test eax, eax
jne 0x49daed
cmp edi, 2
je 0x49d5c3
inc edi
cmp edi, 3
jl 0x49dac0
mov ecx, ebp
lea edi, [esp + 0x10054]
lea esi, [esp + 0x54]
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
jne 0x49d6fd
mov ecx, dword [esp + 0x14]
mov eax, ebp
cdq
sub ecx, eax
mov eax, dword [esp + 0x18]
sbb eax, edx
mov dword [esp + 0x14], ecx
mov dword [esp + 0x18], eax
jmp 0x49dbb0
push ebx
jmp 0x49d6ca
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0xee
pop ebx
add esp, 0x30044
ret
cmp ah, 1
jne 0x49dba7
mov ebp, ebx
xor eax, eax
shl ebp, 9
mov ecx, ebp
lea edi, [esp + 0x10054]
mov edx, ecx
shr ecx, 2
rep stosd dword es:[edi], eax
mov ecx, edx
and ecx, 3
rep stosb byte es:[edi], al
xor edi, edi
mov ecx, dword [esp + 0x30058]
lea eax, [esp + 0x10054]
push eax
push esi
push ebx
push ecx
call fcn.0048f830
add esp, 0x10
test eax, eax
jne 0x49db8f
cmp edi, 2
je 0x49d6c5
inc edi
cmp edi, 3
jl 0x49db62
mov ecx, ebp
lea edi, [esp + 0x10054]
lea esi, [esp + 0x20054]
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
jne 0x49dbee
jmp 0x49dbb0
cmp ah, 2
jne 0x49d3ff
mov eax, dword [esp + 0x18]
test eax, eax
jg 0x49d990
jl 0x49d727
mov eax, dword [esp + 0x14]
test eax, eax
ja 0x49d990
jmp 0x49d727
mov eax, dword [esp + 0x10]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0xee1
pop ebx
add esp, 0x30044
ret
mov edx, dword [esp + 0x10]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 0xee2
pop ebx
add esp, 0x30044
ret