Function at 0x14001187a
Capabilities:
Write file on windows

Disassembly:
jmp 0x1400183d0
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x27]
sub rsp, 0xf0
mov qword [rbp - 0x11], 0xfffffffffffffffe
mov qword [rsp + 0x140], rbx
mov rax, qword [0x140029010]
xor rax, rsp
mov qword [rbp + 0x17], rax
movzx r12d, dx
mov r14, rcx
mov word [rbp + 0xf], dx
xor esi, esi
mov dword [rsp + 0x40], esi
call fcn.140011aa0
movzx r15d, ax
mov word [rsp + 0x40], ax
lea rdx, [rbp + 0xf]
lea rcx, [rsp + 0x40]
call fcn.1400117f8
test al, al
je 0x140018445
lea rcx, [rbp + 0xf]
call fcn.140011474
jmp 0x14001868e
mov rcx, r14
call qword [sym.imp.MSVCP140D.dll_protected:_wchar_t____ptr64___cdecl_std::basic_streambuf_wchar_t__struct_std::char_traits_wchar_t__::pptr_void_const___ptr64]
test rax, rax
je 0x14001848e
mov rcx, r14
call qword [sym.imp.MSVCP140D.dll_protected:_wchar_t____ptr64___cdecl_std::basic_streambuf_wchar_t__struct_std::char_traits_wchar_t__::epptr_void_const___ptr64]
mov rbx, rax
mov rcx, r14
call qword [sym.imp.MSVCP140D.dll_protected:_wchar_t____ptr64___cdecl_std::basic_streambuf_wchar_t__struct_std::char_traits_wchar_t__::pptr_void_const___ptr64]
cmp rax, rbx
jae 0x14001848e
mov rcx, r14
call qword [sym.imp.MSVCP140D.dll_protected:_wchar_t____ptr64___cdecl_std::basic_streambuf_wchar_t__struct_std::char_traits_wchar_t__::_Pninc_void____ptr64]
mov rbx, rax
lea rcx, [rbp + 0xf]
call fcn.14001199c
mov word [rbx], ax
movzx eax, r12w
jmp 0x14001868e
cmp qword [r14 + 0x80], rsi
je 0x14001868a
mov rcx, r14
call fcn.1400112d5
lea rcx, [rbp + 0xf]
call fcn.14001199c
cmp qword [r14 + 0x68], rsi
jne 0x1400184cd
movzx ecx, ax
mov rdx, qword [r14 + 0x80]
call fcn.14001149c
test al, al
cmovne r15w, r12w
jmp 0x14001868a
mov word [rbp + 7], ax
xor r8d, r8d
lea edx, [r8 + 8]
lea rcx, [rsp + 0x48]
call fcn.1400118bb
nop
lea rdx, [rbp - 0x41]
lea rcx, [rsp + 0x48]
call fcn.140011942
mov rbx, rax
lea rdx, [rbp - 0x59]
lea rcx, [rsp + 0x48]
call fcn.140011942
mov rdi, rax
mov rcx, rbx
call fcn.1400110b9
mov rbx, rax
lea rcx, [rsp + 0x48]
call fcn.14001187f
add rbx, rax
mov rcx, rdi
call fcn.1400110b9
lea rcx, [rbp - 9]
mov qword [rsp + 0x38], rcx
mov qword [rsp + 0x30], rbx
mov qword [rsp + 0x28], rax
lea rax, [rbp - 1]
mov qword [rsp + 0x20], rax
lea r9, [rbp + 9]
lea r8, [rbp + 7]
lea rdx, [r14 + 0x74]
mov rcx, qword [r14 + 0x68]
call qword [sym.imp.MSVCP140D.dll_public:_int___cdecl_std::codecvt_wchar_t__char__struct__Mbstatet_::out_struct__Mbstatet____ptr64__wchar_t_const____ptr64__wchar_t_const____ptr64__wchar_t_const____ptr64____ptr64__char____ptr64__char____ptr64__char____ptr64____ptr64_const___ptr64]
mov ebx, eax
lea rcx, [rbp - 0x59]
call fcn.140011424
nop
lea rcx, [rbp - 0x41]
call fcn.140011424
test ebx, ebx
js 0x140018680
cmp ebx, 1
jg 0x140018664
lea rdx, [rbp - 0x29]
lea rcx, [rsp + 0x48]
call fcn.140011942
nop
mov rcx, rax
call fcn.1400110b9
mov rbx, qword [rbp - 9]
sub rbx, rax
lea rcx, [rbp - 0x29]
call fcn.140011424
test rbx, rbx
je 0x1400185e9
lea rdx, [rbp - 0x29]
lea rcx, [rsp + 0x48]
call fcn.140011942
nop
or esi, 1
mov dword [rsp + 0x40], esi
mov rcx, rax
call fcn.1400110b9
mov rcx, rax
mov r9, qword [r14 + 0x80]
mov r8, rbx
mov edx, 1
call qword [sym.imp.ucrtbased.dll_fwrite]
cmp rbx, rax
je 0x1400185e9
mov dil, 1
jmp 0x1400185ec
xor dil, dil
test sil, 1
je 0x1400185fe
and esi, 0xfffffffe
lea rcx, [rbp - 0x29]
call fcn.140011424
test dil, dil
jne 0x140018680
mov byte [r14 + 0x72], 1
lea rax, [rbp + 7]
cmp qword [rbp - 1], rax
jne 0x14001865e
test rbx, rbx
jne 0x140018637
lea rcx, [rsp + 0x48]
call fcn.14001187f
cmp rax, 0x20
jae 0x140018680
xor r8d, r8d
lea edx, [rbx + 8]
lea rcx, [rsp + 0x48]
call fcn.140011181
lea rdx, [rbp - 0x41]
lea rcx, [rsp + 0x48]
call fcn.140011942
mov rbx, rax
lea rdx, [rbp - 0x59]
lea rcx, [rsp + 0x48]
call fcn.140011942
mov rdi, rax
jmp 0x140018505
movzx r15d, r12w
jmp 0x140018680
cmp ebx, 3
jne 0x140018680
mov rdx, qword [r14 + 0x80]
movzx ecx, word [rbp + 7]
call fcn.14001149c
test al, al
cmovne r15w, r12w
lea rcx, [rsp + 0x48]
call fcn.1400111bd
movzx eax, r15w
mov rcx, qword [rbp + 0x17]
xor rcx, rsp
call fcn.140011910
mov rbx, qword [rsp + 0x140]
add rsp, 0xf0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret