Function at 0x401000
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x30
mov eax, dword [0x44c040]
xor eax, ebp
mov dword [ebp - 8], eax
mov ecx, dword [ebp + 0xc]
mov eax, dword [ebp + 0x10]
push ebx
push esi
push edi
mov edi, edx
mov dword [ebp - 0x2c], ecx
mov edx, dword [ebp + 8]
mov dword [ebp - 0x28], edx
mov dword [ebp - 0x30], eax
test edx, edx
je 0x40120e
test ecx, ecx
je 0x40120e
test eax, eax
je 0x40120e
push 0
push 3
push 1
push 0x80000000
push str.C:UserspcDesktopweqImGui_Standalone_mainSourceRelease_frame.dds
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 0x401090
call dword [sym.imp.KERNEL32.dll_GetLastError]
test eax, eax
jle 0x401213
movzx eax, ax
or eax, 0x80070000
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 8]
xor ecx, ebp
call fcn.004411d1
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 0x4010d2
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov edi, eax
test edi, edi
jle 0x4010b8
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.004411d1
mov esp, ebp
pop ebp
ret
cmp dword [ebp - 0x18], 0
jg 0x4011f1
mov eax, dword [ebp - 0x1c]
cmp eax, 0x80
jb 0x4011f1
push 0x443680
push eax
call fcn.004411e4
mov ecx, dword [edi]
add esp, 8
mov dword [edi], eax
test ecx, ecx
je 0x401109
push ecx
call fcn.004411df
add esp, 4
mov eax, dword [edi]
test eax, eax
jne 0x40112c
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.004411d1
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 0x401166
mov dword [edi], 0
test eax, eax
je 0x4010a3
push eax
call fcn.004411df
add esp, 4
jmp 0x4010a3
mov edx, dword [ebp - 0x1c]
cmp dword [ebp - 0xc], edx
jb 0x4011de
cmp dword [eax], 0x20534444
jne 0x4011de
cmp dword [eax + 4], 0x7c
lea ecx, [eax + 4]
jne 0x4011de
cmp dword [ecx + 0x48], 0x20
jne 0x4011de
xor bl, bl
test byte [ecx + 0x4c], 4
je 0x4011a0
cmp dword [ecx + 0x50], 0x30315844
jne 0x4011a0
cmp edx, 0x94
jb 0x4011de
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.004411d1
mov esp, ebp
pop ebp
ret
mov dword [edi], 0
test eax, eax
je 0x4011f1
push eax
call fcn.004411df
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.004411d1
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.004411d1
mov esp, ebp
pop ebp
ret