Function at 0x14015e710
Capabilities:
Write file on windows

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x58
movsxd r12, dword [r8 + 4]
mov byte [rsp + 0x35], 0
mov rsi, rcx
mov ebx, edx
mov rdi, r8
test dl, 0x40
jne 0x14015e8e8
xor ebp, ebp
test dl, 0x80
jne 0x14015e839
test bl, 0x20
je 0x14015e7f0
mov eax, ebx
and eax, 0x10
cmp eax, 1
sbb r12d, r12d
and r12d, 0xfffffff8
add r12d, 9
lea rax, [rsp + 0x35]
mov edx, dword [rdi]
mov rcx, qword [rdi + 8]
mov r8d, r12d
mov qword [rsp + 0x28], 0
and ebx, 0x40f
mov qword [rsp + 0x20], rax
mov r9d, ebx
mov r13d, ebx
call fcn.14015db00
test eax, eax
js 0x14015e7d0
cmp byte [rsp + 0x35], 0
lea ebx, [rax + rbp]
je 0x14015e960
add ebx, 2
test rsi, rsi
je 0x14015e7d5
lea rbp, [0x1402b9595]
mov r9, rsi
mov r8d, 1
mov edx, 1
mov rcx, rbp
call sub.msvcrt.dll_fwrite
cmp rax, 1
je 0x14015e998
nop
mov ebx, 0xffffffff
mov eax, ebx
add rsp, 0x58
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
lea eax, [r12 - 1]
cmp eax, 0x1d
ja 0x14015e830
lea rax, [0x1402b95d0]
movsx r12d, byte [rax + r12]
mov eax, r12d
cmp r12b, 0xff
je 0x14015e830
test bl, 0x10
je 0x14015e761
or eax, 8
test r12d, r12d
mov r12d, 1
movsx eax, al
cmovne r12d, eax
jmp 0x14015e761
test bh, 1
je 0x14015e74e
test rsi, rsi
je 0x14015eafc
mov r9, rsi
mov r8d, 1
mov edx, 1
lea rcx, [0x1402b9593]
call sub.msvcrt.dll_fwrite
cmp rax, 1
jne 0x14015e7d0
and bh, 2
jne 0x14015e9e8
movsxd r12, dword [rdi]
mov r14, qword [rdi + 8]
mov rbx, r12
add r12, r14
cmp r12, r14
je 0x14015eb10
lea rdi, [0x1402b95b0]
lea r13, [rsp + 0x40]
jmp 0x14015e8a5
add r14, 1
cmp r12, r14
je 0x14015eb07
movzx eax, byte [r14]
xor edx, edx
mov r9, rsi
mov r8d, 2
mov ecx, eax
and eax, 0xf
shr cl, 4
and ecx, 0xf
mov dl, byte [rdi + rcx]
mov dh, byte [rdi + rax]
mov rcx, r13
mov word [rsp + 0x40], dx
mov edx, 1
call sub.msvcrt.dll_fwrite
cmp rax, 2
jne 0x14015e7d0
jmp 0x14015e898
mov ecx, r12d
call fcn.140167fb0
mov rcx, rax
mov r13, rax
call sub.msvcrt.dll_strlen
mov rbp, rax
test rsi, rsi
je 0x14015eaf0
mov edx, 1
mov r9, rsi
movsxd r8, eax
mov rcx, r13
call sub.msvcrt.dll_fwrite
mov rdx, rax
mov eax, ebp
cmp rdx, rax
jne 0x14015e7d0
mov r9, rsi
mov r8d, 1
mov edx, 1
lea rcx, [0x1402b9591]
call sub.msvcrt.dll_fwrite
cmp rax, 1
jne 0x14015e7d0
add ebp, 1
test bl, 0x80
je 0x14015e745
jmp 0x14015e842
test rsi, rsi
je 0x14015e7d5
mov edx, dword [rdi]
mov rcx, qword [rdi + 8]
mov qword [rsp + 0x28], rsi
mov r9d, r13d
mov qword [rsp + 0x20], 0
mov r8d, r12d
call fcn.14015db00
test eax, eax
jns 0x14015e7d5
jmp 0x14015e7d0
mov edx, dword [rdi]
mov rcx, qword [rdi + 8]
mov qword [rsp + 0x28], rsi
mov r9d, r13d
mov qword [rsp + 0x20], 0
mov r8d, r12d
call fcn.14015db00
test eax, eax
js 0x14015e7d0
mov r9, rsi
mov r8d, 1
mov edx, 1
mov rcx, rbp
call sub.msvcrt.dll_fwrite
cmp rax, 1
jne 0x14015e7d0
jmp 0x14015e7d5
mov eax, dword [rdi + 4]
mov qword [rsp + 0x48], rdi
lea rdi, [rsp + 0x40]
xor edx, edx
mov rcx, rdi
mov dword [rsp + 0x40], eax
call fcn.140065d00
mov ebx, eax
test eax, eax
jle 0x14015e7d0
movsxd r12, eax
mov r8d, 0x11d
lea rdx, str.crypto_asn1_a_strex.c
mov rcx, r12
call fcn.1400c4810
mov r13, rax
test rax, rax
je 0x14015eb1c
lea rdx, [rsp + 0x38]
mov rcx, rdi
mov qword [rsp + 0x38], rax
call fcn.140065d00
test rsi, rsi
je 0x14015eac1
add r12, r13
mov r15, r13
lea r14, [rsp + 0x36]
lea rdi, [0x1402b95b0]
nop word [rax + rax]
movzx eax, byte [r15]
xor edx, edx
mov r9, rsi
mov r8d, 2
mov ecx, eax
and eax, 0xf
shr cl, 4
and ecx, 0xf
mov dl, byte [rdi + rcx]
mov dh, byte [rdi + rax]
mov rcx, r14
mov word [rsp + 0x36], dx
mov edx, 1
call sub.msvcrt.dll_fwrite
cmp rax, 2
je 0x14015eab8
mov r8d, 0x124
lea rdx, str.crypto_asn1_a_strex.c
mov rcx, r13
call fcn.1400c47e0
jmp 0x14015e7d0
add r15, 1
cmp r12, r15
jne 0x14015ea60
add ebx, ebx
mov r8d, 0x124
lea rdx, str.crypto_asn1_a_strex.c
mov rcx, r13
call fcn.1400c47e0
test ebx, ebx
js 0x14015e7d0
add ebx, 1
add ebx, ebp
jmp 0x14015e7d5
add ebp, 1
test bl, 0x80
je 0x14015e745
and bh, 2
jne 0x14015e9e8
mov ebx, dword [rdi]
add ebx, ebx
jns 0x14015eae0
jmp 0x14015e7d0
mov ebx, 1
add ebx, ebp
jmp 0x14015e7d5
mov r8d, 0x41
mov edx, 0x7d
mov ecx, 0xd
mov dword [rsp + 0x20], 0x11e
lea r9, str.crypto_asn1_a_strex.c
call fcn.1400a0f90
jmp 0x14015e7d0