Function at 0x14022a1f0
Capabilities:
Write file on windows

Disassembly:
mov rax, rsp
push rbp
push rdi
push r14
lea rbp, [rax - 0x5f]
sub rsp, 0x90
mov qword [rbp - 9], 0xfffffffffffffffe
mov qword [rax + 0x18], rbx
mov qword [rax + 0x20], rsi
mov rax, qword [0x1403ddfb8]
xor rax, rsp
mov qword [rbp + 0x37], rax
mov esi, edx
mov rbx, rcx
cmp edx, 0xffffffff
jne 0x14022a231
xor eax, eax
jmp 0x14022a463
mov rax, qword [rcx + 0x40]
mov rdx, qword [rax]
test rdx, rdx
je 0x14022a26b
mov rax, qword [rcx + 0x58]
movsxd r8, dword [rax]
lea rcx, [rdx + r8]
cmp rdx, rcx
jae 0x14022a26b
lea ecx, [r8 - 1]
mov dword [rax], ecx
mov rdx, qword [rbx + 0x40]
mov r8, qword [rdx]
lea rcx, [r8 + 1]
mov qword [rdx], rcx
mov byte [r8], sil
mov eax, esi
jmp 0x14022a463
cmp qword [rbx + 0x80], 0
jne 0x14022a27d
or eax, 0xffffffff
jmp 0x14022a463
mov r8, qword [rbx + 0x18]
lea rax, [rbx + 0x70]
cmp qword [r8], rax
jne 0x14022a2aa
mov rdx, qword [rbx + 0x90]
mov rcx, qword [rbx + 0x88]
mov qword [r8], rcx
mov rax, qword [rbx + 0x38]
mov qword [rax], rcx
sub edx, ecx
mov rax, qword [rbx + 0x50]
mov dword [rax], edx
cmp qword [rbx + 0x68], 0
jne 0x14022a2ce
mov rdx, qword [rbx + 0x80]
movzx ecx, sil
call fcn.140225900
or ebx, 0xffffffff
test al, al
cmovne ebx, esi
jmp 0x14022a461
mov byte [rbp + 0xf], sil
mov qword [rbp + 0x2f], sendto
mov qword [rbp + 0x27], 0
mov byte [rbp + 0x17], 0
xor r8d, r8d
lea edx, [r8 + 8]
lea rcx, [rbp + 0x17]
call fcn.1400535b0
nop
mov rcx, qword [rbp + 0x17]
mov r9, qword [rbp + 0x2f]
nop
lea rdx, [rbp + 0x17]
cmp r9, 0x10
cmovae rdx, rcx
lea r8, [rbp + 0x17]
cmovae r8, rcx
mov rcx, qword [rbx + 0x68]
mov r10, qword [rcx]
add rdx, qword [rbp + 0x27]
lea rax, [rbp - 1]
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x30], rdx
mov qword [rsp + 0x28], r8
lea rax, [rbp + 7]
mov qword [rsp + 0x20], rax
lea r9, [rbp + 0x10]
lea r8, [rbp + 0xf]
lea rdx, [rbx + 0x74]
call qword [r10 + reloc.WS2_32.dll_getservbyport]
test eax, eax
js 0x14022a406
cmp eax, 1
jg 0x14022a3df
lea rax, [rbp + 0x17]
mov rcx, qword [rbp + 0x17]
mov r9, qword [rbp + 0x2f]
cmp r9, 0x10
cmovae rax, rcx
mov rdi, qword [rbp - 1]
sub rdi, rax
je 0x14022a3a9
lea rax, [rbp + 0x17]
cmp r9, 0x10
cmovae rax, rcx
mov r9, qword [rbx + 0x80]
mov r8, rdi
mov edx, 1
mov rcx, rax
call fcn.1402a2450
mov r9, qword [rbp + 0x2f]
mov rcx, qword [rbp + 0x17]
cmp rdi, rax
jne 0x14022a40e
mov byte [rbx + 0x71], 1
lea rax, [rbp + 0xf]
cmp qword [rbp + 7], rax
jne 0x14022a3db
test rdi, rdi
jne 0x14022a300
cmp qword [rbp + 0x27], 0x20
jae 0x14022a40e
xor r8d, r8d
lea edx, [rdi + 8]
lea rcx, [rbp + 0x17]
call fcn.1400479c0
jmp 0x14022a2f7
mov ebx, esi
jmp 0x14022a411
cmp eax, 3
jne 0x14022a406
mov rdx, qword [rbx + 0x80]
movzx ecx, byte [rbp + 0xf]
call fcn.140225900
or ebx, 0xffffffff
test al, al
cmovne ebx, esi
mov r9, qword [rbp + 0x2f]
mov rcx, qword [rbp + 0x17]
jmp 0x14022a411
mov r9, qword [rbp + 0x2f]
mov rcx, qword [rbp + 0x17]
or ebx, 0xffffffff
cmp r9, 0x10
jb 0x14022a461
lea rax, [r9 + 1]
cmp rax, 0x1000
jb 0x14022a45c
test byte [rbp + 0x17], 0x1f
je 0x14022a42f
call fcn.14029051c
int3
mov rax, qword [rcx - 8]
cmp rax, rcx
jb 0x14022a43e
call fcn.14029051c
int3
sub rcx, rax
cmp rcx, 8
jae 0x14022a44d
call fcn.14029051c
int3
cmp rcx, 0x27
jbe 0x14022a459
call fcn.14029051c
int3
mov rcx, rax
call fcn.14026d850
mov eax, ebx
mov rcx, qword [rbp + 0x37]
xor rcx, rsp
call fcn.14026d870
lea r11, [rsp + 0x90]
mov rbx, qword [r11 + 0x30]
mov rsi, qword [r11 + 0x38]
mov rsp, r11
pop r14
pop rdi
pop rbp
ret