Function at 0x14000d6b0
Capabilities:
Write file on windows

Disassembly:
push rbp
push rbx
push rsi
push rdi
push r12
push r13
push r14
mov rbp, rsp
sub rsp, 0x70
mov qword [rbp - 0x30], 0xfffffffffffffffe
movzx r12d, dx
mov rdi, rcx
mov esi, 0xffff
cmp si, dx
jne 0x14000d6e7
xor r13d, r13d
movzx eax, r13w
jmp 0x14000d9b8
mov rdx, qword [rcx + 0x48]
cmp qword [rdx], 0
je 0x14000d722
mov rdx, qword [rdx]
mov r8, qword [rcx + 0x60]
movsxd rax, dword [r8]
lea rcx, [rdx + rax*2]
cmp rdx, rcx
jae 0x14000d722
dec dword [r8]
mov rcx, qword [rdi + 0x48]
mov rdx, qword [rcx]
lea rax, [rdx + 2]
mov qword [rcx], rax
mov word [rdx], r12w
movzx eax, r12w
jmp 0x14000d9b8
cmp qword [rdi + 0x98], 0
je 0x14000d9b5
mov rdx, qword [rdi + 0x20]
lea rax, [rdi + 0x88]
cmp qword [rdx], rax
jne 0x14000d75e
mov rcx, qword [rdi + 0x78]
mov rax, qword [rdi + 0x70]
mov qword [rdx], rax
mov rax, qword [rdi + 0x40]
mov qword [rax], rcx
sub rcx, rcx
sar rcx, 1
mov rax, qword [rdi + 0x58]
mov dword [rax], ecx
cmp qword [rdi + 0x80], 0
jne 0x14000d78a
mov rdx, qword [rdi + 0x98]
movzx ecx, r12w
call fcn.140026548
cmp ax, si
je 0x14000d9b5
movzx esi, r12w
jmp 0x14000d9b5
mov word [rbp + 0x48], r12w
mov edx, reloc.WS2_32.dll_ntohs
mov qword [rbp - 0x10], rdx
mov byte [rbp - 0x28], 0
xor ecx, ecx
mov qword [rbp - 0x28], rcx
mov qword [rbp - 0x18], 8
lea rax, [rbp - 0x28]
cmp rdx, 0x10
cmovae rax, rcx
mov byte [rax + 8], cl
xor r13d, r13d
mov r9, qword [rbp - 0x10]
mov r8, qword [rbp - 0x18]
mov r10, qword [rbp - 0x28]
nop dword [rax + rax]
lea rax, [rbp - 0x28]
cmp r9, 0x10
cmovae rax, r10
lea rdx, [rbp - 0x28]
cmovae rdx, r10
mov rcx, qword [rdi + 0x80]
mov r10, qword [rcx]
add rax, r8
lea r8, [rbp + 0x50]
mov qword [rsp + 0x38], r8
mov qword [rsp + 0x30], rax
mov qword [rsp + 0x28], rdx
lea rax, [rbp + 0x58]
mov qword [rsp + 0x20], rax
lea r9, [rbp + 0x4a]
lea r8, [rbp + 0x48]
lea rdx, [rdi + 0x8c]
call qword [r10 + 0x28]
test eax, eax
js 0x14000d9a5
cmp eax, 1
jg 0x14000d972
lea rax, [rbp - 0x28]
mov r10, qword [rbp - 0x28]
mov r9, qword [rbp - 0x10]
cmp r9, 0x10
cmovae rax, r10
mov rbx, qword [rbp + 0x50]
sub rbx, rax
je 0x14000d87f
lea rcx, [rbp - 0x28]
cmp r9, 0x10
cmovae rcx, r10
mov r9, qword [rdi + 0x98]
mov r8, rbx
mov edx, 1
call fcn.140024814
cmp rbx, rax
jne 0x14000d937
mov r9, qword [rbp - 0x10]
mov r10, qword [rbp - 0x28]
mov byte [rdi + 0x8a], 1
lea rax, [rbp + 0x48]
cmp qword [rbp + 0x58], rax
jne 0x14000d95e
mov r8, qword [rbp - 0x18]
test rbx, rbx
jne 0x14000d7d0
cmp r8, 0x20
jae 0x14000d953
or rax, 0xffffffffffffffff
sub rax, r8
cmp rax, 8
jbe 0x14000d946
lea rbx, [r8 + 8]
cmp rbx, 0xfffffffffffffffe
ja 0x14000d939
cmp r9, rbx
jae 0x14000d8e5
mov rdx, rbx
lea rcx, [rbp - 0x28]
call fcn.140004520
mov r9, qword [rbp - 0x10]
mov r8, qword [rbp - 0x18]
mov r10, qword [rbp - 0x28]
jmp 0x14000d902
test rbx, rbx
jne 0x14000d90b
mov qword [rbp - 0x18], r13
lea rax, [rbp - 0x28]
cmp r9, 0x10
cmovae rax, r10
mov byte [rax], r13b
jmp 0x14000d7bc
test rbx, rbx
je 0x14000d7d0
lea rax, [rbp - 0x28]
cmp r9, 0x10
cmovae rax, r10
xor ecx, ecx
mov qword [rax + r8], rcx
mov qword [rbp - 0x18], rbx
lea rax, [rbp - 0x28]
cmp qword [rbp - 0x10], 0x10
cmovae rax, qword [rbp - 0x28]
mov byte [rbx + rax], cl
jmp 0x14000d7bc
jmp 0x14000d9a5
lea rcx, str.string_too_long
call fcn.14003cf80
int3
lea rcx, str.string_too_long
call fcn.14003cf80
nop
cmp r9, 0x10
jb 0x14000d9b5
mov rcx, r10
jmp 0x14000d9b0
cmp r9, 0x10
jb 0x14000d96c
mov rcx, r10
call fcn.140023d50
movzx eax, r12w
jmp 0x14000d9b8
cmp eax, 3
jne 0x14000d9a5
mov rdx, qword [rdi + 0x98]
movzx ecx, word [rbp + 0x48]
call fcn.140026548
cmp ax, si
jne 0x14000d98f
mov r12d, esi
cmp qword [rbp - 0x10], 0x10
jb 0x14000d99f
mov rcx, qword [rbp - 0x28]
call fcn.140023d50
movzx eax, r12w
jmp 0x14000d9b8
cmp qword [rbp - 0x10], 0x10
jb 0x14000d9b5
mov rcx, qword [rbp - 0x28]
call fcn.140023d50
movzx eax, si
add rsp, 0x70
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
pop rbp
ret