Function at 0x40116d
Capabilities:
Read file on windows

Disassembly:
jmp 0x40830e
sub esp, 0x20
push ebx
push ebp
push esi
xor ebx, ebx
push edi
push ebx
push 0x80000020
push 3
push ebx
push 1
push 0x80000000
mov dword [esp + 0x28], ebx
push dword [esp + 0x4c]
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, dword [sym.imp.KERNEL32.dll_ReadFile]
mov ebp, 0x9bd278
mov esi, eax
push ebx
push ebp
lea eax, [esp + 0x30]
push 4
push eax
push esi
mov dword [esp + 0x34], esi
call edi
lea eax, [esp + 0x28]
push str.IWAD
push eax
mov byte [esp + 0x34], bl
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
je 0x40838c
lea eax, [esp + 0x28]
push str.PWAD
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x40892c
push ebx
push ebp
lea eax, [esp + 0x2c]
push 4
push eax
push esi
call edi
mov eax, dword [esp + 0x24]
push dword [0xac59f8]
mov dword [0x6a1318], eax
call dword [sym.imp.KERNEL32.dll_GlobalUnlock]
push dword [0xac59f8]
call dword [sym.imp.KERNEL32.dll_GlobalFree]
mov eax, dword [0x6a1318]
lea eax, [eax + eax*2 + 0x12c]
shl eax, 3
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
push eax
mov dword [0xac59f8], eax
call dword [sym.imp.KERNEL32.dll_GlobalLock]
mov dword [0x9bd2c4], eax
push ebx
push ebp
lea eax, [esp + 0x24]
push 4
push eax
push esi
call edi
push ebx
push ebx
push dword [esp + 0x24]
push esi
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
mov eax, dword [esp + 0x1c]
cmp dword [0x6a1318], ebx
mov dword [0xac5a1c], eax
mov dword [0xac5a20], 0xc
mov dword [esp + 0x34], ebx
jle 0x40892c
xor esi, esi
mov eax, dword [0x9bd2c4]
push ebx
push ebp
add eax, esi
push 0x10
push eax
push dword [esp + 0x30]
call edi
mov eax, dword [0x9bd2c4]
add eax, esi
mov ecx, dword [eax + 4]
add dword [0xac5a20], ecx
mov byte [eax + 0x10], bl
mov eax, dword [0x9bd2c4]
add eax, esi
cmp dword [eax + 4], ebx
jle 0x408486
cmp dword [esp + 0x10], ebx
je 0x408462
mov dword [eax + 0x14], 0xc
jmp 0x408911
cmp dword [esp + 0x14], ebx
je 0x408474
mov dword [eax + 0x14], 0xd
jmp 0x408911
cmp dword [esp + 0x18], ebx
je 0x408486
mov dword [eax + 0x14], 0xe
jmp 0x408911
mov cl, byte [eax + 8]
lea edx, [eax + 8]
cmp cl, 0x44
jne 0x4084d1
cmp byte [eax + 9], 0x53
jne 0x4084a3
mov dword [eax + 0x14], 0x10
jmp 0x408911
cmp cl, 0x44
jne 0x4084d1
cmp byte [eax + 9], 0x50
jne 0x4084ba
mov dword [eax + 0x14], 0x11
jmp 0x408911
cmp cl, 0x44
jne 0x4084d1
cmp byte [eax + 9], 0x5f
jne 0x4084d1
mov dword [eax + 0x14], 0xf
jmp 0x408911
cmp cl, 0x57
jne 0x4084e8
cmp byte [eax + 9], 0x49
jne 0x4084e8
mov dword [eax + 0x14], 0x1a
jmp 0x408911
cmp cl, 0x4d
jne 0x4084ff
cmp byte [eax + 9], 0x5f
jne 0x4084ff
mov dword [eax + 0x14], 0x1b
jmp 0x408911
cmp cl, 0x53
jne 0x408516
cmp byte [eax + 9], 0x54
jne 0x408516
mov dword [eax + 0x14], 0x19
jmp 0x408911
cmp cl, 0x44
jne 0x408539
cmp byte [eax + 9], 0x45
jne 0x408539
cmp byte [eax + 0xa], 0x4d
jne 0x408539
cmp byte [eax + 0xb], 0x4f
jne 0x408539
mov dword [eax + 0x14], 0x16
jmp 0x408911
cmp cl, 0x50
jne 0x40855c
cmp byte [eax + 9], 0x4e
jne 0x40855c
cmp byte [eax + 0xa], 0x41
jne 0x40855c
cmp byte [eax + 0xb], 0x4d
jne 0x40855c
mov dword [eax + 0x14], 0x17
jmp 0x408911
push str.PLAYPAL
push edx
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x40857f
mov eax, dword [0x9bd2c4]
mov dword [esi + eax + 0x14], 0x13
jmp 0x408911
mov eax, dword [0x9bd2c4]
push str.COLORMAP
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
mov eax, dword [0x9bd2c4]
pop ecx
jne 0x4085ab
mov dword [esi + eax + 0x14], 0x14
jmp 0x408911
add eax, esi
cmp byte [eax + 8], 0x54
lea ecx, [eax + 8]
jne 0x4085e0
cmp byte [eax + 9], 0x45
jne 0x4085e0
cmp byte [eax + 0xa], 0x58
jne 0x4085e0
cmp byte [eax + 0xb], 0x54
jne 0x4085e0
cmp byte [eax + 0xc], 0x55
jne 0x4085e0
cmp byte [eax + 0xd], 0x52
jne 0x4085e0
mov dword [eax + 0x14], 0x12
jmp 0x408911
push str.THINGS
push ecx
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x408603
mov eax, dword [0x9bd2c4]
mov dword [esi + eax + 0x14], 2
jmp 0x408911
mov eax, dword [0x9bd2c4]
push str.LINEDEFS
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x40862f
mov eax, dword [0x9bd2c4]
mov dword [esi + eax + 0x14], 3
jmp 0x408911
mov eax, dword [0x9bd2c4]
push str.SIDEDEFS
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x40865b
mov eax, dword [0x9bd2c4]
mov dword [esi + eax + 0x14], 4
jmp 0x408911
mov eax, dword [0x9bd2c4]
push str.VERTEXES
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x408687
mov eax, dword [0x9bd2c4]
mov dword [esi + eax + 0x14], 5
jmp 0x408911
mov eax, dword [0x9bd2c4]
push str.SEGS
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x4086b3
mov eax, dword [0x9bd2c4]
mov dword [esi + eax + 0x14], 6
jmp 0x408911
mov eax, dword [0x9bd2c4]
push str.SSECTORS
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x4086df
mov eax, dword [0x9bd2c4]
mov dword [esi + eax + 0x14], 7
jmp 0x408911
mov eax, dword [0x9bd2c4]
push str.NODES
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x40870b
mov eax, dword [0x9bd2c4]
mov dword [esi + eax + 0x14], 8
jmp 0x408911
mov eax, dword [0x9bd2c4]
push str.SECTORS
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x408737
mov eax, dword [0x9bd2c4]
mov dword [esi + eax + 0x14], 9
jmp 0x408911
mov eax, dword [0x9bd2c4]
push str.REJECT
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x408763
mov eax, dword [0x9bd2c4]
mov dword [esi + eax + 0x14], 0xa
jmp 0x408911
mov eax, dword [0x9bd2c4]
push str.BLOCKMAP
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x40878f
mov eax, dword [0x9bd2c4]
mov dword [esi + eax + 0x14], 0xb
jmp 0x408911
mov eax, dword [0x9bd2c4]
push str.PLATFORM
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
je 0x408904
mov eax, dword [0x9bd2c4]
push str.TAGDESC
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
je 0x408904
mov eax, dword [0x9bd2c4]
push str.ENDOOM
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
mov eax, dword [0x9bd2c4]
pop ecx
jne 0x4087f7
mov dword [esi + eax + 0x14], 0x15
jmp 0x408911
add eax, esi
cmp dword [eax + 4], ebx
jne 0x4088fb
mov cl, byte [eax + 8]
cmp cl, 0x45
jne 0x408815
cmp byte [eax + 0xa], 0x4d
jne 0x408815
cmp byte [eax + 0xc], bl
je 0x408826
cmp cl, 0x4d
jne 0x408832
cmp byte [eax + 9], 0x41
jne 0x408832
cmp byte [eax + 0xa], 0x50
jne 0x408832
mov dword [eax + 0x14], 0x1d
jmp 0x408911
mov dword [eax + 0x14], 1
mov eax, dword [0x9bd2c4]
push str.S_START
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x40885b
mov dword [esp + 0x10], 1
mov eax, dword [0x9bd2c4]
push str.S_END
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x408879
mov dword [esp + 0x10], ebx
mov eax, dword [0x9bd2c4]
push str.P_START
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x40889b
mov dword [esp + 0x14], 1
mov eax, dword [0x9bd2c4]
push str.P_END
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x4088b9
mov dword [esp + 0x14], ebx
mov eax, dword [0x9bd2c4]
push str.F_START
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x4088db
mov dword [esp + 0x18], 1
mov eax, dword [0x9bd2c4]
push str.F_END
lea eax, [esi + eax + 8]
push eax
call sub.MSVCRT.dll_strcmp
pop ecx
test eax, eax
pop ecx
jne 0x408911
mov dword [esp + 0x18], ebx
jmp 0x408911
mov dword [eax + 0x14], 0x1c
jmp 0x408911
mov eax, dword [0x9bd2c4]
mov dword [esi + eax + 0x14], 0x1e
inc dword [esp + 0x34]
add esi, 0x18
mov eax, dword [esp + 0x34]
cmp eax, dword [0x6a1318]
jl 0x40841f
mov esi, dword [esp + 0x20]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x20
ret