Function at 0x40e410
Capabilities:
Write file on windows

Disassembly:
sub rsp, 0x28
mov dword [0x005142f8], 0x14
cmp edx, 0x13
mov qword [0x005142f0], rcx
mov dword [0x005142e8], edx
ja 0x40e3f5
add rsp, 0x28
ret
lea r8, str.bfd_set_input_error
mov edx, 0x21c
lea rcx, str..._.._.._src_binutils_2.30_bfd_bfd.c
call fcn.0040e340
nop
nop
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x178
lea r15, [rsp + 0xe0]
mov qword [rsp + 0x1c8], rdx
mov rbx, rcx
lea rdx, [rsp + 0x170]
mov rax, r15
mov dword [rax], 0
add rax, 0x10
cmp rdx, rax
jne 0x40e441
mov rcx, qword [0x00505e60]
mov rax, rbx
mov dword [rsp + 0x28], 0
lea rdi, [0x004ce25d]
mov qword [rsp + 0x40], rcx
mov qword [rsp + 0x48], rcx
mov qword [rsp + 0x30], rcx
mov qword [rsp + 0x38], rcx
nop dword [rax]
movzx edx, byte [rax]
test dl, dl
je 0x40e4a2
cmp dl, 0x25
je 0x40e725
mov edx, 0x25
mov rcx, rax
call sub.msvcrt.dll_strchr
test rax, rax
jne 0x40e480
mov eax, dword [rsp + 0x28]
test eax, eax
je 0x40e501
mov eax, dword [rsp + 0x28]
lea rcx, [0x004ce288]
mov r9, qword [rsp + 0x1c8]
sub eax, 1
lea r8, [rax*8 + 8]
xor eax, eax
nop word [rax + rax]
cmp dword [r15 + rax*2], 6
ja 0x40ee8e
mov edx, dword [r15 + rax*2]
movsxd rdx, dword [rcx + rdx*4]
add rdx, rcx
jmp rdx
add rax, 8
cmp r8, rax
jne 0x40e4d0
mov rdi, qword [fcn.004c1900]
mov ecx, 1
mov qword [rsp + 0x40], rdi
call rdi
mov rcx, rax
call fcn.004c1788
mov rsi, qword [0x005142e0]
mov ecx, 2
test rsi, rsi
je 0x40edeb
call rdi
lea rdx, [0x004ce261]
mov r8, rsi
mov rcx, rax
call sub.msvcrt.dll_fprintf
mov ecx, 2
mov rax, qword [rsp + 0x40]
call rax
mov dword [rsp + 0x30], 0
mov qword [rsp + 0x28], rax
jmp 0x40e59f
mov edx, 0x25
mov rcx, rbx
call sub.msvcrt.dll_strchr
test rax, rax
je 0x40eaf0
mov rcx, qword [rsp + 0x28]
mov r8d, eax
mov r9, rbx
lea rdx, str._.s
sub r8d, ebx
call sub.msvcrt.dll_fprintf
movsxd rdx, eax
add rbx, rdx
cmp eax, 0xffffffff
je 0x40e96f
movzx eax, byte [rbx]
test al, al
je 0x40e96f
cmp al, 0x25
jne 0x40e560
movzx esi, byte [rbx + 1]
cmp sil, 0x25
je 0x40ec71
lea rdi, [rbx + 1]
cmp sil, 0x30
mov byte [rsp + 0x60], 0x25
je 0x40eca0
mov rdx, qword [0x00505e60]
movzx eax, sil
movsx ebp, sil
mov r12d, 0xffffffff
test byte [rdx + rax*2], 4
je 0x40e600
cmp byte [rbx + 2], 0x24
jne 0x40e600
lea r12d, [rbp - 0x31]
movsx ebp, byte [rbx + 3]
lea rdi, [rbx + 3]
mov esi, ebp
nop
lea rax, [rsp + 0x60]
mov qword [rsp + 0x38], rax
lea r14, [rsp + 0x61]
jmp 0x40e622
add rdi, 1
movsx ebp, byte [rdi]
add r14, 1
mov byte [r14 - 1], sil
mov esi, ebp
lea rcx, str.__0I
mov edx, ebp
call sub.msvcrt.dll_strchr
test rax, rax
jne 0x40e611
cmp sil, 0x2a
je 0x40ebb0
mov rdx, qword [0x00505e60]
movzx ebp, bpl
test byte [rdx + rbp*2], 4
je 0x40e668
add rdi, 1
movzx eax, byte [rdi]
add r14, 1
mov byte [r14 - 1], sil
test byte [rdx + rax*2], 4
mov rsi, rax
jne 0x40e650
cmp sil, 0x2e
je 0x40ec26
lea rbx, [0x004ce25d]
xor r13d, r13d
xor ebp, ebp
nop
movsx edx, sil
mov rcx, rbx
call sub.msvcrt.dll_strchr
test rax, rax
je 0x40e910
cmp sil, 0x68
je 0x40e6f0
cmp sil, 0x6c
je 0x40e720
cmp sil, 0x4c
je 0x40e710
lea r8, str._bfd_doprnt
mov edx, 0x307
lea rcx, str..._.._.._src_binutils_2.30_bfd_bfd.c
call fcn.0040e340
nop
mov rdx, qword [r9 + rax]
mov qword [r15 + rax*2], rdx
jmp 0x40e4f8
mov r13d, 1
add rdi, 1
add r14, 1
mov byte [r14 - 1], sil
movzx esi, byte [rdi]
jmp 0x40e680
mov ebp, 2
jmp 0x40e6f6
add ebp, 1
jmp 0x40e6f6
movzx esi, byte [rax + 1]
cmp sil, 0x25
jne 0x40e740
add rax, 2
jmp 0x40e480
lea r14, [rax + 1]
cmp sil, 0x30
je 0x40ec90
mov rcx, qword [rsp + 0x38]
movzx edx, sil
movsx ebp, sil
mov r12d, 0xffffffff
test byte [rcx + rdx*2], 4
je 0x40e78a
cmp byte [rax + 2], 0x24
jne 0x40e78a
lea r12d, [rbp - 0x31]
movsx ebp, byte [rax + 3]
lea r14, [rax + 3]
mov esi, ebp
jmp 0x40e78a
add r14, 1
movsx ebp, byte [r14]
mov esi, ebp
lea rcx, str.__0I
mov edx, ebp
call sub.msvcrt.dll_strchr
test rax, rax
jne 0x40e780
cmp sil, 0x2a
je 0x40eb10
mov rax, qword [rsp + 0x30]
movzx ebp, bpl
mov rdx, qword [rsp + 0x30]
test byte [rax + rbp*2], 4
je 0x40e7d1
nop dword [rax + rax]
add r14, 1
movzx eax, byte [r14]
test byte [rdx + rax*2], 4
mov rsi, rax
jne 0x40e7c0
cmp sil, 0x2e
jne 0x40e811
movzx esi, byte [r14 + 1]
cmp sil, 0x2a
je 0x40ecc0
mov rcx, qword [rsp + 0x40]
movzx eax, sil
add r14, 1
mov rdx, qword [rsp + 0x40]
test byte [rcx + rax*2], 4
je 0x40e811
nop
add r14, 1
movzx eax, byte [r14]
test byte [rdx + rax*2], 4
mov rsi, rax
jne 0x40e800
xor r13d, r13d
xor ebp, ebp
nop word cs:[rax + rax]
movsx edx, sil
mov rcx, rdi
call sub.msvcrt.dll_strchr
test rax, rax
je 0x40e885
cmp sil, 0x68
je 0x40e860
cmp sil, 0x6c
je 0x40e880
cmp sil, 0x4c
je 0x40e870
lea r8, str._bfd_doprnt_scan
mov edx, 0x404
lea rcx, str..._.._.._src_binutils_2.30_bfd_bfd.c
call fcn.0040e340
nop dword [rax + rax]
mov r13d, 1
add r14, 1
movzx esi, byte [r14]
jmp 0x40e820
mov ebp, 2
jmp 0x40e866
add ebp, 1
jmp 0x40e866
lea ecx, [rsi - 0x41]
test r12d, r12d
cmovs r12d, dword [rsp + 0x28]
lea rax, [r14 + 1]
cmp cl, 0x37
ja 0x40eea6
mov edx, 1
shl rdx, cl
movabs rcx, 0x90410c00800000
test rdx, rcx
jne 0x40eb80
movabs rcx, 0x4800000000003
test rdx, rcx
jne 0x40ecb0
movabs rcx, 0x7000000050
test rdx, rcx
je 0x40eea6
xor r13d, r13d
test ebp, ebp
setne r13b
add r13d, 4
cmp r12d, 8
ja 0x40ef1e
add dword [rsp + 0x28], 1
mov r12d, r12d
shl r12, 4
mov dword [rsp + r12 + 0xe0], r13d
jmp 0x40e480
lea eax, [rsi - 0x41]
test r12d, r12d
mov byte [r14], sil
cmovs r12d, dword [rsp + 0x30]
cmp al, 0x37
mov byte [r14 + 1], 0
lea rbx, [rdi + 1]
ja case.0x40e941.2
lea rdx, [0x004ce2a4]
movzx eax, al
movsxd rax, dword [rdx + rax*4]
add rax, rdx
jmp rax
mov r12d, r12d
mov rdx, qword [rsp + 0x38]
shl r12, 4
mov rcx, qword [rsp + 0x28]
mov r8, qword [rsp + r12 + 0xe0]
call sub.msvcrt.dll_fprintf
add dword [rsp + 0x30], 1
cmp eax, 0xffffffff
jne 0x40e59f
mov rbx, qword [rsp + 0x40]
mov ecx, 2
call rbx
mov ecx, 0xa
mov rdx, rax
call sub.msvcrt.dll_fputc
mov ecx, 2
call rbx
mov rcx, rax
call fcn.004c1788
nop
add rsp, 0x178
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov r12d, r12d
shl r12, 4
add r12, r15
test r13d, r13d
jne 0x40e9ec
cmp byte [rdi - 1], 0x4c
lea rax, [r14 + 1]
jne 0x40e9df
mov byte [r14 - 1], 0x6c
lea rax, [r14 + 2]
mov byte [r14], 0x6c
mov byte [r14 + 1], sil
mov byte [r14 + 2], 0
test ebp, ebp
je 0x40e9ec
cmp ebp, 1
jne 0x40ee56
mov r8d, dword [r12]
mov rdx, qword [rsp + 0x38]
mov rcx, qword [rsp + 0x28]
call sub.msvcrt.dll_fprintf
jmp 0x40e961
mov r12d, r12d
shl r12, 4
add r12, r15
test ebp, ebp
jne 0x40ed89
mov rdx, qword [rsp + 0x38]
mov rcx, qword [rsp + 0x28]
movsd xmm0, qword [r12]
movapd xmm2, xmm0
movq r8, xmm0
call sub.msvcrt.dll_fprintf
jmp 0x40e961
mov r12d, r12d
shl r12, 4
mov rax, qword [rsp + r12 + 0xe0]
test rax, rax
je 0x40eebe
mov rdx, qword [rax + 0xc8]
mov r8, qword [rax]
test rdx, rdx
je 0x40ea71
test byte [rdx + 0x44], 1
je 0x40edcf
mov rcx, qword [rsp + 0x28]
lea rdx, [0x004ce271]
call sub.msvcrt.dll_fprintf
jmp 0x40e961
mov r12d, r12d
shl r12, 4
mov rax, qword [rsp + r12 + 0xe0]
test rax, rax
je 0x40eed6
mov rdx, qword [rax + 0xf0]
mov r8, qword [rax]
test rdx, rdx
je 0x40ea71
mov rdx, qword [rdx + 8]
mov edx, dword [rdx + 8]
cmp edx, 5
je 0x40ee11
cmp edx, 2
jne 0x40ea71
mov rax, qword [rax + 0xe0]
test rax, rax
je 0x40ea71
mov rax, qword [rax + 0x40]
test rax, rax
je 0x40ea71
mov r9, qword [rax]
jmp 0x40ee37
mov rcx, qword [rsp + 0x28]
lea rdx, [0x004ce271]
mov r8, rbx
call sub.msvcrt.dll_fprintf
jmp 0x40e590
movzx edx, byte [r14 + 1]
lea rcx, [r14 + 1]
mov esi, dword [rsp + 0x28]
cmp dl, 0x30
mov eax, esi
je 0x40eb50
mov r10, qword [rsp + 0x48]
movsx r8d, dl
movzx edx, dl
test byte [r10 + rdx*2], 4
je 0x40eb50
cmp byte [r14 + 2], 0x24
jne 0x40eb50
lea eax, [r8 - 0x31]
lea rcx, [r14 + 3]
nop word cs:[rax + rax]
cmp eax, 8
ja 0x40ef36
shl rax, 4
movzx esi, byte [rcx]
mov r14, rcx
mov dword [rsp + rax + 0xe0], 1
add dword [rsp + 0x28], 1
jmp 0x40e7d1
test r13d, r13d
jne 0x40e8ec
test ebp, ebp
mov r13d, 1
je 0x40e8ec
xor r13d, r13d
cmp ebp, 1
setne r13b
add r13d, 2
jmp 0x40e8ec
movzx edx, byte [rdi + 1]
lea rbx, [rdi + 1]
mov esi, dword [rsp + 0x30]
cmp dl, 0x30
mov eax, esi
je 0x40ebe1
mov rcx, qword [0x00505e60]
movsx r8d, dl
movzx edx, dl
test byte [rcx + rdx*2], 4
je 0x40ebe1
cmp byte [rdi + 2], 0x24
je 0x40edc2
add dword [rsp + 0x30], 1
shl rax, 4
mov rcx, r14
mov rdi, rbx
mov edx, dword [rsp + rax + 0xe0]
mov r8d, dword [rsp + rax + 0xe0]
sar edx, 0x1f
xor r8d, edx
sub r8d, edx
lea rdx, [0x004ce274]
call sub.msvcrt.dll_sprintf
movzx esi, byte [rbx]
cdqe
add r14, rax
cmp sil, 0x2e
jne 0x40e672
movzx esi, byte [rdi + 1]
lea rbx, [r14 + 1]
mov byte [r14], 0x2e
cmp sil, 0x2a
je 0x40ed15
mov rdx, qword [0x00505e60]
movzx eax, sil
add rdi, 1
test byte [rdx + rax*2], 4
je 0x40ec69
add rdi, 1
movzx eax, byte [rdi]
add rbx, 1
mov byte [rbx - 1], sil
test byte [rdx + rax*2], 4
mov rsi, rax
jne 0x40ec51
mov r14, rbx
jmp 0x40e672
mov rdx, qword [rsp + 0x28]
mov ecx, 0x25
add rbx, 2
call sub.msvcrt.dll_fputc
jmp 0x40e59f
mov r12d, 0xffffffff
mov ebp, 0x30
jmp 0x40e78a
mov r12d, 0xffffffff
mov ebp, 0x30
jmp 0x40e600
mov r13d, 6
jmp 0x40e8ec
movzx edx, byte [r14 + 2]
lea rcx, [r14 + 2]
mov esi, dword [rsp + 0x28]
cmp dl, 0x30
mov eax, esi
je 0x40eced
mov r11, qword [0x00505e60]
movsx r8d, dl
movzx edx, dl
test byte [r11 + rdx*2], 4
jne 0x40edaa
cmp eax, 8
ja 0x40ef06
shl rax, 4
movzx esi, byte [rcx]
mov r14, rcx
mov dword [rsp + rax + 0xe0], 1
add dword [rsp + 0x28], 1
jmp 0x40e811
movzx edx, byte [rdi + 2]
lea rbp, [rdi + 2]
mov esi, dword [rsp + 0x30]
cmp dl, 0x30
mov eax, esi
je 0x40ed46
mov rcx, qword [0x00505e60]
movsx r8d, dl
movzx edx, dl
test byte [rcx + rdx*2], 4
je 0x40ed46
cmp byte [rdi + 3], 0x24
je 0x40ee81
add dword [rsp + 0x30], 1
shl rax, 4
mov rcx, rbx
mov rdi, rbp
mov edx, dword [rsp + rax + 0xe0]
mov r8d, dword [rsp + rax + 0xe0]
sar edx, 0x1f
xor r8d, edx
sub r8d, edx
lea rdx, [0x004ce274]
call sub.msvcrt.dll_sprintf
movzx esi, byte [rbp]
movsxd r9, eax
lea r14, [rbx + r9]
jmp 0x40e672
mov rdx, qword [rsp + 0x38]
lea r8, [rsp + 0x50]
mov rcx, qword [rsp + 0x28]
fld xword [r12]
fstp xword [rsp + 0x50]
call sub.msvcrt.dll_fprintf
jmp 0x40e961
cmp byte [r14 + 3], 0x24
jne 0x40eced
lea eax, [r8 - 0x31]
lea rcx, [r14 + 4]
jmp 0x40eced
lea eax, [r8 - 0x31]
lea rbx, [rdi + 3]
jmp 0x40ebe1
mov r9, r8
mov rcx, qword [rsp + 0x28]
mov r8, qword [rdx]
lea rdx, str._s__s_
call sub.msvcrt.dll_fprintf
jmp 0x40e961
mov rax, qword [rsp + 0x40]
call rax
mov r8d, 5
mov edx, 1
lea rcx, str.BFD:
mov r9, rax
call sub.msvcrt.dll_fwrite
jmp 0x40e545
mov rdx, qword [rax + 0xe0]
cmp qword [rdx + 0xc0], 0
je 0x40ea71
test byte [rax + 0x23], 2
jne 0x40ea71
mov r9, qword [rdx + 0xb0]
test r9, r9
je 0x40ea71
mov rcx, qword [rsp + 0x28]
lea rdx, [0x004ce277]
call sub.msvcrt.dll_fprintf
jmp 0x40e961
mov r8, qword [r12]
mov byte [rax], sil
mov rdx, qword [rsp + 0x38]
mov byte [rax - 3], 0x49
mov rcx, qword [rsp + 0x28]
mov byte [rax - 2], 0x36
mov byte [rax - 1], 0x34
mov byte [rax + 1], 0
call sub.msvcrt.dll_fprintf
jmp 0x40e961
lea eax, [r8 - 0x31]
lea rbp, [rdi + 4]
jmp 0x40ed46
lea r8, str.error_handler_internal
mov edx, 0x485
lea rcx, str..._.._.._src_binutils_2.30_bfd_bfd.c
call fcn.0040e340
lea r8, str._bfd_doprnt_scan
mov edx, 0x44f
lea rcx, str..._.._.._src_binutils_2.30_bfd_bfd.c
call fcn.0040e340
lea r8, str._bfd_doprnt
mov edx, 0x38c
lea rcx, str..._.._.._src_binutils_2.30_bfd_bfd.c
call fcn.0040e340
lea r8, str._bfd_doprnt
mov edx, 0x372
lea rcx, str..._.._.._src_binutils_2.30_bfd_bfd.c
call fcn.0040e340
lea r8, str._bfd_doprnt
mov edx, 0x396
lea rcx, str..._.._.._src_binutils_2.30_bfd_bfd.c
call fcn.0040e340
lea r8, str._bfd_doprnt_scan
mov edx, 0x3ed
lea rcx, str..._.._.._src_binutils_2.30_bfd_bfd.c
call fcn.0040e340
lea r8, str._bfd_doprnt_scan
mov edx, 0x453
lea rcx, str..._.._.._src_binutils_2.30_bfd_bfd.c
call fcn.0040e340
lea r8, str._bfd_doprnt_scan
mov edx, 0x3d4
lea rcx, str..._.._.._src_binutils_2.30_bfd_bfd.c
call fcn.0040e340
nop
nop