Function at 0x4037a0
Capabilities:
Read file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x88
mov rax, qword [0x00502630]
mov qword [rsp + 0x38], rcx
mov r12d, edx
mov byte [rsp + 0x37], r8b
mov ecx, dword [rax + 0x1358]
test ecx, ecx
jne 0x403ee0
mov rcx, qword [rsp + 0x38]
xor r8d, r8d
xor edx, edx
call sub.msvcrt.dll__open_1
test eax, eax
mov edi, eax
js 0x403f00
lea rdx, [rsp + 0x40]
mov rcx, qword [rsp + 0x38]
call qword [sym.imp.msvcrt.dll__stat64]
test eax, eax
js 0x403f00
mov rax, qword [rsp + 0x58]
lea rcx, [rax + 1]
call fcn.0047c0a6
mov r8d, dword [rsp + 0x58]
mov rdx, rax
mov ecx, edi
mov rsi, rax
call sub.msvcrt.dll__read_1
test eax, eax
mov ebx, eax
js 0x403f00
cdqe
mov ecx, edi
mov byte [rsi + rax], 0
call sub.msvcrt.dll__close_1
lea ecx, [rbx + 1]
movsxd rcx, ecx
call fcn.0047c0a6
mov rbx, rax
mov rcx, rax
mov rax, rsi
jmp 0x40385f
mov byte [rcx], dl
add rcx, 1
add rax, 1
je 0x403883
movzx edx, byte [rax]
test dl, dl
je 0x403883
cmp dl, 0xd
jne 0x403853
cmp rsi, rax
jae 0x403876
cmp byte [rax - 1], 0xa
je 0x403859
cmp byte [rax + 1], 0xa
je 0x403859
mov edx, 0xa
jmp 0x403853
mov byte [rcx], 0
mov r14, rbx
mov rcx, rsi
call fcn.00494cb8
mov rcx, r14
call fcn.00401560
movzx edx, byte [rax]
test dl, dl
je 0x403b22
cmp dl, 0x25
jne 0x4038b1
test r12b, r12b
mov r14, rax
je 0x403908
cmp dl, 0x3a
mov rsi, rax
jne 0x4038d8
jmp 0x403a09
add rsi, 1
movzx edx, byte [rsi]
test dl, dl
je 0x403a00
cmp dl, 0x3a
je 0x403a00
cmp dl, 0xa
jne 0x4038c0
mov r8d, esi
mov rax, qword [0x00502670]
lea rdx, str.specs_file_malformed_after__ld_characters
sub r8d, ebx
mov ecx, dword [rax]
call fcn.00426b60
nop dword [rax + rax]
cmp dl, 0xa
je 0x403915
mov r14, r9
movzx edx, byte [r14 + 1]
lea r9, [r14 + 1]
test dl, dl
jne 0x403900
lea rdi, [0x0049c50f]
mov ecx, 8
mov rsi, rax
add r14, 2
repe cmpsb byte [rsi], byte [rdi]
jne 0x403942
movzx edx, byte [rax + 8]
cmp dl, 0x20
je 0x403e27
cmp dl, 9
je 0x403e27
lea rdi, str._include_noerr
mov ecx, 0xe
mov rsi, rax
repe cmpsb byte [rsi], byte [rdi]
jne 0x40396b
movzx edx, byte [rax + 0xe]
cmp dl, 0x20
je 0x403c2c
cmp dl, 9
je 0x403c2c
lea rdi, str._rename
mov ecx, 7
mov rsi, rax
repe cmpsb byte [rsi], byte [rdi]
jne 0x403f34
movzx edx, byte [rax + 7]
cmp dl, 0x20
je 0x403994
cmp dl, 9
jne 0x403f34
lea r15, [rax + 8]
movzx eax, byte [rax + 8]
cmp al, 0x20
je 0x4039a4
cmp al, 9
jne 0x4039b4
add r15, 1
movzx eax, byte [r15]
cmp al, 9
je 0x4039a4
cmp al, 0x20
je 0x4039a4
mov rdx, qword [0x00502570]
test byte [rdx + rax*2], 0x88
je 0x403f2f
movzx eax, byte [r15]
test al, al
je 0x403ec5
movzx ecx, al
mov r8, r15
test byte [rdx + rcx*2], 0x40
je 0x4039ef
jmp 0x403cc2
movzx ecx, al
test byte [rdx + rcx*2], 0x40
jne 0x403cc2
add r8, 1
movzx eax, byte [r8]
test al, al
jne 0x4039e2
jmp 0x403ec8
cmp dl, 0x3a
jne 0x4038dd
cmp rbx, rsi
jae 0x403e1f
movzx edx, byte [rsi - 1]
cmp dl, 9
je 0x403a24
cmp dl, 0x20
jne 0x403e1f
mov rdx, rsi
nop word [rax + rax]
sub rdx, 1
cmp rdx, rbx
je 0x403a47
movzx ecx, byte [rdx - 1]
cmp cl, 0x20
je 0x403a30
cmp cl, 9
je 0x403a30
sub rdx, rax
mov rcx, rax
call fcn.00401820
lea rcx, [rsi + 1]
mov rbp, rax
call fcn.00401560
movzx edx, byte [rax + 1]
test dl, dl
je 0x403f95
movzx r8d, byte [rax]
mov r14, rax
test r8b, r8b
jne 0x403a90
jmp 0x403e18
add r14, 1
test dl, dl
je 0x403aa5
mov r8d, edx
movzx edx, byte [r14 + 1]
cmp r8b, 0xa
jne 0x403a80
cmp dl, 0xa
je 0x403aa5
test dl, dl
je 0x403aa5
add r14, 1
jmp 0x403a88
mov edx, r14d
sub edx, eax
mov rcx, rax
call fcn.00401820
mov r13, rax
movzx eax, byte [rax]
mov rcx, r13
mov rdx, r13
test al, al
je 0x403ae4
cmp al, 0x5c
je 0x403b70
cmp al, 0x23
je 0x403b58
mov byte [rcx], al
movzx eax, byte [rdx + 1]
add rcx, 1
add rdx, 1
test al, al
jne 0x403ac2
mov byte [rcx], 0
cmp byte [rbp], 0x2a
jne 0x403b90
lea rdi, str.link_command
mov ecx, 0xe
mov rsi, rbp
repe cmpsb byte [rsi], byte [rdi]
jne 0x403c10
mov rcx, r14
mov qword [str.__fsyntax_only:__c:__M:__MM:__E:__S:______linker____fno_use_linker_plugin:__fno_lto:______plugin___linker_plugin_file_______plugin_opt__lto_wrapper_______plugin_opt_fresolution_u.res______flinker_output:_plugin_opt_linker_output_known_______nostdlib:__nodefaultlibs:_:pass_through_libs___link_gcc_c_sequence________fltoflto:__fcompare_debug______flto__fno_lto__flto__l__staticsharedr:_pie:_pie__fuse_ld:_fuse_ld____gzgzzlib:__compress_debug_sectionszlib__gznone:__compress_debug_sectionsnone__gzzlib_gnu:__compress_debug_sectionszlib_gnu__X__o__e__N__n__r_____s__t__u__z__Z___nostdlib:__r:__nostartfiles:_S______staticno_piestatic_pie:___L___mfwrap____link_libgcc___fvtable_verifynone:__fvtable_verifystd:____e_fvtable_verifystd_is_not_supported_in_this_configuration__fvtable_verifypreinit:____e_fvtable_verifypreinit_is_not_supported_in_this_configuration___nostdlib:__r:__nodefaultlibs:__:sanitize_address_:_______:sanitize_thread_:_______:sanitize_leak_:__o_______fopenaccfopenmp_:gt__ftree_parallelize_loops:__1_:_t_:include_libgomp.spec___link_gomp______fgnu_tm:_:include_libitm.spec___link_itm_______mflib____fsplit_stack:___wrappthread_create_____fprofile_arcsfprofile_generatecoverage:_lgcov___nostdlib:__r:__nodefaultlibs:__:sanitize_address_:_static_libasan:_Bstatic__lasan__static_libasan:_Bdynamic__static_libasanstatic:_:include_libsanitizer.spec___link_libasan______static:_ecannot_specify__static_with__fsanitizeaddress______:sanitize_thread_:_static_libtsan:_Bstatic__ltsan__static_libtsan:_Bdynamic__static_libtsanstatic:_:include_libsanitizer.spec___link_libtsan______static:_ecannot_specify__static_with__fsanitizethread______:sanitize_undefined_:_static_libubsan:_Bstatic__lubsan__static_libubsan:_Bdynamic__static_libubsanstatic:_:include_libsanitizer.spec___link_libubsan_______:sanitize_leak_:_static_liblsan:_Bstatic__llsan__static_liblsan:_Bdynamic__static_liblsanstatic:_:include_libsanitizer.spec___link_liblsan________nostdlib:__r:__nodefaultlibs:__link_ssp____link_gcc_c_sequence_______nostdlib:__r:__nostartfiles:_E__T___n__post_link__], r13
call fcn.00401560
movzx edx, byte [rax]
test dl, dl
jne 0x4038a4
cmp qword [str.__fsyntax_only:__c:__M:__MM:__E:__S:______linker____fno_use_linker_plugin:__fno_lto:______plugin___linker_plugin_file_______plugin_opt__lto_wrapper_______plugin_opt_fresolution_u.res______flinker_output:_plugin_opt_linker_output_known_______nostdlib:__nodefaultlibs:_:pass_through_libs___link_gcc_c_sequence________fltoflto:__fcompare_debug______flto__fno_lto__flto__l__staticsharedr:_pie:_pie__fuse_ld:_fuse_ld____gzgzzlib:__compress_debug_sectionszlib__gznone:__compress_debug_sectionsnone__gzzlib_gnu:__compress_debug_sectionszlib_gnu__X__o__e__N__n__r_____s__t__u__z__Z___nostdlib:__r:__nostartfiles:_S______staticno_piestatic_pie:___L___mfwrap____link_libgcc___fvtable_verifynone:__fvtable_verifystd:____e_fvtable_verifystd_is_not_supported_in_this_configuration__fvtable_verifypreinit:____e_fvtable_verifypreinit_is_not_supported_in_this_configuration___nostdlib:__r:__nodefaultlibs:__:sanitize_address_:_______:sanitize_thread_:_______:sanitize_leak_:__o_______fopenaccfopenmp_:gt__ftree_parallelize_loops:__1_:_t_:include_libgomp.spec___link_gomp______fgnu_tm:_:include_libitm.spec___link_itm_______mflib____fsplit_stack:___wrappthread_create_____fprofile_arcsfprofile_generatecoverage:_lgcov___nostdlib:__r:__nodefaultlibs:__:sanitize_address_:_static_libasan:_Bstatic__lasan__static_libasan:_Bdynamic__static_libasanstatic:_:include_libsanitizer.spec___link_libasan______static:_ecannot_specify__static_with__fsanitizeaddress______:sanitize_thread_:_static_libtsan:_Bstatic__ltsan__static_libtsan:_Bdynamic__static_libtsanstatic:_:include_libsanitizer.spec___link_libtsan______static:_ecannot_specify__static_with__fsanitizethread______:sanitize_undefined_:_static_libubsan:_Bstatic__lubsan__static_libubsan:_Bdynamic__static_libubsanstatic:_:include_libsanitizer.spec___link_libubsan_______:sanitize_leak_:_static_liblsan:_Bstatic__llsan__static_liblsan:_Bdynamic__static_liblsanstatic:_:include_libsanitizer.spec___link_liblsan________nostdlib:__r:__nodefaultlibs:__link_ssp____link_gcc_c_sequence_______nostdlib:__r:__nostartfiles:_E__T___n__post_link__], 0
je 0x403f1a
mov rcx, rbx
add rsp, 0x88
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
jmp fcn.00494cb8
cmp al, 0xa
je 0x403abe
add rdx, 1
movzx eax, byte [rdx]
test al, al
jne 0x403b50
jmp 0x403abe
cmp byte [rdx + 1], 0xa
jne 0x403ad2
movzx eax, byte [rdx + 2]
add rdx, 2
jmp 0x403abe
mov eax, dword [0x00510228]
mov rcx, qword [0x00510230]
lea edx, [rax + 2]
movsxd rdx, edx
shl rdx, 5
call fcn.0047c14c
movsxd rdx, dword [0x00510228]
mov qword [0x00510230], rax
mov rcx, rdx
shl rdx, 5
lea r8, [rax + rdx]
lea rax, [rax + rdx + 0x20]
add ecx, 1
mov dword [0x00510228], ecx
mov qword [r8], rbp
mov qword [r8 + 8], r13
mov qword [rax], 0
mov qword [rax + 8], 0
mov qword [rax + 0x10], 0
mov qword [rax + 0x18], 0
cmp byte [rbp], 0
je 0x403b08
jmp 0x403891
movzx r8d, byte [rsp + 0x37]
lea rcx, [rbp + 1]
mov rdx, r13
call fcn.00402630
mov rcx, r13
call fcn.00494cb8
jmp 0x403bf9
lea rdx, [rax + 0xf]
movzx eax, byte [rax + 0xf]
cmp al, 0x20
jne 0x403c4b
nop dword [rax + rax]
add rdx, 1
movzx eax, byte [rdx]
cmp al, 0x20
je 0x403c40
cmp al, 9
je 0x403c40
cmp al, 0x3c
lea rsi, [rdx + 1]
jne 0x403f79
cmp byte [r9 - 1], 0x3e
jne 0x403f79
lea rcx, [0x0049b8a0]
mov byte [r9 - 1], 0
mov r8d, 4
mov r9d, 1
mov rdx, rsi
call fcn.004036d0
test rax, rax
jne 0x403eb0
mov rax, qword [0x00502630]
mov edx, dword [rax + 0x1358]
test edx, edx
je 0x403891
call qword [sym.imp.msvcrt.dll___iob_func]
lea rdx, str.could_not_find_specs_file__s_n
lea rcx, [rax + 0x60]
mov r8, rsi
call fcn.00424db0
jmp 0x403891
cmp al, 0x20
jne 0x403ea2
movzx eax, byte [r8 + 1]
mov ebp, r8d
lea rdi, [r8 + 1]
sub ebp, r15d
mov byte [r8], 0
cmp al, 0x20
je 0x403ce5
cmp al, 9
jne 0x403cf4
add rdi, 1
movzx eax, byte [rdi]
cmp al, 9
je 0x403ce5
cmp al, 0x20
je 0x403ce5
test byte [rdx + rax*2], 0x88
je 0x403f71
movzx eax, byte [rdi]
mov r8, rdi
test al, al
jne 0x403d1c
jmp 0x403d22
add r8, 1
movzx eax, byte [r8]
test al, al
je 0x403d22
test byte [rdx + rax*2], 0x40
je 0x403d10
cmp r9, r8
jne 0x403ec8
mov r13, qword [0x005101d0]
mov byte [r9], 0
test r13, r13
je 0x403e00
mov rsi, r13
jmp 0x403d51
mov rsi, qword [rsi + 0x18]
test rsi, rsi
je 0x403e00
cmp dword [rsi + 0x20], ebp
jne 0x403d44
mov rcx, qword [rsi]
mov rdx, r15
call sub.msvcrt.dll_strcmp
test eax, eax
jne 0x403d44
mov rdx, rdi
mov rcx, r15
call sub.msvcrt.dll_strcmp
test eax, eax
je 0x403891
mov rcx, qword [r13]
mov rdx, rdi
call sub.msvcrt.dll_strcmp
test eax, eax
je 0x403f4f
mov r13, qword [r13 + 0x18]
test r13, r13
jne 0x403d78
mov rax, qword [0x00502630]
mov eax, dword [rax + 0x1358]
test eax, eax
je 0x403dc2
call qword [sym.imp.msvcrt.dll___iob_func]
lea rdx, str.rename_spec__s_to__s_n
lea rcx, [rax + 0x60]
mov r9, rdi
mov r8, r15
call fcn.00424db0
mov rax, qword [rsi + 0x10]
movzx r8d, byte [rsp + 0x37]
mov rcx, rdi
mov rdx, qword [rax]
call fcn.00402630
cmp byte [rsi + 0x25], 0
je 0x403de9
mov rax, qword [rsi + 0x10]
mov rcx, qword [rax]
call fcn.00494cb8
mov rax, qword [rsi + 0x10]
lea rdi, section..rdata
mov qword [rax], rdi
mov byte [rsi + 0x25], 0
jmp 0x403891
mov rax, qword [0x00502670]
lea rdx, str.specs__s_spec_was_not_found_to_be_renamed
mov r8, r15
mov ecx, dword [rax]
call fcn.00426b60
xor edx, edx
jmp 0x403aaa
mov rdx, rsi
jmp 0x403a47
lea rdx, [rax + 9]
movzx eax, byte [rax + 9]
cmp al, 0x20
je 0x403e40
cmp al, 9
jne 0x403e4f
nop word [rax + rax]
add rdx, 1
movzx eax, byte [rdx]
cmp al, 9
je 0x403e40
cmp al, 0x20
je 0x403e40
cmp al, 0x3c
lea rsi, [rdx + 1]
jne 0x403f79
cmp byte [r9 - 1], 0x3e
jne 0x403f79
lea rcx, [0x0049b8a0]
mov rdx, rsi
mov byte [r9 - 1], 0
mov r8d, 4
mov r9d, 1
call fcn.004036d0
movzx r8d, byte [rsp + 0x37]
test rax, rax
cmove rax, rsi
xor edx, edx
mov rcx, rax
call fcn.004037a0
jmp 0x403891
cmp al, 9
je 0x403cca
jmp 0x403ec8
movzx r8d, byte [rsp + 0x37]
xor edx, edx
mov rcx, rax
call fcn.004037a0
jmp 0x403891
mov r8, r15
mov rax, qword [0x00502670]
lea rdx, str.specs___rename_syntax_malformed_after__ld_characters
sub r8d, ebx
mov ecx, dword [rax]
call fcn.00426b60
call qword [sym.imp.msvcrt.dll___iob_func]
mov r8, qword [rsp + 0x38]
lea rcx, [rax + 0x60]
lea rdx, str.Reading_specs_from__s_n
call fcn.00424db0
jmp 0x4037d5
mov rax, qword [0x00502670]
mov r8, qword [rsp + 0x38]
lea rdx, str.cannot_read_spec_file__qs:__m
mov ecx, dword [rax]
call fcn.00426b60
mov rax, qword [0x00502670]
lea rdx, str.spec_file_has_no_spec_for_linking
mov ecx, dword [rax]
call fcn.00426b60
mov r8d, r15d
jmp 0x403ec8
mov r8d, eax
mov rax, qword [0x00502670]
lea rdx, str.specs_unknown____command_after__ld_characters
sub r8d, ebx
mov ecx, dword [rax]
call fcn.00426b60
mov rax, qword [0x00502670]
mov qword [rsp + 0x20], rdi
lea rdx, str._s:_attempt_to_rename_spec__qs_to_already_defined_spec__qs
mov r8, qword [rsp + 0x38]
mov r9, r15
mov ecx, dword [rax]
call fcn.00426b60
mov r8d, edi
jmp 0x403ec8
mov rax, qword [0x00502670]
sub rsi, rbx
lea rdx, str.specs___include_syntax_malformed_after__ld_characters
lea r8d, [rsi + 1]
mov ecx, dword [rax]
call fcn.00426b60
mov r8d, eax
jmp 0x4038e0