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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x50
push ebx
push esi
xor ebx, ebx
push edi
push ebx
push 0x80
push 3
push ebx
push 1
push 0x80000000
mov ecx, 0x482ab8
call fcn.0041fa6a
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
or eax, 0xffffffff
cmp esi, eax
mov dword [ebp - 8], esi
je 0x41d2e7
lea eax, [ebp - 0x40]
mov dword [ebp - 0xc], ebx
push eax
push esi
mov dword [ebp - 0x40], ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, dword [sym.imp.KERNEL32.dll_SetFilePointer]
push 2
push ebx
push 0xfffffffffffffff8
push esi
mov dword [ebp - 0x30], eax
mov dword [ebp - 0x1c], 8
mov dword [ebp - 0x24], ebx
mov dword [ebp - 0x28], ebx
call edi
lea eax, [ebp - 0xc]
push ebx
push eax
lea eax, [ebp - 0x24]
push 4
push eax
push esi
mov esi, dword [sym.imp.KERNEL32.dll_ReadFile]
call esi
lea eax, [ebp - 0xc]
push ebx
push eax
lea eax, [ebp - 0x28]
push 4
push eax
push dword [ebp - 8]
call esi
cmp dword [ebp - 0x24], 0xb1c2d3e
jne 0x41d00f
cmp dword [ebp - 0x28], 0x12345678
je 0x41d174
push ebx
push ebx
push 0x190
push dword [ebp - 8]
call edi
lea eax, [ebp - 0xc]
push ebx
push eax
lea eax, [ebp - 0x14]
push 4
push eax
push dword [ebp - 8]
mov dword [ebp - 0x14], ebx
mov dword [ebp - 0x10], ebx
call esi
lea eax, [ebp - 0xc]
push ebx
push eax
lea eax, [ebp - 0x10]
push 4
push eax
push dword [ebp - 8]
call esi
lea eax, [ebp - 0xc]
push ebx
push eax
lea eax, [ebp - 0x34]
push 4
push eax
push dword [ebp - 8]
mov dword [ebp - 0x34], ebx
mov dword [ebp - 0x2c], ebx
call esi
lea eax, [ebp - 0xc]
push ebx
push eax
lea eax, [ebp - 0x2c]
push 4
push eax
push dword [ebp - 8]
call esi
lea eax, [ebp - 0xc]
push ebx
push eax
lea eax, [ebp - 0x38]
push 4
push eax
push dword [ebp - 8]
mov dword [ebp - 0x38], ebx
mov dword [ebp - 0x3c], ebx
call esi
lea eax, [ebp - 0xc]
push ebx
push eax
lea eax, [ebp - 0x3c]
push 4
push eax
push dword [ebp - 8]
call esi
mov eax, dword [ebp - 0x14]
cmp eax, ebx
jne 0x41d0c5
cmp dword [ebp - 0x10], ebx
jne 0x41d2d2
mov eax, dword [ebp - 0x34]
mov ecx, dword [ebp - 0x2c]
cmp eax, ebx
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x10], ecx
jne 0x41d0c5
cmp ecx, ebx
jne 0x41d0bd
mov eax, dword [ebp - 0x38]
mov ecx, dword [ebp - 0x3c]
mov dword [ebp - 0x14], eax
mov dword [ebp - 0x10], ecx
cmp eax, ebx
je 0x41d2d2
cmp eax, dword [ebp - 0x30]
ja 0x41d2d2
cmp dword [ebp - 0x10], ebx
je 0x41d2d2
lea ecx, [ebp - 0x44]
push ebx
push ecx
push eax
push dword [ebp - 8]
mov dword [ebp - 0x44], ebx
call edi
mov dword [ebp - 0x1c], ebx
push 1
push ebx
push 0xffffffffffffffff
push dword [ebp - 8]
call edi
lea eax, [ebp - 0xc]
push ebx
push eax
lea eax, [ebp - 1]
push 1
push eax
push dword [ebp - 8]
mov byte [ebp - 1], bl
call esi
cmp byte [ebp - 1], bl
jne 0x41d11d
push 1
push ebx
push 0xffffffffffffffff
push dword [ebp - 8]
call edi
inc dword [ebp - 0x1c]
cmp dword [ebp - 0x1c], 8
jl 0x41d0e8
mov eax, dword [ebp - 0x1c]
push 2
sub dword [ebp - 0x14], eax
add dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x10]
push ebx
add eax, 8
mov dword [ebp - 0x1c], eax
neg eax
push eax
push dword [ebp - 8]
call edi
lea eax, [ebp - 0xc]
push ebx
push eax
lea eax, [ebp - 0x24]
push 4
push eax
push dword [ebp - 8]
call esi
lea eax, [ebp - 0xc]
push ebx
push eax
lea eax, [ebp - 0x28]
push 4
push eax
push dword [ebp - 8]
call esi
cmp dword [ebp - 0x24], 0xb1c2d3e
jne 0x41d2d2
cmp dword [ebp - 0x28], 0x12345678
jne 0x41d2d2
push 2
push ebx
push 0xfffffffffffffffc
mov dword [ebp - 0x18], ebx
pop eax
sub eax, dword [ebp - 0x1c]
push eax
push dword [ebp - 8]
call edi
lea eax, [ebp - 0xc]
push ebx
push eax
lea eax, [ebp - 0x18]
push 4
push eax
push dword [ebp - 8]
call esi
mov eax, dword [ebp - 0x18]
cmp eax, 0xffffffff
je 0x41d214
cmp eax, 0x3e8
ja 0x41d2b8
mov ecx, dword [ebp - 0x30]
push eax
sub ecx, eax
sub ecx, dword [ebp - 0x1c]
sub ecx, 4
push ecx
mov ecx, 0x482ab8
call fcn.0041fa6a
push eax
mov ecx, 0x4822d0
call fcn.0041f806
push 0x4822d0
lea ecx, [ebp - 0x50]
call fcn.0041eb84
lea ecx, [ebp - 0x50]
call fcn.0041f00c
test al, al
jne 0x41d1ed
mov byte [0x482488], 1
jmp 0x41d20a
lea eax, [ebp - 0x50]
push eax
call fcn.00420b2a
pop ecx
lea ecx, [ebp - 0x50]
call fcn.0041f00c
neg al
sbb al, al
inc al
mov byte [0x482488], al
lea ecx, [ebp - 0x50]
call fcn.0041ebe6
jmp 0x41d21e
mov dword [ebp - 0x18], ebx
mov byte [0x482488], 1
push 2
push ebx
push 0xfffffffffffffff8
pop eax
sub eax, dword [ebp - 0x18]
sub eax, dword [ebp - 0x1c]
push eax
push dword [ebp - 8]
call edi
lea eax, [ebp - 0xc]
push ebx
push eax
lea eax, [ebp - 0x20]
push 4
push eax
push dword [ebp - 8]
mov dword [ebp - 0x20], ebx
call esi
test eax, eax
jne 0x41d257
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0xfffffffffffffffe
jmp 0x41d2e6
mov esi, dword [ebp - 0x30]
mov eax, esi
sub eax, dword [ebp - 0x20]
sub eax, dword [ebp - 0x18]
sub eax, dword [ebp - 0x1c]
sub eax, 8
cmp eax, 0x3e8
ja 0x41d2b8
push dword [ebp - 8]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esi, dword [ebp - 0x20]
mov ecx, 0x482ab8
sub esi, dword [ebp - 0x18]
sub esi, dword [ebp - 0x1c]
sub esi, 8
push esi
push dword [ebp - 0x20]
call fcn.0041fa6a
mov esi, 0x482668
push eax
mov ecx, esi
call fcn.0041f806
test eax, eax
jge 0x41d2a7
push 0xfffffffffffffffd
jmp 0x41d2e6
push 0xe8
mov ecx, esi
call fcn.0041f63e
cmp eax, dword [ebp - 0x20]
je 0x41d2ce
push ebx
mov ecx, 0x482320
push dword [0x4303fc]
push ebx
call fcn.0041df67
push 0xfffffffffffffffc
jmp 0x41d2e6
push 1
jmp 0x41d2e6
push ebx
mov ecx, 0x482320
push dword [0x4303f8]
push ebx
call fcn.0041df67
push 0xfffffffffffffffb
pop eax
pop edi
pop esi
pop ebx
leave
ret