Function at 0x4042ad
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
push esi
push edi
push 8
call fcn.00405bbe
xor esi, esi
inc esi
cmp dword [0x41c664], esi
pop ecx
jne 0x4042d5
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_TerminateProcess]
cmp dword [ebp + 0xc], 0
mov al, byte [ebp + 0x10]
mov dword [0x41c660], esi
mov byte [0x41c65c], al
jne 0x40433b
mov ecx, dword [0x41de88]
test ecx, ecx
je 0x40431c
mov eax, dword [0x41de84]
sub eax, 4
cmp eax, ecx
jmp 0x404315
mov eax, dword [eax]
test eax, eax
je 0x404307
call eax
mov eax, dword [0x41de84]
sub eax, 4
cmp eax, dword [0x41de88]
mov dword [0x41de84], eax
jae 0x4042ff
mov eax, 0x419074
mov esi, 0x41907c
cmp eax, esi
mov edi, eax
jae 0x40433b
mov eax, dword [edi]
test eax, eax
je 0x404334
call eax
add edi, 4
cmp edi, esi
jb 0x40432c
mov eax, 0x419080
mov esi, 0x419088
cmp eax, esi
mov edi, eax
jae 0x40435a
mov eax, dword [edi]
test eax, eax
je 0x404353
call eax
add edi, 4
cmp edi, esi
jb 0x40434b
cmp dword [ebp + 0x10], 0
pop edi
pop esi
je 0x40436b
push 8
call fcn.00405b2a
jmp 0x40437d
push dword [ebp + 8]
mov dword [0x41c664], 1
call fcn.00404206
pop ecx
pop ebp
ret

Function at 0x4067e7
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10c
mov eax, dword [0x4197d0]
xor eax, dword [ebp + 4]
mov ecx, dword [ebp + 8]
push ebx
push esi
mov dword [ebp - 4], eax
xor edx, edx
push edi
xor eax, eax
cmp ecx, dword [eax*8 + 0x419bb8]
je 0x406814
inc eax
cmp eax, 0x12
jb 0x406805
mov esi, eax
shl esi, 3
cmp ecx, dword [esi + 0x419bb8]
jne 0x406948
mov eax, dword [0x41c61c]
cmp eax, 1
je 0x406923
cmp eax, edx
jne 0x406844
cmp dword [0x4197c4], 1
je 0x406923
cmp ecx, 0xfc
je 0x406948
push 0x104
lea eax, [ebp - 0x10c]
push eax
push edx
mov byte [ebp - 8], dl
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x40687d
lea eax, [ebp - 0x10c]
push str._program_name_unknown_
push eax
call fcn.00407f40
pop ecx
pop ecx
lea eax, [ebp - 0x10c]
push eax
lea edi, [ebp - 0x10c]
call fcn.00403f40
inc eax
cmp eax, 0x3c
pop ecx
jbe 0x4068bf
lea eax, [ebp - 0x10c]
push eax
call fcn.00403f40
mov edi, eax
lea eax, [ebp - 0x10c]
sub eax, 0x3b
push 3
add edi, eax
push 0x415c48
push edi
call fcn.004091e0
add esp, 0x10
push edi
call fcn.00403f40
push dword [esi + 0x419bbc]
mov ebx, eax
call fcn.00403f40
lea eax, [ebx + eax + 0x1c]
pop ecx
add eax, 3
pop ecx
and eax, 0xfffffffc
call fcn.004037a0
mov ebx, esp
push str.Runtime_Error__n_nProgram:
push ebx
call fcn.00407f40
push edi
push ebx
call fcn.00407f50
push 0x415c28
push ebx
call fcn.00407f50
push dword [esi + 0x419bbc]
push ebx
call fcn.00407f50
push 0x12010
push str.Microsoft_Visual_C_Runtime_Library
push ebx
call fcn.004090e4
add esp, 0x2c
jmp 0x406948
push edx
lea eax, [ebp + 8]
push eax
lea esi, [esi + 0x419bbc]
push dword [esi]
call fcn.00403f40
pop ecx
push eax
push dword [esi]
push 0xfffffffffffffff4
call dword [sym.imp.KERNEL32.dll_GetStdHandle]
push eax
call dword [sym.imp.KERNEL32.dll_WriteFile]
lea esp, [ebp - 0x118]
mov ecx, dword [ebp - 4]
xor ecx, dword [ebp + 4]
call fcn.00403ede
pop edi
pop esi
pop ebx
leave
ret