Function at 0x1400820d0
Capabilities:
Set socket configuration

Disassembly:
push rbp
push rbx
push r15
lea rbp, [rsp - 0x47]
sub rsp, 0x90
mov rax, qword [0x140492fc0]
xor rax, rsp
mov qword [rbp + 0x2f], rax
mov rbx, rcx
mov qword [rsp + 0x80], r14
lea rcx, [rbp - 0x19]
movzx r15d, r8w
call fcn.140008240
lea rcx, [rbp - 0x19]
call fcn.1400495e0
test eax, eax
jne 0x14008214e
lea rcx, [rbp - 0x19]
call fcn.1400499d0
and eax, 0xffff0000
cmp eax, 0xefff0000
jne 0x14008214e
mov edx, 6
lea rcx, [rbp - 9]
call fcn.140048180
mov rdx, qword [rbp - 0x19]
mov rcx, qword [rax]
mov qword [rbp - 0x19], rcx
lea rcx, [rbp - 9]
mov qword [rax], rdx
call fcn.1400482a0
lea rcx, [rbp - 0x19]
mov qword [rsp + 0x88], rsi
call fcn.1400495e0
cmp eax, 1
je 0x1400821ba
lea rcx, [rbp - 0x19]
call fcn.1400495e0
cmp eax, 2
je 0x1400821ba
mov eax, dword [rbx + 0x70]
dec eax
cmp eax, 1
jbe 0x1400821ba
mov esi, 2
mov qword [rbp + 7], 0
movzx ecx, r15w
mov word [rbp - 1], si
call qword [sym.imp.WS2_32.dll_htons]
lea rcx, [rbp - 0x19]
mov word [rbp + 1], ax
call fcn.1400499d0
mov ecx, eax
call qword [sym.imp.WS2_32.dll_htonl]
mov dword [rbp + 3], eax
mov r14d, select
jmp 0x140082243
mov eax, 0x17
mov dword [rbp + 3], 0
lea rdx, [rbp - 9]
mov word [rbp - 1], ax
lea rcx, [rbp - 0x19]
call fcn.1400496b0
mov rcx, rax
call fcn.1400142e0
mov dword [rbp + 0x17], eax
mov esi, 2
mov rax, qword [rbp - 9]
mov ecx, dword [rax]
test ecx, ecx
je 0x140082208
cmp ecx, 0xffffffff
je 0x14008221a
mov rax, qword [rbp - 9]
mov ecx, 0xffffffff
lock xadd dword [rax], ecx
cmp ecx, 1
jne 0x14008221a
mov rcx, qword [rbp - 9]
mov r8d, 8
mov rdx, rsi
call fcn.1400affb0
movzx ecx, r15w
call qword [sym.imp.WS2_32.dll_htons]
lea rdx, [rbp + 0x1f]
mov word [rbp + 1], ax
lea rcx, [rbp - 0x19]
call fcn.1400499e0
movups xmm0, xmmword [rbp + 0x1f]
mov r14d, 0x1c
movups xmmword [rbp + 7], xmm0
cmp word [rbp - 1], 0x17
jne 0x140082286
lea rcx, [rbp - 0x19]
mov dword [rbp - 0x11], 0
call fcn.1400495e0
cmp eax, 1
jne 0x140082262
mov dword [rbp - 0x11], eax
mov rcx, qword [rbx + 0xa8]
lea r9, [rbp - 0x11]
mov edx, 0x29
mov dword [rsp + 0x20], 4
mov r8d, 0x1b
call qword [sym.imp.WS2_32.dll_setsockopt]
mov rcx, qword [rbx + 0xa8]
lea rdx, [rbp - 1]
mov r8d, r14d
call qword [sym.imp.WS2_32.dll_bind]
mov r14, qword [rsp + 0x80]
cmp eax, 0xffffffff
jne 0x140082369
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x273f
jne 0x140082308
lea rcx, [rbp - 0x19]
call fcn.1400495e0
cmp eax, 2
jne 0x140082308
movzx ecx, r15w
mov word [rbp - 1], si
call qword [sym.imp.WS2_32.dll_htons]
lea rcx, [rbp - 0x19]
mov word [rbp + 1], ax
call fcn.1400499d0
mov ecx, eax
call qword [sym.imp.WS2_32.dll_htonl]
mov rcx, qword [rbx + 0xa8]
lea rdx, [rbp - 1]
mov r8d, select
mov dword [rbp + 3], eax
call qword [sym.imp.WS2_32.dll_bind]
cmp eax, 0xffffffff
jne 0x140082369
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
sub eax, 0x271d
je 0x140082352
sub eax, 9
je 0x14008233b
sub eax, 0x1a
je 0x14008233b
cmp eax, 1
jne 0x140082365
mov edx, 9
mov r8d, select
mov rcx, rbx
call fcn.140070600
xor bl, bl
jmp 0x140082372
mov edx, 8
mov r8d, reloc.WS2_32.dll_ntohl
mov rcx, rbx
call fcn.140070600
xor bl, bl
jmp 0x140082372
mov edx, 3
mov r8d, select
mov rcx, rbx
call fcn.140070600
xor bl, bl
jmp 0x140082372
mov dword [rbx + 0x68], 4
mov bl, 1
lea rcx, [rbp - 0x19]
call fcn.1400482a0
mov rsi, qword [rsp + 0x88]
movzx eax, bl
mov rcx, qword [rbp + 0x2f]
xor rcx, rsp
call fcn.140229fa0
add rsp, 0x90
pop r15
pop rbx
pop rbp
ret