Function at 0x1400a7750
Capabilities:
Write file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x38
mov r15d, r8d
mov rdi, rcx
mov r14d, edx
mov rbp, r9
and r15d, 0x40
test edx, edx
jle 0x1400a7900
movsxd rdx, edx
movzx eax, byte [rcx + rdx - 1]
mov ecx, r8d
and ecx, 0x200
cmp al, 0xa
je 0x1400a78d0
mov dword [rsp + 0x2c], 0
test ecx, ecx
je 0x1400a77af
lea r12d, [r14 - 1]
mov r13d, 1
cmp al, 0xd
je 0x1400a7aed
test r15d, r15d
jne 0x1400a7a90
mov r12d, r14d
xor r13d, r13d
mov r11d, r8d
mov eax, r8d
xor r9d, r9d
mov dword [rsp + 0x24], r15d
shr r11b, 7
and eax, 0x800
mov esi, r12d
xor ebx, ebx
mov dword [rsp + 0x20], eax
mov r12d, r9d
mov r15d, r11d
mov dword [rsp + 0x28], r13d
mov dword [rsp + 0x88], r14d
mov dword [rsp + 0x90], r8d
jmp 0x1400a7870
test rbp, rbp
je 0x1400a7855
sub edx, r12d
movsxd rcx, r12d
mov r9, rbp
mov r8d, 1
movsxd rdx, edx
add rcx, rdi
call sub.msvcrt.dll_fwrite
mov rcx, qword [rsp + 0xb0]
mov rdx, rbp
call fcn.1401bf070
mov edx, 1
mov rcx, r14
mov r9, rbp
mov r8d, 1
call sub.msvcrt.dll_fwrite
mov rcx, qword [rsp + 0xa8]
mov rdx, rbp
call fcn.1401bf070
or dword [rsp + 0x24], 0x800
lea r12d, [r13 + 1]
add rbx, 1
mov edx, r12d
cmp edx, esi
jge 0x1400a7b20
movzx eax, byte [rdi + rbx]
mov r13d, ebx
mov edx, ebx
lea r14, [rdi + rbx]
cmp al, 0x20
je 0x1400a7b10
cmp al, 9
jne 0x1400a7b20
test r15b, r15b
je 0x1400a789b
cmp r12d, ebx
jl 0x1400a7b50
mov ecx, dword [rsp + 0x20]
test ecx, ecx
jne 0x1400a7800
test rbp, rbp
je 0x1400a785d
sub edx, r12d
movsxd rcx, r12d
mov r9, rbp
mov r8d, 1
add edx, 1
add rcx, rdi
movsxd rdx, edx
call sub.msvcrt.dll_fwrite
jmp 0x1400a785d
lea r12d, [r14 - 1]
test ecx, ecx
je 0x1400a7ae2
test r12d, r12d
je 0x1400a7bd0
mov dword [rsp + 0x2c], 1
movzx eax, byte [rdi + rdx - 2]
mov r14d, r12d
jmp 0x1400a779d
test r15d, r15d
jne 0x1400a7a70
mov dword [rsp + 0x2c], 0
mov r12d, edx
xor r13d, r13d
xor esi, esi
xor r9d, r9d
nop dword [rax]
test r8d, 0x100
je 0x1400a7990
mov ebx, esi
and r8d, 0x3f
sub ebx, r9d
cmp ebx, r8d
jb 0x1400a7990
mov dword [rsp + 0x20], r9d
or r15d, 0x100
test rbp, rbp
je 0x1400a7a3d
mov rcx, qword [rsp + 0xb0]
mov rdx, rbp
call fcn.1401bf070
movsxd rcx, dword [rsp + 0x20]
mov r9, rbp
movsxd rdx, ebx
mov r8d, 1
add rcx, rdi
call sub.msvcrt.dll_fwrite
mov rcx, qword [rsp + 0xa8]
mov rdx, rbp
call fcn.1401bf070
mov r9d, esi
jmp 0x1400a7999
test rbp, rbp
je 0x1400a7a3d
mov ebx, r12d
mov dword [rsp + 0x20], r9d
sub ebx, r9d
test ebx, ebx
jle 0x1400a79e1
mov rcx, qword [rsp + 0xa0]
mov rdx, rbp
call fcn.1401bf070
movsxd rcx, dword [rsp + 0x20]
movsxd rdx, ebx
mov r9, rbp
mov r8d, 1
add rcx, rdi
call sub.msvcrt.dll_fwrite
mov rcx, qword [rsp + 0xa8]
mov rdx, rbp
call fcn.1401bf070
cmp r14d, r12d
je 0x1400a7a23
mov rcx, qword [rsp + 0xb0]
mov rdx, rbp
call fcn.1401bf070
mov edx, r14d
movsxd rcx, r12d
mov r9, rbp
sub edx, r12d
add rcx, rdi
mov r8d, 1
movsxd rdx, edx
call sub.msvcrt.dll_fwrite
mov rcx, qword [rsp + 0xa8]
mov rdx, rbp
call fcn.1401bf070
test r13d, r13d
jne 0x1400a7a58
mov eax, dword [rsp + 0x2c]
test eax, eax
je 0x1400a7a3d
mov rdx, rbp
mov ecx, 0xa
call sub.msvcrt.dll_fputc
mov eax, r15d
add rsp, 0x38
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov rdx, rbp
mov ecx, 0xd
call sub.msvcrt.dll_fputc
jmp 0x1400a7a28
mov dword [rsp + 0x2c], 0
xor r13d, r13d
mov r12d, r14d
xor esi, esi
xor r9d, r9d
xor r15d, r15d
jmp 0x1400a7920
lea eax, [r14 - 1]
xor r13d, r13d
mov r9, qword [str._________AA__A__________________]
cdqe
mov r12d, 0xffffffff
xor r15d, r15d
jmp 0x1400a7ac2
sub rax, 1
mov r15d, 0x40
test eax, eax
js 0x1400a7bb7
movzx edx, byte [rdi + rax]
mov ecx, r12d
mov r12d, eax
test byte [r9 + rdx], 1
jne 0x1400a7ab0
cmp ecx, 0xffffffff
cmove ecx, r14d
mov r12d, ecx
jmp 0x1400a77be
mov dword [rsp + 0x2c], 1
xor r13d, r13d
test r15d, r15d
je 0x1400a7bb4
lea eax, [r12 - 1]
test r12d, r12d
je 0x1400a7beb
mov r14d, r12d
jmp 0x1400a7a97
lea edx, [rbx + 1]
add rbx, 1
cmp edx, esi
jl 0x1400a7870
nop
mov r9d, r12d
mov r13d, dword [rsp + 0x28]
mov r12d, esi
mov r15d, dword [rsp + 0x24]
mov r14d, dword [rsp + 0x88]
mov r8d, dword [rsp + 0x90]
mov esi, edx
jmp 0x1400a7920
test rbp, rbp
je 0x1400a7ba7
mov rcx, qword [rsp + 0xb0]
mov rdx, rbp
call fcn.1401bf070
mov edx, ebx
movsxd rcx, r12d
mov r9, rbp
sub edx, r12d
mov r8d, 1
add rcx, rdi
movsxd rdx, edx
call sub.msvcrt.dll_fwrite
mov rcx, qword [rsp + 0xa8]
mov rdx, rbp
call fcn.1401bf070
mov r9, rbp
mov edx, 1
mov rcx, r14
mov r8d, 1
call sub.msvcrt.dll_fwrite
or dword [rsp + 0x24], 0x80
jmp 0x1400a785d
mov r14d, r12d
test r12d, r12d
jne 0x1400a77be
xor esi, esi
xor r9d, r9d
jmp 0x1400a7920
mov dword [rsp + 0x2c], 1
xor r13d, r13d
xor r14d, r14d
xor esi, esi
xor r9d, r9d
xor r15d, r15d
jmp 0x1400a7920
xor r14d, r14d
jmp 0x1400a7a7b