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

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x54
push ebx
push esi
push edi
mov ebx, edx
mov dword [ebp - 8], ecx
xorps xmm0, xmm0
mov dword [ebp - 0x18], ebx
push 0x100000
mov dword [ebp - 0xc], 0
movlpd qword [ebp - 0x20], xmm0
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov esi, eax
add esp, 4
test esi, esi
jne 0x405d33
push str.____out_of_memory__aborting_n
push 2
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
push eax
call fcn.00401010
add esp, 8
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_abort]
push 0x44af34
lea eax, [ebp - 0xc]
push ebx
push eax
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fopen_s]
add esp, 0xc
test eax, eax
jne 0x405d67
mov eax, dword [ebp - 0xc]
test eax, eax
je 0x405d67
mov edi, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
push eax
push 0x63
push 1
push esi
call edi
add esp, 0x10
cmp eax, 0x63
jae 0x405d7c
push ebx
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_perror]
add esp, 4
mov edi, dword [ebp - 0x1c]
mov ebx, dword [ebp - 0x20]
jmp 0x406192
mov ecx, esi
mov edx, str.segscan_1.1
mov ebx, 7
nop dword [eax + eax]
mov eax, dword [ecx]
cmp eax, dword [edx]
jne 0x4061d3
add ecx, 4
add edx, 4
sub ebx, 4
jae 0x405d90
mov ax, word [ecx]
cmp ax, word [edx]
jne 0x4061d3
mov al, byte [ecx + 2]
cmp al, byte [edx + 2]
jne 0x4061d3
cmp byte [esi + 0xb], 0x2e
jne 0x405e2b
mov ebx, dword [sym.imp.api_ms_win_crt_convert_l1_1_0.dll_strtoul]
lea eax, [esi + 0xc]
push 0
push 0
push eax
call ebx
add esp, 0xc
cmp eax, 2
jb 0x405e2b
xor ecx, ecx
nop dword [eax]
mov al, byte [esi + ecx]
test al, al
je 0x405df1
cmp al, 0xa
je 0x405df1
inc ecx
cmp ecx, 0x61
jb 0x405de0
mov eax, ecx
inc ecx
cmp byte [esi + ecx], 0x73
cmovne ecx, eax
cmp byte [ecx + esi + 1], 0x3a
lea eax, [ecx + 1]
cmovne eax, ecx
inc eax
cmp eax, 0x61
jae 0x405e2b
push 0
add eax, esi
push 0
push eax
call ebx
mov ecx, dword [ebp - 8]
add esp, 0xc
mov dword [ecx + 0x218], eax
mov dword [ecx + 0x21c], 0
push dword [ebp - 0xc]
push 1
push 1
push esi
call edi
add esp, 0x10
cmp eax, 1
jne 0x405d71
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x10], eax
mov eax, dword [ebp - 0x20]
mov dword [ebp - 0x14], eax
nop dword [eax]
mov al, byte [esi]
movzx ebx, al
and ebx, 0x7f
test al, al
jns 0x405e83
nop dword [eax]
push dword [ebp - 0xc]
push 1
push 1
push esi
call edi
add esp, 0x10
cmp eax, 1
jne 0x405e83
mov cl, byte [esi]
movzx eax, cl
and eax, 0x7f
shl ebx, 7
or ebx, eax
test cl, cl
js 0x405e60
push dword [ebp - 0xc]
push 1
push 1
push esi
call edi
add esp, 0x10
cmp eax, 1
jne 0x40618c
mov al, byte [esi]
movzx edi, al
and edi, 0x7f
test al, al
jns 0x405ecc
push dword [ebp - 0xc]
push 1
push 1
push esi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
add esp, 0x10
cmp eax, 1
jne 0x405ecc
mov cl, byte [esi]
movzx eax, cl
and eax, 0x7f
shl edi, 7
or edi, eax
test cl, cl
js 0x405ea5
cmp edi, 0x100000
ja 0x4061b8
push dword [ebp - 0xc]
push edi
push 1
push esi
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
mov edx, eax
add esp, 0x10
mov dword [ebp - 0x1c], edx
cmp edx, edi
jb 0x40618c
lea eax, [ebx - 1]
cmp eax, 0x6c
ja case.0x405f08.8
movzx ecx, byte [eax + 0x40622c]
jmp dword [ecx*4 + 0x4061f8]
mov eax, dword [ebp + 0xc]
cmp dword [eax + 4], 0
jne case.0x405f08.109
mov ecx, dword [ebp - 8]
push edx
push esi
mov edx, 1
call fcn.004051e0
add esp, 8
jmp case.0x405f08.109
mov eax, dword [ebp + 0xc]
cmp dword [eax + 4], 0
jne case.0x405f08.109
mov ecx, dword [ebp - 8]
push edx
push esi
mov edx, 2
call fcn.004051e0
add esp, 8
jmp case.0x405f08.109
movzx edi, byte [esi]
movzx eax, byte [esi + 1]
movzx ecx, byte [esi + 4]
mov ebx, dword [ebp - 8]
shl edi, 8
or edi, eax
shl ecx, 8
movzx eax, byte [esi + 2]
shl edi, 8
or edi, eax
mov byte [ebp - 0x38], 4
movzx eax, byte [esi + 3]
shl edi, 8
or edi, eax
movzx eax, byte [esi + 5]
or ecx, eax
movzx eax, byte [esi + 6]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 7]
shl ecx, 8
or ecx, eax
mov al, byte [esi + 8]
mov byte [ebp - 1], al
mov al, byte [esi + 9]
mov dword [ebp - 0x48], ecx
movzx ecx, byte [esi + 0xa]
mov byte [ebp - 2], al
movzx eax, byte [esi + 0xb]
shl ecx, 8
or ecx, eax
mov eax, dword [ebx + 0x218]
or eax, dword [ebx + 0x21c]
jne 0x405fd1
mov dword [ebx + 0x218], edi
mov dword [ebx + 0x21c], eax
movups xmm0, xmmword [ebp - 0x48]
lea eax, [edx - 0xc]
push eax
lea eax, [esi + 0xc]
push eax
movzx eax, byte [ebp - 2]
push 0
push ecx
movzx ecx, byte [ebp - 1]
shl ecx, 8
or ecx, eax
push ecx
push 6
sub esp, 0x18
mov eax, esp
push 0
movups xmmword [eax], xmm0
push edi
movq xmm0, qword [ebp - 0x38]
push ebx
movq qword [eax + 0x10], xmm0
call fcn.00431390
add esp, 0x3c
jmp case.0x405f08.109
push dword [ebp - 0xc]
mov edi, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
lea eax, [esi + edx]
push 1
push 1
push eax
call edi
add esp, 0x10
cmp eax, 1
jne 0x406151
mov eax, dword [ebp - 0x1c]
mov edx, esi
mov ecx, dword [ebp - 8]
inc eax
push eax
call fcn.00405a30
add esp, 4
jmp 0x406101
mov ecx, dword [ebp - 8]
push edx
mov edx, esi
call fcn.00405a30
add esp, 4
jmp case.0x405f08.109
mov eax, dword [ebp + 0xc]
cmp dword [eax + 4], 0
jne case.0x405f08.109
push dword [ebp + 8]
mov ecx, dword [ebp - 8]
push edx
push esi
mov edx, 1
call fcn.00405340
jmp 0x4060f8
mov eax, dword [ebp + 0xc]
cmp dword [eax + 4], 0
jne case.0x405f08.109
push dword [ebp + 8]
mov ecx, dword [ebp - 8]
push edx
push esi
mov edx, 2
call fcn.00405340
jmp 0x4060f8
push dword [ebp + 0xc]
mov ecx, dword [ebp - 8]
push dword [ebp + 8]
push edx
mov edx, esi
call fcn.00405b20
jmp 0x4060f8
mov eax, dword [ebp + 0xc]
cmp dword [eax + 4], 0
jne case.0x405f08.109
push dword [ebp + 8]
mov ecx, dword [ebp - 8]
push edx
push esi
mov edx, 1
call fcn.00405570
jmp 0x4060f8
mov eax, dword [ebp + 0xc]
cmp dword [eax + 4], 0
jne case.0x405f08.109
push dword [ebp + 8]
mov ecx, dword [ebp - 8]
push edx
push esi
mov edx, 2
call fcn.00405570
jmp 0x4060f8
push dword [ebp + 0xc]
mov ecx, dword [ebp - 8]
push dword [ebp + 8]
push edx
mov edx, esi
call fcn.004057a0
add esp, 0xc
mov edi, dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fread]
mov ebx, dword [ebp - 0x14]
mov ecx, dword [ebp - 0x10]
add ebx, 1
movzx eax, bx
adc ecx, 0
mov dword [ebp - 0x14], ebx
or eax, 0
mov dword [ebp - 0x10], ecx
jne 0x406139
push ecx
push ebx
push dword [ebp - 0x18]
push str._s:__8llu_r
push 2
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
push eax
call fcn.00401010
add esp, 0x14
push dword [ebp - 0xc]
push 1
push 1
push esi
call edi
add esp, 0x10
cmp eax, 1
je 0x405e50
jmp 0x40618f
push str.read___error_n
push 2
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
push eax
call fcn.00401010
add esp, 8
push 1
call dword [sym.imp.api_ms_win_crt_runtime_l1_1_0.dll_exit]
push ebx
push str.file_corrupt:_unknown_type__u_n
push 2
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
push eax
call fcn.00401010
add esp, 0xc
mov ebx, dword [ebp - 0x14]
mov edi, dword [ebp - 0x10]
push esi
call dword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov ecx, dword [ebp - 0xc]
add esp, 4
test ecx, ecx
je 0x4061ad
push ecx
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
add esp, 4
mov edx, edi
mov eax, ebx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push str.file_corrupt_n
push 2
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
push eax
call fcn.00401010
add esp, 8
jmp 0x40618c
push dword [ebp - 0x18]
push str._s:_unknown_file_format__expeced__segscan_1.1___n
push 2
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
push eax
call fcn.00401010
mov edi, dword [ebp - 0x1c]
add esp, 0xc
mov ebx, dword [ebp - 0x20]
jmp 0x406192