Function at 0x18000aac0
Capabilities:
Write file on windows

Disassembly:
mov rax, rsp
push rbp
push r12
push r13
push r14
push r15
lea rbp, [rax - 0x5f]
sub rsp, 0xd0
mov qword [rbp - 0x29], 0xfffffffffffffffe
mov qword [rax + 0x10], rbx
mov qword [rax + 0x18], rsi
mov qword [rax + 0x20], rdi
mov rax, qword [0x18005d0e0]
xor rax, rsp
mov qword [rbp + 0x2f], rax
mov rsi, rcx
mov qword [rbp - 0x51], rcx
lea rcx, [0x18005d078]
mov rax, qword [0x18005d078]
call qword [rax + 0x18]
add rax, 0x18
mov qword [rbp - 0x61], rax
lea rdx, [0x18004e29c]
mov eax, 1
test rdx, 0xffffffffffff0000
jne 0x18000ab4e
movzx ebx, dx
mov ecx, ebx
call fcn.180001110
test rax, rax
je 0x18000ab5b
mov r8d, ebx
mov rdx, rax
lea rcx, [rbp - 0x61]
call fcn.180001a00
jmp 0x18000ab5b
mov r8d, eax
lea rcx, [rbp - 0x61]
call fcn.180001b40
nop
xor r13b, r13b
mov rcx, qword [rsi + 0x10]
or r14d, 0xffffffff
test rcx, rcx
je 0x18000adf0
xor r15d, r15d
mov r12d, r15d
mov qword [rbp - 0x49], r15
mov edi, r15d
mov qword [rbp - 0x41], r15
mov qword [rbp - 0x39], r15
mov edx, dword [rsi + 8]
test edx, edx
je 0x18000aba3
lea r9, [rbp - 0x49]
lea r8, [0x18004e270]
call fcn.180020050
mov rdi, qword [rbp - 0x41]
mov r12, qword [rbp - 0x49]
lea rcx, [0x18005d078]
mov rax, qword [0x18005d078]
call qword [rax + 0x18]
lea rbx, [rax + 0x18]
mov qword [rbp - 0x59], rbx
mov qword [rbp - 9], sendto
mov qword [rbp - 0x11], r15
mov byte [rbp - 0x21], 0
sub rdi, r12
sar rdi, 3
cmp rdi, 1
jb 0x18000ac3a
mov rdx, qword [r12]
lea rcx, [rdx - 0x18]
lea rsi, [rbx - 0x18]
cmp rcx, rsi
je 0x18000ac3a
cmp dword [rsi + 0x10], 0
jl 0x18000ac29
mov rax, qword [rsi]
cmp qword [rcx], rax
jne 0x18000ac29
call fcn.180001790
mov rbx, rax
mov ecx, r14d
lock xadd dword [rsi + 0x10], ecx
dec ecx
test ecx, ecx
jg 0x18000ac1b
mov rcx, qword [rsi]
mov r8, qword [rcx]
mov rdx, rsi
call qword [rreloc.WS2_32.dll_htonl + 8]
add rbx, 0x18
mov qword [rbp - 0x59], rbx
mov r12, qword [rbp - 0x49]
jmp 0x18000ac3a
mov r8d, dword [rdx - 0x10]
lea rcx, [rbp - 0x59]
call fcn.180001b40
mov rbx, qword [rbp - 0x59]
cmp rdi, 2
jb 0x18000acda
mov rax, qword [r12 + 8]
mov r8d, dword [rax - 0x10]
mov rdx, rax
lea rcx, [rbp + 7]
call fcn.18000a4c0
mov rdi, rax
lea rax, [rbp - 0x21]
cmp rax, rdi
je 0x18000acca
cmp qword [rbp - 9], 0x10
jb 0x18000ac75
mov rcx, qword [rbp - 0x21]
call fcn.18002f934
mov qword [rbp - 9], sendto
mov qword [rbp - 0x11], r15
mov byte [rbp - 0x21], 0
cmp qword [rdi + 0x18], 0x10
jae 0x18000aca1
mov r8, qword [rdi + 0x10]
inc r8
mov rdx, rdi
lea rcx, [rbp - 0x21]
call fcn.18002fb80
jmp 0x18000acab
mov rax, qword [rdi]
mov qword [rbp - 0x21], rax
mov qword [rdi], r15
mov rax, qword [rdi + 0x10]
mov qword [rbp - 0x11], rax
mov rax, qword [rdi + 0x18]
mov qword [rbp - 9], rax
mov qword [rdi + 0x18], sendto
mov qword [rdi + 0x10], r15
mov byte [rdi], 0
cmp qword [rbp + 0x1f], 0x10
jb 0x18000acda
mov rcx, qword [rbp + 7]
call fcn.18002f934
mov rdi, qword [rbp - 0x11]
lea r15, [rbp - 0x21]
cmp qword [rbp - 9], 0x10
cmovae r15, qword [rbp - 0x21]
xor sil, sil
lea rdx, [0x18004e3ec]
mov rcx, rbx
call fcn.180030e68
mov r12, rax
test rax, rax
je 0x18000ad41
test edi, edi
je 0x18000ad24
mov edi, edi
mov r9, rax
mov r8d, edi
mov edx, 1
mov rcx, r15
call fcn.180031000
cmp rax, rdi
jne 0x18000ad27
mov sil, 1
mov rcx, r12
call fcn.18003110c
movzx r13d, r13b
test sil, sil
mov edi, 1
cmovne r13d, edi
jmp 0x18000ad46
mov edi, 1
cmp qword [rbp - 9], 0x10
jb 0x18000ad56
mov rcx, qword [rbp - 0x21]
call fcn.18002f934
mov qword [rbp - 9], sendto
mov qword [rbp - 0x11], 0
mov byte [rbp - 0x21], 0
lea rdx, [rbx - 0x18]
mov eax, r14d
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x18000ad86
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_htonl]
nop
mov rbx, qword [rbp - 0x49]
test rbx, rbx
je 0x18000add4
cmp rbx, qword [rbp - 0x41]
je 0x18000adcc
nop word [rax + rax]
mov rdx, qword [rbx]
sub rdx, 0x18
mov eax, r14d
lock xadd dword [rdx + 0x10], eax
dec eax
test eax, eax
jg 0x18000adbe
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_htonl]
add rbx, 8
cmp rbx, qword [rbp - 0x41]
jne 0x18000ada0
mov rbx, qword [rbp - 0x49]
mov rcx, rbx
call fcn.18002f934
test r13b, r13b
je 0x18000adec
mov r8d, edi
lea rdx, [0x18004e26c]
lea rcx, [rbp - 0x61]
call fcn.180001b40
mov rsi, qword [rbp - 0x51]
mov rbx, qword [rbp - 0x61]
mov r12d, dword [rbx - 0x10]
mov edi, dword [rsi + 4]
mov rax, qword [0x18005fdf8]
mov esi, dword [rax - 0x10]
lea ecx, [rsi + r12 + 0xd]
call fcn.18002f604
mov r13, rax
mov byte [rax], gethostbyname
mov dword [rax + 1], edi
mov dword [rax + 5], esi
mov dword [rax + 9], r12d
mov r8d, esi
lea rcx, [rax + 0xd]
mov rdx, qword [0x18005fdf8]
call fcn.18002fb80
lea edi, [rsi + 0xd]
mov r8d, r12d
mov ecx, edi
add rcx, r13
mov rdx, rbx
call fcn.18002fb80
add edi, r12d
lea eax, [rdi*4 + 0x800]
mov dword [rbp - 0x69], eax
inc eax
movsxd rcx, eax
call fcn.18002f604
mov rsi, rax
lea r9, [rax + 5]
lea rax, [rbp - 0x69]
mov qword [rsp + 0x20], rax
lea r8, [0x18004e7a0]
mov edx, edi
mov rcx, r13
call fcn.180023f20
mov byte [rsi], 0x30
mov ecx, dword [rbp - 0x69]
mov dword [rsi + 1], ecx
lea edi, [rcx + 5]
mov rcx, r13
call fcn.18002f934
mov edx, edi
mov rcx, rsi
call fcn.18002c4d0
mov rcx, rsi
call fcn.18002f934
nop
lea rdx, [rbx - 0x18]
lock xadd dword [rdx + 0x10], r14d
dec r14d
test r14d, r14d
jg 0x18000aebf
mov rcx, qword [rdx]
mov rax, qword [rcx]
call qword [rax + reloc.WS2_32.dll_htonl]
mov rcx, qword [rbp + 0x2f]
xor rcx, rsp
call fcn.18002f950
lea r11, [rsp + 0xd0]
mov rbx, qword [r11 + 0x38]
mov rsi, qword [r11 + 0x40]
mov rdi, qword [r11 + 0x48]
mov rsp, r11
pop r15
pop r14
pop r13
pop r12
pop rbp
ret