Function at 0x40b3e0
Capabilities:
Read file on windows
Terminate process

Disassembly:
push 0xffffffffffffffff
push 0x411cca
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x48
xor eax, eax
push ebx
mov dword [esp + 0x29], eax
push ebp
mov dword [esp + 0x31], eax
mov ebp, ecx
mov dword [esp + 0x35], eax
push esi
mov word [esp + 0x3d], ax
push edi
lea ecx, [esp + 0x10]
mov byte [esp + 0x34], 0
mov byte [esp + 0x43], al
call sub.MFC42u.DLL_CString::CString_3
xor ecx, ecx
mov ebx, dword [sym.imp.MSVCRT.dll_calloc]
mov dword [esp + 0x45], ecx
xor esi, esi
mov dword [esp + 0x49], ecx
push 1
mov dword [esp + 0x51], ecx
push 0x104
mov dword [esp + 0x59], ecx
mov dword [esp + 0x68], esi
mov word [esp + 0x5d], cx
mov byte [esp + 0x4c], 0
mov byte [esp + 0x5f], cl
call ebx
mov edi, eax
add esp, 8
cmp edi, esi
mov dword [esp + 0x1c], edi
jne 0x40b477
push esi
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
push 1
call dword [sym.imp.MSVCRT.dll_exit]
push 1
push 0x104
call ebx
add esp, 8
cmp eax, esi
mov dword [esp + 0x30], eax
jne 0x40b49d
push esi
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
push 1
call dword [sym.imp.MSVCRT.dll_exit]
mov eax, dword [ebp + 0x1a68]
dec eax
je 0x40b4c4
dec eax
je 0x40b4b8
dec eax
jne 0x40b4ce
mov dword [ebp + 0x1ad4], 0x1f4
jmp 0x40b4ce
mov dword [ebp + 0x1ad4], 0x400
jmp 0x40b4ce
mov dword [ebp + 0x1ad4], 0x1000
push 2
mov ecx, ebp
call fcn.0040c3c0
cmp dword [ebp + 0x1a9c], esi
jne 0x40b7c2
lea edx, [ebp + 0x327e]
push 0x41a4a8
mov eax, dword [edx]
mov dword [esp + 0x38], eax
mov ecx, dword [edx + 4]
mov dword [esp + 0x3c], ecx
mov eax, dword [edx + 8]
mov dword [esp + 0x40], eax
mov ecx, dword [edx + 0xc]
mov dword [esp + 0x44], ecx
lea ecx, [esp + 0x14]
call sub.MFC42u.DLL_CString::operator_2
mov eax, dword [ebp + 0x1c80]
mov dword [esp + 0x28], esi
cmp eax, esi
jbe 0x40b7b8
lea ebx, [esp + 0x36]
mov dword [esp + 0x20], esi
mov dword [esp + 0x24], ebx
mov ecx, ebp
call fcn.00407980
mov esi, eax
test esi, esi
mov dword [esp + 0x2c], esi
je 0x40b7e6
mov edx, dword [ebp + 0x1c84]
mov ecx, dword [esp + 0x20]
add edx, ecx
push 0
push edx
push esi
call dword [sym.imp.MSVCRT.dll_fseek]
push esi
push 0x18
push 1
push edi
call dword [sym.imp.MSVCRT.dll_fread]
lea eax, [ebp + 0x1d0c]
mov esi, edi
mov ecx, 6
mov edi, eax
add esp, 0x1c
lea eax, [ebx - 2]
rep movsd dword es:[edi], dword [esi]
push eax
mov ecx, ebp
call fcn.00406150
push ebx
mov ecx, ebp
mov esi, eax
call fcn.00406150
cmp word [ebp + 0x1d10], si
jne 0x40b5a6
cmp word [ebp + 0x1d12], ax
je 0x40b78b
push 0x40
call sub.MFC42u.DLL_operatornew
add esp, 4
mov dword [esp + 0x18], eax
test eax, eax
mov byte [esp + 0x60], 1
je 0x40b5ca
mov ecx, eax
call sub.MFC42u.DLL_CWnd::CWnd
mov dword [esp + 0x18], eax
jmp 0x40b5d2
mov dword [esp + 0x18], 0
mov ecx, dword [esp + 0x18]
push 1
lea ebx, [ebp + 0x1ae8]
push str.Simulator
push ecx
mov ecx, ebx
mov byte [esp + 0x6c], 0
call fcn.0040f310
push 0
mov ecx, ebx
call fcn.0040fa60
mov edx, dword [0x41a8a4]
push edx
push ebx
call fcn.0040fb70
mov ecx, dword [ebp + 0x1d18]
mov esi, dword [esp + 0x34]
mov eax, dword [ebp + 0x1d14]
add esp, 8
mov dword [ebp + 0x1ac0], ecx
mov ecx, ebp
push esi
mov dword [ebp + 0x1acc], eax
call fcn.00406060
push esi
mov dword [ebp + 0x1ad0], eax
call dword [sym.imp.MSVCRT.dll_fclose]
push 2
push 0x104
call dword [sym.imp.MSVCRT.dll_calloc]
mov edx, dword [ebp + 0x1d0c]
push 0xa
push eax
push edx
call dword [sym.imp.MSVCRT.dll__itow]
add esp, 0x18
lea ecx, [esp + 0x10]
push eax
push 9
call sub.MFC42u.DLL_CString::Insert
lea eax, [esp + 0x10]
lea ecx, [esp + 0x14]
push eax
call sub.MFC42u.DLL_CString::CString_2
push 0x14
lea ecx, [esp + 0x18]
mov byte [esp + 0x64], 2
call sub.MFC42u.DLL_CString::GetBuffer
push 0xffffffffffffffff
lea ecx, [esp + 0x18]
mov esi, eax
call sub.MFC42u.DLL_CString::ReleaseBuffer
push 0
push 0
lea ecx, [esp + 0x4c]
push 0x14
push ecx
push 0xffffffffffffffff
push esi
push 0x200
push 0
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
test eax, eax
je 0x40b7f2
lea edi, [esp + 0x44]
or ecx, 0xffffffff
xor eax, eax
mov edx, dword [esp + 0x30]
repne scasb al, byte es:[edi]
not ecx
dec ecx
lea esi, [esp + 0x44]
mov eax, ecx
mov edi, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
xor eax, eax
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x10]
mov ecx, dword [ecx - 8]
test ecx, ecx
mov dword [ebp + 0x1ac4], ecx
jle 0x40b702
mov cl, byte [eax + edx]
mov byte [eax + ebp + 0x46c8], cl
mov ecx, dword [ebp + 0x1ac4]
inc eax
cmp eax, ecx
jl 0x40b6ed
push 0x41a4a8
lea ecx, [esp + 0x14]
call sub.MFC42u.DLL_CString::operator_2
mov ecx, dword [ebp + 0x1ad4]
mov edx, dword [ebp + 0x1acc]
push 1
lea eax, [edx + ecx - 1]
cdq
idiv ecx
mov ecx, ebx
add eax, 2
mov dword [ebp + 0x1ad8], eax
add eax, 0xfffffffe
push eax
push 0
call fcn.0040f9c0
mov eax, dword [ebp + 0x1acc]
test eax, eax
je 0x40b7fe
mov ecx, ebp
call fcn.0040b860
mov eax, dword [ebp + 0x1a9c]
test eax, eax
jne 0x40b80f
mov eax, dword [esp + 0x18]
test eax, eax
je 0x40b769
mov eax, dword [eax + 0x20]
push eax
call sub.MFC42u.DLL_operatordelete
mov eax, dword [ebx]
add esp, 4
mov ecx, ebx
call dword [eax + 0x60]
lea ecx, [esp + 0x14]
mov byte [esp + 0x60], 0
call sub.MFC42u.DLL_CString::CString
mov ebx, dword [esp + 0x24]
mov eax, dword [esp + 0x28]
mov edx, dword [esp + 0x20]
mov ecx, dword [ebp + 0x1c80]
mov edi, dword [esp + 0x1c]
add ebx, 4
inc eax
add edx, 0x18
cmp eax, ecx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x28], eax
mov dword [esp + 0x20], edx
jb 0x40b530
push edi
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
lea ecx, [esp + 0x10]
mov dword [esp + 0x60], 0xffffffff
call sub.MFC42u.DLL_CString::CString
mov ecx, dword [esp + 0x58]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x54
ret
mov dword [ebp + 0x1a9c], 7
jmp 0x40b7b8
mov dword [ebp + 0x1a9c], 5
jmp 0x40b840
mov ecx, dword [esp + 0x1c]
mov dword [ebp + 0x1a9c], 5
push ecx
jmp 0x40b814
mov eax, dword [esp + 0x1c]
push eax
call dword [sym.imp.MSVCRT.dll_free]
mov eax, dword [esp + 0x1c]
add esp, 4
test eax, eax
je 0x40b828
mov eax, dword [eax + 0x20]
push eax
call sub.MFC42u.DLL_operatordelete
mov edx, dword [ebp + 0x1ae8]
lea ecx, [ebp + 0x1ae8]
add esp, 4
call dword [edx + 0x60]
lea ecx, [esp + 0x14]
mov byte [esp + 0x60], 0
call sub.MFC42u.DLL_CString::CString
jmp 0x40b7c2