Function at 0x402400
Capabilities:
Accept command line arguments
Get file size
Get process heap flags
Read file on windows
Set console window title
Set current directory
Terminate process

Disassembly:
lea ecx, [esp + 4]
and esp, 0xfffffff8
push dword [ecx - 4]
push ebp
mov ebp, esp
push edi
push esi
push ebx
push ecx
sub esp, 0x528
mov esi, dword [ecx + 4]
call fcn.00402340
mov ebx, dword [esi + 4]
test ebx, ebx
je 0x402ac1
mov dword [esp + 4], str.__app_name
mov dword [esp], ebx
call dword [sym.imp.ucrtbase.dll_strcmp]
test eax, eax
jne 0x4028e3
mov eax, dword [esi + 8]
mov dword [ebp - 0x4f8], eax
test eax, eax
je 0x402ac1
lea ecx, [esi + 0xc]
mov edi, dword [ecx]
test edi, edi
je 0x402792
mov ebx, dword [ecx + 4]
lea eax, [ecx + 4]
mov dword [ebp - 0x4ec], eax
test ebx, ebx
je 0x402798
mov edi, eax
xor eax, eax
mov dword [ebp - 0x4f4], ecx
mov dword [ebp - 0x4f0], edi
mov edi, eax
mov dword [ebp - 0x500], esi
lea esi, [esi]
movzx eax, byte [ebx]
test al, al
je 0x402783
mov edx, ebx
xor esi, esi
xor ecx, ecx
jmp 0x4024cd
cmp al, 9
je 0x402768
cmp al, 0x20
je 0x402768
cmp al, 0x22
je 0x402778
xor ecx, ecx
movzx eax, byte [edx + 1]
add edx, 1
test al, al
je 0x4024df
cmp al, 0x5c
jne 0x4024a8
movzx eax, byte [edx + 1]
add edx, 1
add ecx, 1
test al, al
jne 0x4024cd
sub edx, ebx
add edx, 1
add dword [ebp - 0x4f0], 4
add edx, edi
mov eax, dword [ebp - 0x4f0]
lea edi, [edx + esi*2]
mov ebx, dword [eax]
test ebx, ebx
jne 0x402490
mov ecx, dword [ebp - 0x4f4]
mov dword [ebp - 0x4fc], edi
mov esi, dword [ebp - 0x500]
mov dword [ebp - 0x4f0], ecx
test edi, edi
je 0x402798
lea edx, [edi + 1]
xor ebx, ebx
mov dword [esp + 8], edx
mov dword [esp + 4], ebx
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_HeapAlloc]
mov ecx, dword [ebp - 0x4f0]
sub esp, 0xc
test eax, eax
mov dword [ebp - 0x500], eax
je 0x402ada
mov eax, dword [ebp - 0x500]
cmp dword [ebp - 0x4fc], 0xff
lea ebx, [eax + 1]
jle 0x402aa2
mov edi, dword [ecx + 4]
mov byte [eax], 0xff
test edi, edi
je 0x402644
mov dword [ebp - 0x4f0], edi
mov dword [ebp - 0x504], esi
lea esi, cs:[esi]
mov edx, dword [ebp - 0x4f0]
movzx ecx, byte [edx]
test cl, cl
je 0x4029c5
mov eax, ecx
xor esi, esi
xor edi, edi
jmp 0x4025c3
cmp al, 0x22
je 0x4027f8
movzx eax, byte [edx + 1]
add edx, 1
test al, al
je 0x4025e3
cmp al, 0x20
je 0x4025cb
cmp al, 9
jne 0x4025b0
test edi, edi
jne 0x402810
movzx eax, byte [edx + 1]
add edx, 1
mov esi, 1
test al, al
jne 0x4025c3
test esi, esi
jne 0x4028b4
test edi, edi
jne 0x40282a
mov edi, dword [ebp - 0x4f0]
mov dword [esp], ebx
mov dword [esp + 4], edi
call dword [sym.imp.ucrtbase.dll_strcpy]
mov dword [esp], edi
call dword [sym.imp.ucrtbase.dll_strlen]
add eax, ebx
add dword [ebp - 0x4ec], 4
mov byte [eax], 0x20
lea ebx, [eax + 1]
mov eax, dword [ebp - 0x4ec]
mov eax, dword [eax]
mov dword [ebp - 0x4f0], eax
test eax, eax
jne 0x402590
mov eax, dword [ebp - 0x4fc]
mov esi, dword [ebp - 0x504]
test eax, eax
je 0x402647
sub ebx, 1
mov byte [ebx], 0
test byte [section..data], 8
jne 0x402946
lea eax, [ebp - 0x3d0]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_GetStartupInfoA]
mov eax, 2
sub esp, 4
mov word [ebp - 0x4e4], ax
mov eax, 1
test byte [ebp - 0x3a4], 1
je 0x40268a
movzx eax, word [ebp - 0x3a0]
mov word [ebp - 0x4e2], ax
xor eax, eax
mov word [ebp - 0x4d5], ax
mov eax, dword [ebp - 0x500]
mov dword [esp], eax
call sub.krnl386.exe16_MapLS
sub esp, 4
mov dword [ebp - 0x4d3], eax
lea eax, [ebp - 0x4e4]
mov dword [esp], eax
call sub.krnl386.exe16_MapLS
sub esp, 4
mov dword [ebp - 0x4cf], eax
mov dword [ebp - 0x4cb], 0
mov dword [esp], 1
call sub.krnl386.exe16_RestoreThunkLock
sub esp, 4
mov dword [esp], str.gdi.exe
call sub.krnl386.exe16_LoadLibrary16
sub esp, 4
mov dword [esp], str.user.exe
call sub.krnl386.exe16_LoadLibrary16
sub esp, 4
mov dword [esp], str.mmsystem.dll
call sub.krnl386.exe16_LoadLibrary16
lea eax, [ebp - 0x4d5]
sub esp, 4
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x4f8]
mov dword [esp], eax
call sub.krnl386.exe16_LoadModule16
movzx ebx, ax
sub esp, 8
cmp bx, 0x1f
jbe 0x402ae7
lea eax, [ebp - 0x184]
mov dword [esp], eax
call sub.krnl386.exe16_ReleaseThunkLock
sub esp, 4
mov dword [esp], 0xffffffff
call dword [sym.imp.kernel32.dll_Sleep]
xor eax, eax
sub esp, 4
lea esp, [ebp - 0x10]
pop ecx
pop ebx
pop esi
pop edi
pop ebp
lea esp, [ecx - 4]
ret
xor ecx, ecx
mov esi, 1
jmp 0x4024c2
lea edi, [edi + ecx*2 + 1]
xor ecx, ecx
jmp 0x4024c2
mov edx, 1
mov esi, 1
jmp 0x4024e4
mov dword [ebp - 0x4ec], ecx
xor edx, edx
mov dword [esp + 8], 2
mov dword [esp + 4], edx
mov eax, dword fs:[0x18]
mov eax, dword [eax + 0x30]
mov eax, dword [eax + 0x18]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_HeapAlloc]
sub esp, 0xc
mov dword [ebp - 0x500], eax
test eax, eax
je 0x402ada
mov eax, dword [ebp - 0x500]
xor edx, edx
mov dword [ebp - 0x4fc], edx
mov byte [eax], 0
lea ebx, [eax + 1]
mov eax, dword [ebp - 0x4ec]
mov edi, dword [eax]
test edi, edi
jne 0x40257c
jmp 0x402647
test esi, esi
jne 0x402810
mov edi, 1
jmp 0x4025b8
lea esi, [ebx + 1]
mov byte [ebx], 0x22
mov eax, dword [ebp - 0x4f0]
mov ebx, esi
movzx ecx, byte [eax]
test cl, cl
je 0x402880
mov esi, 1
xor edi, edi
mov dword [ebp - 0x4f4], esi
mov esi, edi
mov edi, dword [ebp - 0x4f0]
jmp 0x402856
cmp cl, 0x22
je 0x402890
mov byte [ebx], cl
xor esi, esi
mov ebx, eax
movzx ecx, byte [edi + 1]
add edi, 1
test cl, cl
je 0x402870
lea eax, [ebx + 1]
cmp cl, 0x5c
jne 0x402840
add edi, 1
mov byte [ebx], 0x5c
add esi, 1
mov ebx, eax
movzx ecx, byte [edi]
test cl, cl
jne 0x402856
mov esi, dword [ebp - 0x4f4]
mov eax, ebx
test esi, esi
je 0x402611
lea eax, [ebx + 1]
mov byte [ebx], 0x22
jmp 0x402611
lea eax, [esi + 1]
mov dword [esp], ebx
add esi, ebx
mov dword [esp + 8], eax
lea ebx, [esi + 2]
mov dword [esp + 4], 0x5c
call sub.ucrtbase.dll_memset
mov byte [esi + 1], 0x22
xor esi, esi
jmp 0x40284b
lea esi, [ebx + 1]
mov byte [ebx], 0x22
test edi, edi
jne 0x402816
mov edi, dword [ebp - 0x4f0]
mov dword [esp], esi
mov dword [esp + 4], edi
call dword [sym.imp.ucrtbase.dll_strcpy]
mov dword [esp], edi
call dword [sym.imp.ucrtbase.dll_strlen]
lea ebx, [esi + eax]
jmp 0x402880
lea edi, [ebp - 0x38c]
xor eax, eax
mov dword [esp + 4], ebx
mov dword [esp + 0x14], eax
xor eax, eax
mov dword [esp + 0x10], edi
mov dword [esp + 0xc], 0x104
mov dword [esp + 8], str..exe
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_SearchPathA]
lea ecx, [esi + 4]
sub esp, 0x18
mov dword [ebp - 0x4f8], edi
test eax, eax
jne 0x402457
mov eax, dword [esi + 4]
mov dword [esp], str.winevdm:_unable_to_exec__s:_file_not_found_n
mov dword [esp + 4], eax
call fcn.00401390
mov dword [esp], 1
call dword [sym.imp.kernel32.dll_ExitProcess]
mov dword [esp], section..data
call fcn.00402280
test al, 8
je 0x402657
test byte [section..data], 8
jne 0x4029ef
mov eax, dword [esi]
xor ebx, ebx
test eax, eax
jne 0x40298e
jmp 0x402657
add ebx, 1
mov eax, dword [esi + ebx*4]
test eax, eax
je 0x402657
test byte [section..data], 8
je 0x402980
mov dword [esp + 0x14], eax
mov dword [esp + 0x10], ebx
mov dword [esp + 0xc], str.argv__d_:__s_n
mov dword [esp + 8], str.main
mov dword [esp + 4], 0x404000
mov dword [esp], 3
call fcn.004018b0
jmp 0x402980
mov byte [ebx], 0x22
lea esi, [ebx + 1]
mov ebx, dword [ebp - 0x4f0]
mov dword [esp], esi
mov dword [esp + 4], ebx
call dword [sym.imp.ucrtbase.dll_strcpy]
mov dword [esp], ebx
call dword [sym.imp.ucrtbase.dll_strlen]
lea ebx, [esi + eax]
jmp 0x402880
call dword [sym.imp.kernel32.dll_GetCommandLineA]
mov dword [esp + 0xc], str.GetCommandLine___s_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.main
mov dword [esp + 4], 0x404000
mov dword [esp], 3
call fcn.004018b0
test byte [section..data], 8
je 0x402967
mov eax, dword [ebp - 0x4f8]
mov dword [esp + 0xc], str.appname___s_n
mov dword [esp + 8], str.main
mov dword [esp + 4], 0x404000
mov dword [esp], 3
mov dword [esp + 0x10], eax
call fcn.004018b0
test byte [section..data], 8
je 0x402967
mov edi, dword [ebp - 0x500]
lea eax, [edi + 1]
mov dword [esp + 0x14], eax
movsx eax, byte [edi]
mov dword [esp + 0xc], str.cmdline___.s_n
mov dword [esp + 8], str.main
mov dword [esp + 4], 0x404000
mov dword [esp + 0x10], eax
mov dword [esp], 3
call fcn.004018b0
jmp 0x402967
mov edi, dword [ebp - 0x500]
movzx eax, byte [ebp - 0x4fc]
mov byte [edi], al
mov edi, dword [ecx + 4]
test edi, edi
jne 0x40257c
jmp 0x402644
mov dword [esp], str.Usage:_winevdm.exe____app_name_app.exe__command_line_n_n
call fcn.00401390
mov dword [esp], 1
call dword [sym.imp.kernel32.dll_ExitProcess]
xor ecx, ecx
mov dword [ebp - 0x500], ecx
jmp 0x40264a
cmp bx, 0xb
je 0x402b35
mov eax, dword [ebp - 0x4f8]
mov dword [esp], str.winevdm:_cant_exec__s:
mov dword [esp + 4], eax
call fcn.00401390
cmp bx, 2
jne 0x402b23
mov dword [esp], str.file_not_found_n
mov ebx, 2
call fcn.00401390
mov dword [esp], ebx
call dword [sym.imp.kernel32.dll_ExitProcess]
mov dword [esp + 4], ebx
mov dword [esp], str.error_d_n
call fcn.00401390
jmp 0x402b1a
mov dword [esp + 4], 0x2e
mov eax, dword [ebp - 0x4f8]
mov dword [esp], eax
mov eax, dword [sym.imp.ucrtbase.dll_strrchr]
mov dword [ebp - 0x504], eax
call eax
mov ebx, dword [ebp - 0x500]
add ebx, 1
mov dword [ebp - 0x4f0], ebx
test eax, eax
je 0x402b84
mov dword [esp], eax
mov eax, dword [sym.imp.ucrtbase.dll__stricmp]
mov dword [esp + 4], str..pif
mov dword [ebp - 0x508], eax
call eax
mov ebx, eax
test eax, eax
je 0x402bc1
mov edx, dword [ebp - 0x4f0]
mov eax, dword [ebp - 0x4f8]
call fcn.004013b0
mov eax, dword [ebp - 0x4f8]
mov dword [esp], str.winevdm:_cant_exec__s:
mov ebx, 0xb
mov dword [esp + 4], eax
call fcn.00401390
mov dword [esp], str.invalid_program_file_n
call fcn.00401390
jmp 0x402b1a
xor eax, eax
mov dword [esp + 0x10], 3
mov dword [esp + 0x18], eax
mov dword [esp + 0x14], eax
xor eax, eax
mov dword [esp + 0xc], eax
mov dword [esp + 8], 1
mov dword [esp + 4], 0x80000000
mov eax, dword [ebp - 0x4f8]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_CreateFileA]
sub esp, 0x1c
mov dword [ebp - 0x4ec], eax
add eax, 1
je 0x402e21
lea eax, [ebp - 0x4e0]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x4ec]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_GetFileSizeEx]
push edi
push edi
test eax, eax
je 0x4034bc
mov eax, 0x186
cmp eax, dword [ebp - 0x4e0]
sbb ebx, dword [ebp - 0x4dc]
jge 0x4034bc
xor ebx, ebx
mov eax, dword [sym.imp.kernel32.dll_SetFilePointer]
xor esi, esi
mov dword [esp + 0xc], ebx
mov dword [esp + 8], ebx
mov dword [esp + 4], ebx
mov edi, dword [ebp - 0x4ec]
mov dword [esp], edi
mov dword [ebp - 0x50c], eax
call eax
lea eax, [ebp - 0x4e8]
sub esp, 0x10
mov dword [esp + 0xc], eax
mov eax, dword [sym.imp.kernel32.dll_ReadFile]
mov dword [esp + 0x10], esi
lea esi, [ebp - 0x184]
mov dword [esp + 8], 0x171
mov dword [esp + 4], esi
mov dword [esp], edi
mov dword [ebp - 0x4fc], eax
call eax
sub esp, 0x14
test eax, eax
je 0x403474
test byte [section..data], 8
jne 0x403324
xor ecx, ecx
mov dword [esp + 8], 0x16
lea eax, [ebp - 0x4e8]
mov dword [esp + 0x10], ecx
lea ebx, [ebp - 0x4c7]
mov dword [esp + 0xc], eax
mov dword [esp + 4], ebx
mov eax, dword [ebp - 0x4ec]
mov dword [esp], eax
mov eax, dword [ebp - 0x4fc]
call eax
sub esp, 0x14
mov dword [esp + 8], 0xf
mov dword [esp + 4], str.MICROSOFT_PIFEX
mov dword [esp], ebx
call sub.ucrtbase.dll_strncmp
mov dword [ebp - 0x4f4], eax
test eax, eax
jne 0x4032b9
movzx eax, word [ebp - 0x4b7]
test ax, ax
js 0x402ec2
lea edx, [eax + 0x16]
cmp dword [ebp - 0x4e0], edx
mov edx, dword [ebp - 0x4dc]
sbb edx, 0
jl 0x402ec2
xor edx, edx
mov dword [esp + 4], eax
mov dword [esp + 0xc], edx
mov dword [esp + 8], edx
mov edi, dword [ebp - 0x4ec]
mov dword [esp], edi
mov eax, dword [ebp - 0x50c]
call eax
sub esp, 0x10
test eax, eax
je 0x403474
xor eax, eax
mov dword [esp + 8], 0x16
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x4e8]
mov dword [esp + 0xc], eax
mov dword [esp + 4], ebx
mov dword [esp], edi
mov eax, dword [ebp - 0x4fc]
call eax
sub esp, 0x14
test eax, eax
je 0x403474
cmp byte [ebp - 0x4c7], 0
je 0x402d11
test byte [section..data], 8
jne 0x402e69
mov dword [esp + 8], 0xb
mov dword [esp + 4], str.WINDOWS_386
mov dword [esp], ebx
call sub.ucrtbase.dll_strncmp
test eax, eax
jne 0x402d11
xor eax, eax
mov dword [esp + 8], 0x68
mov dword [esp + 0x10], eax
lea eax, [ebp - 0x4e8]
mov dword [esp + 0xc], eax
lea eax, [ebp - 0x288]
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x4ec]
mov dword [esp], eax
mov eax, dword [ebp - 0x4fc]
call eax
sub esp, 0x14
test byte [section..data], 8
jne 0x403192
mov dword [ebp - 0x4f4], 1
jmp 0x402d11
test byte [section..data], 2
je 0x402b95
mov eax, dword [ebp - 0x4f8]
or edx, 0xffffffff
call fcn.00401270
mov dword [esp + 0xc], str.open_file__s_failed_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.pif_cmd
mov dword [esp + 4], 0x404000
mov dword [esp], 1
call fcn.004018b0
jmp 0x402b95
movzx ecx, word [ebp - 0x4b7]
or edx, 0xffffffff
mov eax, ebx
movzx edi, word [ebp - 0x4b3]
mov dword [ebp - 0x510], ecx
call fcn.00401270
mov ecx, dword [ebp - 0x510]
mov dword [esp + 0x14], edi
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.reading_record__s_size__d_next_0x_x_n
mov dword [esp + 8], 0x40650c
mov dword [esp + 0x18], ecx
mov dword [esp + 4], 0x404000
mov dword [esp], 3
call fcn.004018b0
jmp 0x402daf
lea eax, [ebp - 0x160]
mov dword [esp + 8], 0x40
mov dword [esp + 4], eax
lea eax, [ebp - 0x492]
mov dword [esp], eax
call section..text
lea eax, [ebp - 0x182]
sub esp, 0xc
mov dword [esp + 4], eax
lea eax, [ebp - 0x4b1]
mov dword [esp + 8], 0x1f
mov dword [esp], eax
call section..text
sub esp, 0xc
cmp dword [ebp - 0x4f4], 0
mov dword [esp + 8], 0x41
je 0x403106
lea eax, [ebp - 0x260]
mov dword [esp + 4], eax
lea eax, [ebp - 0x452]
mov dword [ebp - 0x4f4], eax
lea ebx, [ebp - 0x411]
mov dword [esp], eax
call section..text
lea eax, [ebp - 0x11f]
sub esp, 0xc
mov dword [esp + 8], 0x41
mov dword [esp + 4], eax
mov dword [esp], ebx
call section..text
movzx eax, word [ebp - 0x274]
sub esp, 0xc
and eax, 0x10
mov edi, eax
mov eax, dword [ebp - 0x4ec]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_CloseHandle]
push eax
lea eax, [ebp - 0x492]
mov dword [esp + 4], 0x2e
mov dword [esp], eax
mov eax, dword [ebp - 0x504]
call eax
test eax, eax
je 0x402fbe
mov dword [esp + 4], str..bat
mov dword [esp], eax
mov eax, dword [ebp - 0x508]
call eax
test eax, eax
jne 0x402fbe
test byte [section..data], 1
jne 0x403292
cmp byte [ebp - 0x411], 0
jne 0x4030a6
lea ebx, [ebp - 0x288]
xor eax, eax
mov dword [esp + 0xc], 0x104
mov dword [esp + 0x14], eax
xor eax, eax
mov dword [esp + 8], eax
lea eax, [ebp - 0x492]
mov dword [esp + 4], eax
xor eax, eax
mov dword [esp + 0x10], ebx
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_SearchPathA]
sub esp, 0x18
test eax, eax
je 0x403058
test edi, edi
jne 0x40303c
mov eax, dword [ebp - 0x500]
cmp byte [eax + 1], 0
jne 0x40302a
cmp byte [ebp - 0x452], 0
je 0x40302a
mov eax, dword [ebp - 0x4f4]
mov dword [ebp - 0x4f0], eax
mov edx, dword [ebp - 0x4f0]
mov eax, ebx
call fcn.004013b0
jmp 0x402b95
call dword [sym.imp.kernel32.dll_AllocConsole]
test eax, eax
je 0x403009
lea eax, [ebp - 0x4b1]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_SetConsoleTitleA]
push ecx
jmp 0x403009
mov eax, dword [ebp - 0x4f8]
xor ebx, ebx
mov dword [esp], esi
mov dword [esp + 4], str._s_nInvalid_program_file_name._Check_your_pif_file.
mov dword [esp + 8], eax
call fcn.004012e0
mov dword [esp + 0xc], 0x10
mov dword [esp + 8], str.16_bit_DOS_subsystem
mov dword [esp + 4], esi
mov dword [esp], ebx
call dword [sym.imp.user32.dll_MessageBoxA]
sub esp, 0x10
mov eax, dword fs:[0x18]
mov dword [eax + 0x34], 2
jmp 0x402b95
mov dword [esp], ebx
call dword [sym.imp.kernel32.dll_SetCurrentDirectoryA]
push edx
test eax, eax
jne 0x402fcb
test byte [section..data], 2
jne 0x40315b
mov eax, dword [ebp - 0x4f8]
mov dword [esp + 4], str._s_nInvalid_startup_directory._Check_your_pif_file.
mov dword [esp], esi
mov dword [esp + 8], eax
call fcn.004012e0
xor eax, eax
mov dword [esp + 4], esi
mov dword [esp + 0xc], 0x30
mov dword [esp + 8], str.16_bit_DOS_subsystem
mov dword [esp], eax
call dword [sym.imp.user32.dll_MessageBoxA]
sub esp, 0x10
jmp 0x402fcb
lea eax, [ebp - 0xdf]
mov dword [esp + 4], eax
lea eax, [ebp - 0x452]
mov dword [ebp - 0x4f4], eax
lea ebx, [ebp - 0x411]
mov dword [esp], eax
call section..text
lea eax, [ebp - 0x11f]
sub esp, 0xc
mov dword [esp + 8], 0x41
mov dword [esp + 4], eax
mov dword [esp], ebx
call section..text
movzx eax, byte [ebp - 0x121]
sub esp, 0xc
and eax, 2
mov edi, eax
jmp 0x402f6d
or edx, 0xffffffff
mov eax, ebx
call fcn.00401270
mov dword [esp + 0xc], str.Cannot_change_directory__s_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.pif_cmd
mov dword [esp + 4], 0x404000
mov dword [esp], 1
call fcn.004018b0
jmp 0x4030c5
movzx eax, word [ebp - 0x27c]
mov dword [esp + 0x24], eax
movzx eax, word [ebp - 0x27a]
mov dword [esp + 0x20], eax
movzx eax, word [ebp - 0x280]
mov dword [esp + 0x1c], eax
movzx eax, word [ebp - 0x27e]
mov dword [esp + 0x18], eax
movzx eax, word [ebp - 0x288]
mov dword [esp + 0x14], eax
movzx eax, word [ebp - 0x286]
mov dword [esp + 0xc], str.386rec:_memory_reqd__d_desd__d_EMS_reqd__d_desd__d_XMS_reqd__d_desd__d_n
mov dword [esp + 8], 0x40650c
mov dword [esp + 4], 0x404000
mov dword [esp + 0x10], eax
mov dword [esp], 3
call fcn.004018b0
test byte [section..data], 8
je 0x402e12
movzx eax, word [ebp - 0x274]
mov dword [esp + 0x18], eax
movzx eax, word [ebp - 0x276]
mov dword [esp + 0x14], eax
movzx eax, word [ebp - 0x278]
mov dword [esp + 0xc], str.386rec:_option_0x_x_memory_0x_x_video_0x_x_n
mov dword [esp + 8], 0x40650c
mov dword [esp + 4], 0x404000
mov dword [esp + 0x10], eax
mov dword [esp], 3
call fcn.004018b0
test byte [section..data], 8
je 0x402e12
or edx, 0xffffffff
lea eax, [ebp - 0x260]
call fcn.00401270
mov dword [esp + 0xc], str.386rec:_optional_parameters__s_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], 0x40650c
mov dword [esp + 4], 0x404000
mov dword [esp], 3
call fcn.004018b0
jmp 0x402e12
xor ecx, ecx
mov dword [esp + 0xc], str..bat_programs_in_pif_files_are_not_supported._n
mov dword [esp + 8], str.pif_cmd
mov dword [esp + 4], 0x404000
mov dword [esp], ecx
call fcn.004018b0
jmp 0x402fbe
test byte [section..data], 2
jne 0x403450
mov eax, dword [ebp - 0x4ec]
mov dword [esp], eax
call dword [sym.imp.kernel32.dll_CloseHandle]
push eax
mov eax, dword [ebp - 0x4f8]
mov dword [esp + 4], str._s_nInvalid_file_format._Check_your_pif_file.
mov dword [esp], esi
mov dword [esp + 8], eax
call fcn.004012e0
xor eax, eax
mov dword [esp + 4], esi
mov dword [esp + 0xc], 0x30
mov dword [esp + 8], str.16_bit_DOS_subsystem
mov dword [esp], eax
call dword [sym.imp.user32.dll_MessageBoxA]
sub esp, 0x10
mov eax, dword fs:[0x18]
mov dword [eax + 0x34], 0xb
jmp 0x402b95
lea eax, [ebp - 0xdf]
or edx, 0xffffffff
call fcn.00401270
or edx, 0xffffffff
mov ebx, eax
lea eax, [ebp - 0x11f]
call fcn.00401270
mov edx, 0x1e
mov edi, eax
lea eax, [ebp - 0x182]
call fcn.00401270
or edx, 0xffffffff
mov dword [ebp - 0x4f4], eax
lea eax, [ebp - 0x160]
call fcn.00401270
mov dword [esp + 0x1c], ebx
mov dword [esp + 0x18], edi
mov ebx, dword [ebp - 0x4f4]
mov dword [esp + 0x10], eax
mov dword [esp + 0xc], str.header:_program__s_title__s_startdir__s_params__s_n
mov dword [esp + 8], 0x40650c
mov dword [esp + 0x14], ebx
mov dword [esp + 4], 0x404000
mov dword [esp], 3
call fcn.004018b0
test byte [section..data], 8
je 0x402cb5
movzx eax, byte [ebp - 0x9f]
mov dword [esp + 0x1c], eax
movzx eax, byte [ebp - 0x120]
mov dword [esp + 0x18], eax
movzx eax, word [ebp - 0x164]
mov dword [esp + 0x14], eax
movzx eax, word [ebp - 0x162]
mov dword [esp + 0xc], str.header:_memory_reqd__d_desrd__d_drive__d_videomode__d_n
mov dword [esp + 8], 0x40650c
mov dword [esp + 4], 0x404000
mov dword [esp + 0x10], eax
mov dword [esp], 3
call fcn.004018b0
test byte [section..data], 8
je 0x402cb5
movzx eax, byte [ebp - 0x14]
mov dword [esp + 0x18], eax
movzx eax, byte [ebp - 0x15]
mov dword [esp + 0x14], eax
movzx eax, byte [ebp - 0x121]
mov dword [esp + 0xc], str.header:_flags_0x_x_0x_x_0x_x_n
mov dword [esp + 8], 0x40650c
mov dword [esp + 4], 0x404000
mov dword [esp + 0x10], eax
mov dword [esp], 3
call fcn.004018b0
jmp 0x402cb5
mov dword [esp + 0xc], str.Invalid_pif_file:_magic_string_not_found_n
mov dword [esp + 8], 0x40650c
mov dword [esp + 4], 0x404000
mov dword [esp], 1
call fcn.004018b0
test byte [section..data], 2
je 0x4032c6
mov eax, dword [ebp - 0x4f8]
or edx, 0xffffffff
call fcn.00401270
mov dword [esp + 0xc], str.failed_to_read__s_n
mov dword [esp + 0x10], eax
mov dword [esp + 8], str.pif_cmd
mov dword [esp + 4], 0x404000
mov dword [esp], 1
call fcn.004018b0
jmp 0x4032c6
test byte [section..data], 2
jne 0x4034d0
lea esi, [ebp - 0x184]
jmp 0x4032c6
mov eax, dword [ebp - 0x4e0]
mov dword [esp + 0xc], str.Invalid_pif_file:_size_error__d_n
lea esi, [ebp - 0x184]
mov dword [esp + 8], 0x40650c
mov dword [esp + 4], 0x404000
mov dword [esp], 1
mov dword [esp + 0x10], eax
call fcn.004018b0
jmp 0x403474