Function at 0x14007a700
Capabilities:
Write file on windows

Disassembly:
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
lea rbp, [rsp - 0x27]
sub rsp, 0x90
mov qword [rbp - 0x11], 0xfffffffffffffffe
mov qword [rsp + 0xe0], rbx
mov rax, qword [0x140232230]
xor rax, rsp
mov qword [rbp + 0x17], rax
movzx r14d, dx
mov rdi, rcx
mov esi, 0xffff
cmp si, dx
jne 0x14007a753
xor r15d, r15d
movzx eax, r15w
jmp 0x14007a9fa
mov rax, qword [rcx + 0x40]
mov r8, qword [rax]
test r8, r8
je 0x14007a790
mov rax, qword [rcx + 0x58]
movsxd r9, dword [rax]
lea rdx, [r8 + r9*2]
cmp r8, rdx
jae 0x14007a790
lea ecx, [r9 - 1]
mov dword [rax], ecx
mov rdx, qword [rdi + 0x40]
mov r8, qword [rdx]
lea rcx, [r8 + 2]
mov qword [rdx], rcx
mov word [r8], r14w
movzx eax, r14w
jmp 0x14007a9fa
cmp qword [rcx + 0x90], 0
je 0x14007a9f7
mov rdx, qword [rcx + 0x18]
lea rax, [rcx + 0x80]
cmp qword [rdx], rax
jne 0x14007a7cc
mov rcx, qword [rcx + 0x70]
mov rax, qword [rdi + 0x68]
mov qword [rdx], rax
mov rax, qword [rdi + 0x38]
mov qword [rax], rcx
sub rcx, rcx
sar rcx, 1
mov rax, qword [rdi + 0x50]
mov dword [rax], ecx
cmp qword [rdi + 0x78], 0
jne 0x14007a7f5
mov rdx, qword [rdi + 0x90]
movzx ecx, r14w
call fcn.14016cc40
cmp ax, si
je 0x14007a9f7
movzx esi, r14w
jmp 0x14007a9f7
mov word [rbp - 0x29], r14w
xor r15d, r15d
mov qword [rbp + 7], r15
mov qword [rbp + 0xf], r15
mov r13d, reloc.WS2_32.dll_ntohs
mov qword [rbp + 0xf], r13
mov qword [rbp + 7], r15
mov byte [rbp - 9], r15b
xor ecx, ecx
mov qword [rbp - 9], rcx
mov qword [rbp + 7], 8
lea rax, [rbp - 9]
cmp r13, 0x10
cmovae rax, rcx
mov byte [rax + 8], cl
mov r9, qword [rbp + 0xf]
mov r8, qword [rbp + 7]
mov r10, qword [rbp - 9]
lea rax, [rbp - 9]
cmp r9, 0x10
cmovae rax, r10
lea rdx, [rbp - 9]
cmovae rdx, r10
mov rcx, qword [rdi + 0x78]
mov r10, qword [rcx]
add rax, r8
lea r8, [rbp - 0x19]
mov qword [rsp + 0x38], r8
mov qword [rsp + 0x30], rax
mov qword [rsp + 0x28], rdx
lea rax, [rbp - 0x21]
mov qword [rsp + 0x20], rax
lea r9, [rbp - 0x27]
lea r8, [rbp - 0x29]
lea rdx, [rdi + 0x84]
call qword [r10 + gethostname]
test eax, eax
js 0x14007a9db
cmp eax, 1
jg 0x14007a9bd
lea rax, [rbp - 9]
mov r10, qword [rbp - 9]
mov r9, qword [rbp + 0xf]
cmp r9, 0x10
cmovae rax, r10
mov rbx, qword [rbp - 0x19]
sub rbx, rax
je 0x14007a8ec
lea rcx, [rbp - 9]
cmp r9, 0x10
cmovae rcx, r10
mov r9, qword [rdi + 0x90]
mov r8, rbx
mov edx, 1
call fcn.140168220
cmp rbx, rax
jne 0x14007a9db
mov r9, qword [rbp + 0xf]
mov r10, qword [rbp - 9]
mov byte [rdi + 0x82], 1
lea rax, [rbp - 0x29]
cmp qword [rbp - 0x21], rax
jne 0x14007a9d7
mov r8, qword [rbp + 7]
test rbx, rbx
jne 0x14007a840
cmp r8, 0x20
jae 0x14007a9db
or rax, 0xffffffffffffffff
sub rax, r8
cmp rax, 8
jbe 0x14007a9b0
lea rbx, [r8 + 8]
cmp rbx, 0xfffffffffffffffe
ja 0x14007a9a3
cmp r9, rbx
jae 0x14007a952
mov rdx, rbx
lea rcx, [rbp - 9]
call fcn.140001dc0
mov r9, qword [rbp + 0xf]
mov r8, qword [rbp + 7]
mov r10, qword [rbp - 9]
jmp 0x14007a96e
test rbx, rbx
jne 0x14007a977
mov qword [rbp + 7], r15
lea rax, [rbp - 9]
cmp r9, 0x10
cmovae rax, r10
mov byte [rax], bl
jmp 0x14007a834
test rbx, rbx
je 0x14007a840
lea rax, [rbp - 9]
cmp r9, 0x10
cmovae rax, r10
xor ecx, ecx
mov qword [r8 + rax], rcx
mov qword [rbp + 7], rbx
lea rax, [rbp - 9]
cmp qword [rbp + 0xf], 0x10
cmovae rax, qword [rbp - 9]
mov byte [rbx + rax], cl
jmp 0x14007a834
lea rcx, str.string_too_long
call fcn.140144f6c
int3
lea rcx, str.string_too_long
call fcn.140144f6c
int3
cmp eax, 3
jne 0x14007a9db
mov rdx, qword [rdi + 0x90]
movzx ecx, word [rbp - 0x29]
call fcn.14016cc40
cmp ax, si
je 0x14007a9db
movzx esi, r14w
cmp qword [rbp + 0xf], 0x10
jb 0x14007a9eb
mov rcx, qword [rbp - 9]
call fcn.1401669a0
mov qword [rbp + 0xf], r13
mov qword [rbp + 7], r15
mov byte [rbp - 9], 0
movzx eax, si
mov rcx, qword [rbp + 0x17]
xor rcx, rsp
call fcn.140166980
mov rbx, qword [rsp + 0xe0]
add rsp, 0x90
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret