Function at 0x4036ee
Capabilities:
Terminate process

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x25c
mov dword [ebp - 0x12c], 0
mov dword [ebp - 8], 0
xor eax, eax
mov al, byte [0x40f092]
test eax, eax
je 0x403724
call fcn.00404414
mov dword [ebp - 0x254], eax
mov dword [ebp - 0x250], edx
mov ecx, dword [ebp + 8]
push ecx
lea edx, [ebp - 0x24c]
push edx
call sub.MSVCRTD.dll_strcpy
add esp, 8
push 0x40d0d8
lea eax, [ebp - 0x24c]
push eax
call sub.MSVCRTD.dll_strcat
add esp, 8
mov ecx, dword [ebp + 0xc]
push ecx
lea edx, [ebp - 0x24c]
push edx
call sub.MSVCRTD.dll_strcat
add esp, 8
push 0x40d0e0
lea eax, [ebp - 0x24c]
push eax
call sub.MSVCRTD.dll_strcat
add esp, 8
push 0x40d0ec
lea ecx, [ebp - 0x24c]
push ecx
call dword [sym.imp.MSVCRTD.dll_fopen]
add esp, 8
mov dword [ebp - 4], eax
cmp dword [ebp - 4], 0
jne 0x4037c3
mov edx, dword [ebp + 0x10]
and edx, 0xff
test edx, edx
jne 0x4037bb
push 1
lea eax, [ebp - 0x24c]
push eax
push 0x40d0f0
call fcn.004044e8
add esp, 0xc
push 1
call dword [sym.imp.MSVCRTD.dll_exit]
or eax, 0xffffffff
jmp 0x403c65
mov ecx, dword [ebp - 4]
push ecx
push 0x118
lea edx, [ebp - 0x120]
push edx
call dword [sym.imp.MSVCRTD.dll_fgets]
add esp, 0xc
test eax, eax
je 0x403bf9
mov dword [ebp - 0x258], 0xffffffff
mov eax, dword [ebp - 8]
add eax, 1
mov dword [ebp - 8], eax
movsx ecx, byte [ebp - 0x120]
cmp ecx, 0x23
jne 0x403805
jmp 0x4037c3
movsx edx, byte [ebp - 0x120]
cmp edx, 0x2d
je 0x403834
lea eax, [ebp - 0x24c]
push eax
mov ecx, dword [ebp - 8]
push ecx
push 0x40d10c
mov edx, dword [sym.imp.MSVCRTD.dll__iob]
add edx, 0x40
push edx
call dword [sym.imp.MSVCRTD.dll_fprintf]
add esp, 0x10
mov eax, dword [ebp - 0x12c]
cmp eax, dword [0x40f09c]
jl 0x403851
mov ecx, dword [ebp - 0x12c]
push ecx
call fcn.00403c69
add esp, 4
lea edx, [ebp - 0x120]
push edx
call sub.MSVCRTD.dll_strlen
add esp, 4
mov byte [ebp + eax - 0x121], 0
mov eax, dword [0x40d0d0]
push eax
lea ecx, [ebp - 0x120]
push ecx
call dword [sym.imp.MSVCRTD.dll_strcspn]
add esp, 8
lea edx, [ebp + eax - 0x120]
mov dword [ebp - 0x134], edx
mov eax, dword [ebp - 0x134]
movsx ecx, byte [eax]
test ecx, ecx
jne 0x4038c0
lea edx, [ebp - 0x24c]
push edx
mov eax, dword [ebp - 8]
push eax
push 0x40d138
mov ecx, dword [sym.imp.MSVCRTD.dll__iob]
add ecx, 0x40
push ecx
call dword [sym.imp.MSVCRTD.dll_fprintf]
add esp, 0x10
jmp 0x403af5
mov edx, dword [ebp - 0x134]
mov byte [edx], 0
mov eax, dword [ebp - 0x134]
add eax, 1
mov dword [ebp - 0x134], eax
mov ecx, dword [0x40d0d0]
push ecx
mov edx, dword [ebp - 0x134]
push edx
call dword [sym.imp.MSVCRTD.dll_strspn]
add esp, 8
mov ecx, dword [ebp - 0x134]
add ecx, eax
mov dword [ebp - 0x134], ecx
mov edx, dword [ebp - 0x134]
movsx eax, byte [edx]
test eax, eax
jne 0x403931
lea ecx, [ebp - 0x24c]
push ecx
mov edx, dword [ebp - 8]
push edx
push 0x40d168
mov eax, dword [sym.imp.MSVCRTD.dll__iob]
add eax, 0x40
push eax
call dword [sym.imp.MSVCRTD.dll_fprintf]
add esp, 0x10
jmp 0x403af5
push 0x40d198
call sub.MSVCRTD.dll_strlen
add esp, 4
push eax
push 0x40d1a0
mov ecx, dword [ebp - 0x134]
push ecx
call dword [sym.imp.MSVCRTD.dll_strncmp]
add esp, 0xc
test eax, eax
jne 0x403967
mov dword [ebp - 0x258], 0
jmp 0x403af5
push 0x40d1a8
call sub.MSVCRTD.dll_strlen
add esp, 4
push eax
push 0x40d1b4
mov edx, dword [ebp - 0x134]
push edx
call dword [sym.imp.MSVCRTD.dll_strncmp]
add esp, 0xc
test eax, eax
jne 0x403a62
mov eax, dword [0x40d0d0]
push eax
mov ecx, dword [ebp - 0x134]
push ecx
call dword [sym.imp.MSVCRTD.dll_strcspn]
add esp, 8
mov edx, dword [ebp - 0x134]
add edx, eax
mov dword [ebp - 0x134], edx
mov eax, dword [ebp - 0x134]
movsx ecx, byte [eax]
test ecx, ecx
je 0x4039e8
mov edx, dword [0x40d0d0]
push edx
mov eax, dword [ebp - 0x134]
push eax
call dword [sym.imp.MSVCRTD.dll_strspn]
add esp, 8
mov ecx, dword [ebp - 0x134]
add ecx, eax
mov dword [ebp - 0x134], ecx
mov edx, dword [ebp - 0x134]
movsx eax, byte [edx]
test eax, eax
jne 0x403a19
lea ecx, [ebp - 0x24c]
push ecx
mov edx, dword [ebp - 8]
push edx
push 0x40d1c0
mov eax, dword [sym.imp.MSVCRTD.dll__iob]
add eax, 0x40
push eax
call dword [sym.imp.MSVCRTD.dll_fprintf]
add esp, 0x10
jmp 0x403a5d
mov ecx, dword [ebp - 0x134]
mov dword [ebp - 0x130], ecx
mov edx, dword [0x40d0d0]
push edx
mov eax, dword [ebp - 0x134]
push eax
call dword [sym.imp.MSVCRTD.dll_strcspn]
add esp, 8
mov ecx, dword [ebp - 0x134]
add ecx, eax
mov dword [ebp - 0x134], ecx
mov edx, dword [ebp - 0x134]
mov byte [edx], 0
mov dword [ebp - 0x258], 1
jmp 0x403af5
push 0x40d1f0
call sub.MSVCRTD.dll_strlen
add esp, 4
push eax
push 0x40d1f8
mov eax, dword [ebp - 0x134]
push eax
call dword [sym.imp.MSVCRTD.dll_strncmp]
add esp, 0xc
test eax, eax
jne 0x403a95
mov dword [ebp - 0x258], 2
jmp 0x403af5
push 0x40d200
call sub.MSVCRTD.dll_strlen
add esp, 4
push eax
push 0x40d208
mov ecx, dword [ebp - 0x134]
push ecx
call dword [sym.imp.MSVCRTD.dll_strncmp]
add esp, 0xc
test eax, eax
jne 0x403ac8
mov dword [ebp - 0x258], 3
jmp 0x403af5
lea edx, [ebp - 0x24c]
push edx
mov eax, dword [ebp - 8]
push eax
push 0x40d210
mov ecx, dword [sym.imp.MSVCRTD.dll__iob]
add ecx, 0x40
push ecx
call dword [sym.imp.MSVCRTD.dll_fprintf]
add esp, 0x10
mov dword [ebp - 0x258], 0
xor edx, edx
mov dl, byte [0x40f092]
test edx, edx
je 0x403b1d
lea eax, [ebp - 0x120]
push eax
mov ecx, dword [ebp - 0x12c]
push ecx
push 0x40d240
call dword [sym.imp.MSVCRTD.dll_printf]
add esp, 0xc
cmp dword [ebp - 0x258], 0xffffffff
je 0x403bf4
lea edx, [ebp - 0x120]
push edx
call dword [sym.imp.MSVCRTD.dll__strdup]
add esp, 4
mov ecx, dword [ebp - 0x12c]
imul ecx, ecx, 0xc
mov edx, dword [0x40f094]
mov dword [edx + ecx], eax
mov eax, dword [ebp - 0x12c]
imul eax, eax, 0xc
mov ecx, dword [0x40f094]
mov edx, dword [ebp - 0x258]
mov dword [ecx + eax + 4], edx
mov eax, dword [ebp - 0x258]
mov dword [ebp - 0x25c], eax
cmp dword [ebp - 0x25c], 1
je 0x403b7c
jmp 0x403be5
mov ecx, dword [ebp - 0x130]
push ecx
call dword [sym.imp.MSVCRTD.dll__strdup]
add esp, 4
mov edx, dword [ebp - 0x12c]
imul edx, edx, 0xc
mov ecx, dword [0x40f094]
mov dword [ecx + edx + 8], eax
xor edx, edx
mov dl, byte [0x40f092]
test edx, edx
je 0x403be5
mov eax, dword [ebp - 0x12c]
imul eax, eax, 0xc
mov ecx, dword [0x40f094]
mov edx, dword [ecx + eax + 8]
push edx
push 0x40d258
mov eax, dword [ebp - 0x12c]
imul eax, eax, 0xc
mov ecx, dword [0x40f094]
mov edx, dword [ecx + eax]
push edx
push 0x40d268
call dword [sym.imp.MSVCRTD.dll_printf]
add esp, 0x10
mov eax, dword [ebp - 0x12c]
add eax, 1
mov dword [ebp - 0x12c], eax
jmp 0x4037c3
mov ecx, dword [ebp - 4]
push ecx
call dword [sym.imp.MSVCRTD.dll_fclose]
add esp, 4
mov edx, dword [ebp - 0x12c]
mov dword [0x40f098], edx
xor eax, eax
mov al, byte [0x40f092]
test eax, eax
je 0x403c5f
call fcn.00404414
mov dword [ebp - 0x128], eax
mov dword [ebp - 0x124], edx
mov ecx, dword [ebp - 0x128]
sub ecx, dword [ebp - 0x254]
mov edx, dword [ebp - 0x124]
sbb edx, dword [ebp - 0x250]
push edx
push ecx
call fcn.00404462
add esp, 8
push eax
push 0x40d290
call dword [sym.imp.MSVCRTD.dll_printf]
add esp, 8
mov eax, dword [ebp - 0x12c]
mov esp, ebp
pop ebp
ret