Function at 0x14001cf60
Capabilities:
Write file on windows

Disassembly:
push rbx
push rdi
push r12
sub rsp, 0x30
mov rdi, qword [0x140282e30]
mov rax, qword [rdi + 0x58]
test rax, rax
je 0x14001d039
cmp byte [rdi + 1], 0
je 0x14001d039
mov byte [rax + 0x18], 0
mov rbx, qword [rdi + 0x58]
test rbx, rbx
je 0x14001d039
mov rcx, rbx
call fcn.140041b50
mov rcx, qword [rbx + 0x80]
test rcx, rcx
je 0x14001cfca
mov rax, qword [0x140282e30]
test rax, rax
je 0x14001cfbe
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov rcx, qword [rbx + 0x70]
test rcx, rcx
je 0x14001cff1
mov rax, qword [0x140282e30]
test rax, rax
je 0x14001cfe5
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov rcx, qword [rbx + 0x60]
test rcx, rcx
je 0x14001d018
mov rax, qword [0x140282e30]
test rax, rax
je 0x14001d00c
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov rax, qword [0x140282e30]
test rax, rax
je 0x14001d02a
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
mov rcx, rbx
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
xor r12d, r12d
mov qword [rdi + 0x58], r12
mov rcx, qword [rdi + 0x3c60]
test rcx, rcx
je 0x14001d078
mov rax, qword [0x140282e30]
mov qword [rdi + 0x3c58], r12
test rax, rax
je 0x14001d065
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x3c60], r12
cmp byte [rdi], r12b
je 0x14001d97d
mov qword [rsp + 0x60], rsi
mov qword [rsp + 0x28], r14
cmp byte [rdi + 0x5ba1], r12b
je 0x14001d0f3
mov rbx, qword [rdi + 0x20]
test rbx, rbx
je 0x14001d0f3
mov rax, qword [0x140282e30]
lea rcx, [rsp + 0x50]
mov qword [rsp + 0x50], r12
mov dword [rax + 0x5ba4], r12d
call fcn.1400311b0
lea rdx, [0x14010a5e4]
mov rcx, rbx
mov rsi, rax
call fcn.14001adc0
mov rbx, rax
test rax, rax
je 0x14001d0f3
mov r8, qword [rsp + 0x50]
mov r9, rax
mov edx, 1
mov rcx, rsi
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fwrite]
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
mov ebx, r12d
cmp dword [rdi + 0x5be8], r12d
jle 0x14001d12f
mov rsi, r12
mov rax, qword [rdi + 0x5bf0]
cmp dword [rsi + rax + 4], 6
jne 0x14001d121
movsxd rdx, ebx
mov rcx, rdi
shl rdx, 5
add rdx, rax
call qword [rsi + rax + reloc.WS2_32.dll_recv]
inc ebx
add rsi, 0x20
cmp ebx, dword [rdi + 0x5be8]
jl 0x14001d102
mov esi, r12d
cmp dword [rdi + 0x3e70], r12d
jle 0x14001d187
mov r14, r12
nop
mov rax, qword [rdi + 0x3e78]
mov rbx, qword [r14 + rax]
test rbx, rbx
je 0x14001d179
mov rcx, rbx
call fcn.14001de90
mov rax, qword [0x140282e30]
test rax, rax
je 0x14001d16a
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
mov rcx, rbx
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
inc esi
add r14, 8
cmp esi, dword [rdi + 0x3e70]
jl 0x14001d140
mov rcx, qword [rdi + 0x3e78]
test rcx, rcx
je 0x14001d1bf
mov rax, qword [0x140282e30]
mov qword [rdi + 0x3e70], r12
test rax, rax
je 0x14001d1ac
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x3e78], r12
mov rcx, qword [rdi + 0x3e88]
test rcx, rcx
je 0x14001d1f7
mov rax, qword [0x140282e30]
mov qword [rdi + 0x3e80], r12
test rax, rax
je 0x14001d1e4
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x3e88], r12
mov rcx, qword [rdi + 0x3e98]
test rcx, rcx
je 0x14001d22f
mov rax, qword [0x140282e30]
mov qword [rdi + 0x3e90], r12
test rax, rax
je 0x14001d21c
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x3e98], r12
mov qword [rdi + 0x3ed0], r12
mov rcx, qword [rdi + 0x3ea8]
test rcx, rcx
je 0x14001d26e
mov rax, qword [0x140282e30]
mov qword [rdi + 0x3ea0], r12
test rax, rax
je 0x14001d25b
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x3ea8], r12
mov rcx, qword [rdi + 0x3eb8]
test rcx, rcx
je 0x14001d2a6
mov rax, qword [0x140282e30]
mov qword [rdi + 0x3eb0], r12
test rax, rax
je 0x14001d293
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x3eb8], r12
lea rcx, [rdi + 0x4608]
mov qword [rdi + 0x48b0], r12
mov qword [rdi + 0x3ee0], r12
mov qword [rdi + 0x3ed8], r12
mov qword [rdi + 0x3f68], r12
mov qword [rdi + 0x3f50], r12
mov qword [rdi + 0x3ee8], r12
call fcn.140019130
mov rcx, qword [rdi + 0x4820]
test rcx, rcx
je 0x14001d314
mov rax, qword [0x140282e30]
mov qword [rdi + 0x4818], r12
test rax, rax
je 0x14001d301
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x4820], r12
mov rcx, qword [rdi + 0x4830]
test rcx, rcx
je 0x14001d34c
mov rax, qword [0x140282e30]
mov qword [rdi + 0x4828], r12
test rax, rax
je 0x14001d339
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x4830], r12
mov rcx, qword [rdi + 0x4840]
test rcx, rcx
je 0x14001d384
mov rax, qword [0x140282e30]
mov qword [rdi + 0x4838], r12
test rax, rax
je 0x14001d371
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x4840], r12
mov rcx, qword [rdi + 0x4880]
test rcx, rcx
je 0x14001d3bc
mov rax, qword [0x140282e30]
mov qword [rdi + 0x4878], r12
test rax, rax
je 0x14001d3a9
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x4880], r12
mov rcx, qword [rdi + 0x4890]
test rcx, rcx
je 0x14001d3f4
mov rax, qword [0x140282e30]
mov qword [rdi + 0x4888], r12
test rax, rax
je 0x14001d3e1
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x4890], r12
mov r14d, r12d
mov qword [rsp + 0x58], rbp
cmp dword [rdi + 0x48a0], r12d
jle 0x14001d4ec
mov qword [rsp + 0x20], r15
mov r15, r12
mov rax, qword [rdi + 0x48a8]
mov rbp, qword [r15 + rax]
test rbp, rbp
je 0x14001d4d3
mov rbx, qword [rbp + 0x38]
test rbx, rbx
je 0x14001d457
mov rcx, rbx
call fcn.140018ff0
mov rax, qword [0x140282e30]
test rax, rax
je 0x14001d448
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
mov rcx, rbx
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov rbx, qword [rbp + 0x40]
test rbx, rbx
je 0x14001d489
mov rcx, rbx
call fcn.140018ff0
mov rax, qword [0x140282e30]
test rax, rax
je 0x14001d47a
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
mov rcx, rbx
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov ebx, 2
lea rsi, [rbp + 0x98]
nop word [rax + rax]
sub rsi, 0x10
mov rcx, rsi
call fcn.1400328e0
sub rbx, 1
jne 0x14001d4a0
mov rax, qword [0x140282e30]
test rax, rax
je 0x14001d4c4
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
mov rcx, rbp
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
inc r14d
add r15, 8
cmp r14d, dword [rdi + 0x48a0]
jl 0x14001d411
mov r15, qword [rsp + 0x20]
mov rcx, qword [rdi + 0x48a8]
mov r14, qword [rsp + 0x28]
test rcx, rcx
je 0x14001d529
mov rax, qword [0x140282e30]
mov qword [rdi + 0x48a0], r12
test rax, rax
je 0x14001d516
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x48a8], r12
lea rcx, [rdi + 0x4b88]
call fcn.1400320f0
mov rcx, qword [rdi + 0x4bb8]
test rcx, rcx
je 0x14001d56d
mov rax, qword [0x140282e30]
mov qword [rdi + 0x4bb0], r12
test rax, rax
je 0x14001d55a
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x4bb8], r12
mov rcx, qword [rdi + 0x4bc8]
test rcx, rcx
je 0x14001d5a5
mov rax, qword [0x140282e30]
mov qword [rdi + 0x4bc0], r12
test rax, rax
je 0x14001d592
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x4bc8], r12
mov ebx, r12d
cmp dword [rdi + 0x4b08], r12d
jle 0x14001d5fd
mov rsi, r12
nop dword [rax]
nop dword [rax + rax]
mov rax, qword [rdi + 0x4b10]
mov rcx, qword [rsi + rax + 0x20]
test rcx, rcx
je 0x14001d5ef
mov rax, qword [0x140282e30]
test rax, rax
je 0x14001d5e3
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
inc ebx
add rsi, 0x28
cmp ebx, dword [rdi + 0x4b08]
jl 0x14001d5c0
mov rcx, qword [rdi + 0x4b10]
test rcx, rcx
je 0x14001d635
mov rax, qword [0x140282e30]
mov qword [rdi + 0x4b08], r12
test rax, rax
je 0x14001d622
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x4b10], r12
lea rcx, [rdi + 0x4b38]
call fcn.140032290
mov esi, r12d
cmp dword [rdi + 0x4b28], r12d
jle 0x14001d699
mov rbp, r12
mov rbx, qword [rdi + 0x4b30]
lea rcx, [rbx + 0x10]
add rcx, rbp
call fcn.140041090
mov rcx, qword [rbx + rbp + 0x20]
test rcx, rcx
je 0x14001d68b
mov rax, qword [0x140282e30]
test rax, rax
je 0x14001d67f
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
inc esi
add rbp, 0x70
cmp esi, dword [rdi + 0x4b28]
jl 0x14001d650
mov rcx, qword [rdi + 0x4b30]
mov rsi, qword [rsp + 0x60]
mov rbp, qword [rsp + 0x58]
test rcx, rcx
je 0x14001d6db
mov rax, qword [0x140282e30]
mov qword [rdi + 0x4b28], r12
test rax, rax
je 0x14001d6c8
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x4b30], r12
mov rcx, qword [rdi + 0x4b78]
test rcx, rcx
je 0x14001d713
mov rax, qword [0x140282e30]
mov qword [rdi + 0x4b70], r12
test rax, rax
je 0x14001d700
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x4b78], r12
mov rcx, qword [rdi + 0x5b68]
test rcx, rcx
je 0x14001d74b
mov rax, qword [0x140282e30]
mov qword [rdi + 0x5b60], r12
test rax, rax
je 0x14001d738
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x5b68], r12
mov rcx, qword [rdi + 0x5b78]
test rcx, rcx
je 0x14001d783
mov rax, qword [0x140282e30]
mov qword [rdi + 0x5b70], r12
test rax, rax
je 0x14001d770
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x5b78], r12
mov rcx, qword [rdi + 0x4c08]
test rcx, rcx
je 0x14001d7bb
mov rax, qword [0x140282e30]
mov qword [rdi + 0x4c00], r12
test rax, rax
je 0x14001d7a8
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x4c08], r12
mov rcx, qword [rdi + 0x4c18]
test rcx, rcx
je 0x14001d7f3
mov rax, qword [0x140282e30]
mov qword [rdi + 0x4c10], r12
test rax, rax
je 0x14001d7e0
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x4c18], r12
mov rcx, qword [rdi + 0x4c28]
test rcx, rcx
je 0x14001d82b
mov rax, qword [0x140282e30]
mov qword [rdi + 0x4c20], r12
test rax, rax
je 0x14001d818
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x4c28], r12
mov rcx, qword [rdi + 0x5bd0]
test rcx, rcx
je 0x14001d863
mov rax, qword [0x140282e30]
mov qword [rdi + 0x5bc8], r12
test rax, rax
je 0x14001d850
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x5bd0], r12
mov rcx, qword [rdi + 0x5bc0]
test rcx, rcx
je 0x14001d89b
mov rax, qword [0x140282e30]
mov qword [rdi + 0x5bb8], r12
test rax, rax
je 0x14001d888
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x5bc0], r12
cmp qword [rdi + 0x5c40], r12
je 0x14001d8cb
mov rbx, qword [rdi + 0x5c40]
mov ecx, 1
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
cmp rbx, rax
je 0x14001d8c4
mov rcx, rbx
call qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll_fclose]
mov qword [rdi + 0x5c40], r12
mov rcx, qword [rdi + 0x5c50]
test rcx, rcx
je 0x14001d903
mov rax, qword [0x140282e30]
mov qword [rdi + 0x5c48], r12
test rax, rax
je 0x14001d8f0
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x5c50], r12
mov rcx, qword [rdi + 0x5c88]
test rcx, rcx
je 0x14001d93b
mov rax, qword [0x140282e30]
mov qword [rdi + 0x5c80], r12
test rax, rax
je 0x14001d928
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x5c88], r12
mov rcx, qword [rdi + 0x5c98]
test rcx, rcx
je 0x14001d973
mov rax, qword [0x140282e30]
mov qword [rdi + 0x5c90], r12
test rax, rax
je 0x14001d960
dec dword [rax + 0xf4]
mov rdx, qword [0x140282e20]
call sub.api_ms_win_crt_heap_l1_1_0.dll_free
mov qword [rdi + 0x5c98], r12
mov dword [rdi + 0x5ca0], r12d
mov byte [rdi], r12b
add rsp, 0x30
pop r12
pop rdi
pop rbx
ret