Function at 0x41aa30
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x49d980]
xor eax, ebp
mov dword [ebp - 8], eax
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, dword [ebp + 8]
mov dword [ebp - 0x28], ebx
mov dword [ebp - 0x30], eax
push esi
push edi
mov edi, edx
mov edx, dword [ebp + 0xc]
mov dword [ebp - 0x2c], edx
test ebx, ebx
je 0x41ac3a
test edx, edx
je 0x41ac3a
test eax, eax
je 0x41ac3a
push 0
push 3
push 1
push closesocket
push ecx
mov dword [eax], 0
call dword [sym.imp.KERNEL32.dll_CreateFile2]
mov esi, eax
xor eax, eax
cmp esi, 0xffffffff
cmove esi, eax
test esi, esi
jne 0x41aabc
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x41ac3f
movzx eax, ax
or eax, 0x80070000
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0047cd55
mov esp, ebp
pop ebp
ret
push 0x18
lea eax, [ebp - 0x24]
push eax
push 1
push esi
call dword [sym.imp.KERNEL32.dll_GetFileInformationByHandleEx]
test eax, eax
jne 0x41aafe
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
test edi, edi
jle 0x41aae4
movzx edi, di
or edi, 0x80070000
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, edi
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0047cd55
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 0x18], 0
jg 0x41ac1d
mov eax, dword [ebp - 0x1c]
cmp eax, 0x80
jb 0x41ac1d
push 0x486a88
push eax
call fcn.0047d0df
mov ecx, dword [edi]
add esp, 8
mov dword [edi], eax
test ecx, ecx
je 0x41ab35
push ecx
call fcn.0047d0da
add esp, 4
mov eax, dword [edi]
test eax, eax
jne 0x41ab58
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 0x8007000e
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0047cd55
mov esp, ebp
pop ebp
ret
push 0
lea ecx, [ebp - 0xc]
mov dword [ebp - 0xc], 0
push ecx
push dword [ebp - 0x1c]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
mov eax, dword [edi]
jne 0x41ab92
mov dword [edi], 0
test eax, eax
je 0x41aacf
push eax
call fcn.0047d0da
add esp, 4
jmp 0x41aacf
mov edx, dword [ebp - 0x1c]
cmp dword [ebp - 0xc], edx
jb 0x41ac0a
cmp dword [eax], 0x20534444
jne 0x41ac0a
cmp dword [eax + 4], 0x7c
lea ecx, [eax + 4]
jne 0x41ac0a
cmp dword [ecx + 0x48], 0x20
jne 0x41ac0a
xor bl, bl
test byte [ecx + 0x4c], 4
je 0x41abcc
cmp dword [ecx + 0x50], 0x30315844
jne 0x41abcc
cmp edx, 0x94
jb 0x41ac0a
mov bl, 1
mov eax, dword [ebp - 0x28]
test bl, bl
push esi
mov dword [eax], ecx
mov eax, 0x94
mov ecx, 0x80
cmovne ecx, eax
mov eax, dword [edi]
mov edi, dword [ebp - 0x2c]
add eax, ecx
sub edx, ecx
mov dword [edi], eax
mov eax, dword [ebp - 0x30]
mov dword [eax], edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0047cd55
mov esp, ebp
pop ebp
ret
mov dword [edi], 0
test eax, eax
je 0x41ac1d
push eax
call fcn.0047d0da
add esp, 4
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, 0x80004005
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.0047cd55
mov esp, ebp
pop ebp
ret
mov eax, 0x80004003
mov ecx, dword [ebp - 8]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.0047cd55
mov esp, ebp
pop ebp
ret