Function at 0x180066690
Capabilities:
Encode data using xor

Disassembly:
push rbp
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbx
sub rsp, 0x358
lea rbp, [rsp + 0x80]
mov qword [rbp + 0x2d0], 0xfffffffffffffffe
mov rdi, r8
mov rsi, rcx
mov r15, qword [rbp + 0x340]
movzx eax, byte [rbp + 0x348]
movdqu xmm0, xmmword [r15]
movdqu xmm1, xmmword [r15 + 0x10]
movdqu xmmword [rdx + 0x120], xmm1
movdqu xmmword [rdx + 0x110], xmm0
movabs rcx, 0x14452474e574f44
mov qword [rbp + 0x2c0], rdx
cmp qword [rdx + 0x128], rcx
sete r8b
and r8b, al
je 0x180066848
mov byte [rbp + 0x2b8], r8b
mov rdi, qword [rdi]
mov word [rbp + 0x188], 4
mov byte [rbp + 0xd0], 1
mov byte [rbp + reloc.WS2_32.dll_listen2], 0xd
mov word [rbp + 0x178], 0x1f
cmp byte [rdi + 0x41], 2
sete r8b
mov byte [rbp + 0x2cf], 1
mov byte [rbp + 0x2ce], 0
lea rdx, [rbp + 0xd0]
mov rcx, rdi
call fcn.180056fe0
mov byte [rdi + 0x331], 1
mov word [rsi], 8
mov rax, qword [rbp + 0x2c0]
mov rax, qword [rax + 0xb0]
lock dec qword [rax]
jne 0x18006678c
mov rax, qword [rbp + 0x2c0]
lea rcx, [rax + 0xb0]
call fcn.180018620
mov rax, qword [rbp + 0x2c0]
cmp byte [rax + 0xa8], 2
setne al
test byte [rbp + 0x2b8], al
je 0x1800667b5
mov rax, qword [rbp + 0x2c0]
lea rcx, [rax + 0x28]
call fcn.18005dfd0
mov rsi, qword [rbp + 0x2c0]
cmp byte [rsi], 0
je 0x180066aad
mov rcx, qword [rsi + 0xc8]
mov rax, qword [rsi + 0xd0]
mov qword [rbp + 0x2a8], rcx
mov qword [rbp + 0x2b8], rax
call qword [rax]
mov rax, qword [rbp + 0x2b8]
mov rdx, qword [rax + 8]
test rdx, rdx
je 0x180066803
mov r8, qword [rax + 0x10]
mov rcx, qword [rbp + 0x2a8]
call fcn.180005fa0
mov rax, qword [rbp + 0x2c0]
mov rcx, qword [rax + 0xd8]
test rcx, rcx
je 0x180066dc7
mov rdx, qword [rax + 0xe0]
test rdx, rdx
je 0x180066dc7
mov r8d, 1
add rsp, 0x358
pop rbx
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
pop rbp
jmp fcn.180005fa0
mov rbx, r9
mov rax, qword [r15 + 0x58]
test rax, rax
je 0x180066ad7
mov r14, qword [r15 + 0x48]
shl rax, 3
lea r13, [rax + rax*4]
xor eax, eax
mov ecx, 0x1f7f
jmp 0x180066879
add rax, 0x28
cmp r13, rax
je 0x180066898
movzx edx, word [r14 + rax]
mov r12b, 1
bt rcx, rdx
jb 0x180066870
cmp rdx, 0xd
jne 0x18006689b
cmp word [r14 + rax + 0x20], 0x13
jne 0x180066870
jmp 0x18006689b
xor r12d, r12d
mov rax, qword [rbp + 0x2c0]
lea r9, [rax + 0x130]
mov byte [rax + 0x130], r12b
xor eax, eax
jmp 0x1800668cd
add rax, 0x28
cmp r13, rax
je 0x180066992
movzx ecx, word [r14 + rax]
lea rdx, [rcx - 3]
cmp rdx, 0xa
jb 0x1800668c0
cmp ecx, 2
jb 0x1800668c0
cmp ecx, 0xd
jne 0x1800668ef
cmp word [r14 + rax + 0x20], 0x14
jne 0x1800668c0
mov rax, qword [0x1802220c0]
mov rax, qword [rax]
mov cl, 1
mov dword [rbp + 0x2a8], ecx
cmp rax, 4
jb 0x18006699c
mov qword [rbp + 0x2b0], r9
mov byte [rbp + 0x2b8], r8b
lea rax, [0x180157df8]
mov qword [rbp + 0xd0], rax
mov qword [rbp + 0xd8], 1
lea rax, [0x1801576e8]
mov qword [rbp + 0xe0], rax
pxor xmm0, xmm0
movdqu xmmword [rbp + 0xe8], xmm0
mov byte [rbp + 0x2cf], 1
mov byte [rbp + 0x2ce], 0
mov qword [rsp + 0x20], 0
lea r8, str.rustls::client::tls12::server_hello
lea rcx, [rbp + 0xd0]
mov edx, 4
mov r9d, 0x5a
call fcn.1800d6430
movzx r8d, byte [rbp + 0x2b8]
mov r9, qword [rbp + 0x2b0]
jmp 0x18006699c
mov dword [rbp + 0x2a8], 0
xor eax, eax
mov ecx, 0x1eff
jmp 0x1800669bd
add rax, 0x28
cmp r13, rax
je 0x180066a8c
movzx edx, word [r14 + rax]
bt rcx, rdx
jb 0x1800669b0
cmp rdx, 0xd
jne 0x1800669d7
cmp word [r14 + rax + 0x20], 5
jne 0x1800669b0
mov rax, qword [0x1802220c0]
mov rax, qword [rax]
mov r14b, 1
cmp rax, 4
jb 0x180066a8f
mov qword [rbp + 0x2b0], r9
mov r13b, r8b
lea rax, str.Server_may_staple_OCSP_response
mov qword [rbp + 0xd0], rax
mov qword [rbp + 0xd8], 1
lea rax, [0x1801576e8]
mov qword [rbp + 0xe0], rax
pxor xmm0, xmm0
movdqu xmmword [rbp + 0xe8], xmm0
mov byte [rbp + 0x2cf], 1
mov byte [rbp + 0x2ce], 0
mov qword [rsp + 0x20], 0
lea r8, str.rustls::client::tls12::server_hello
lea rcx, [rbp + 0xd0]
mov edx, 4
mov r9d, 0x66
call fcn.1800d6430
mov rdx, qword [rbp + 0x2c0]
mov r8d, r13d
mov r9, qword [rbp + 0x2b0]
lea r13, [rdx + 0xf0]
mov al, 1
cmp byte [rdx + 0xa8], 2
jne 0x180066b12
jmp 0x180066c9c
xor r14d, r14d
mov rdx, qword [rbp + 0x2c0]
lea r13, [rdx + 0xf0]
mov al, 1
cmp byte [rdx + 0xa8], 2
jne 0x180066b12
jmp 0x180066c9c
mov rcx, qword [rsi + 8]
test rcx, rcx
je 0x1800667c5
mov rdx, qword [rsi + 0x10]
test rdx, rdx
je 0x1800667c5
mov r8d, 1
call fcn.180005fa0
jmp 0x1800667c5
mov rdx, qword [rbp + 0x2c0]
lea r9, [rdx + 0x130]
mov byte [rdx + 0x130], 0
xor r12d, r12d
mov dword [rbp + 0x2a8], 0
xor r14d, r14d
lea r13, [rdx + 0xf0]
mov al, 1
cmp byte [rdx + 0xa8], 2
je 0x180066c9c
mov qword [rbp + 0x2b0], r9
mov byte [rbp + 0x2b8], r8b
add rdx, 0x20
lea rcx, [rbp - 0x40]
mov r8d, 0x90
call sub.VCRUNTIME140.dll_memcpy
mov rax, qword [rbp + 0x40]
cmp rax, qword [r15 + 0x40]
jne 0x180066c71
lea r12, [r15 + 0x20]
test rax, rax
je 0x180066ddb
lea rcx, [rax - 0x21]
cmp rcx, 0xffffffffffffffe0
jb 0x1800673ab
cmp rax, 8
jae 0x180066b6b
xor edx, edx
xor ecx, ecx
jmp 0x180066c50
cmp rax, 0x10
jae 0x180066bdc
xor edx, edx
xor ecx, ecx
mov r8, rcx
mov rcx, rax
and rcx, 0xfffffffffffffff8
movzx edx, dl
movd xmm0, edx
nop word cs:[rax + rax]
mov rdx, qword [r12 + r8]
xor rdx, qword [rbp + r8 + 0x20]
movq xmm1, rdx
por xmm0, xmm1
add r8, 8
cmp rcx, r8
jne 0x180066b90
pshufd xmm1, xmm0, 0x55
por xmm1, xmm0
movdqa xmm0, xmm1
psrld xmm0, 0x10
por xmm0, xmm1
movdqa xmm1, xmm0
psrlw xmm1, 8
por xmm1, xmm0
movd edx, xmm1
cmp rax, rcx
jne 0x180066c50
jmp 0x180066c69
mov rcx, rax
and rcx, 0xfffffffffffffff0
movdqu xmm1, xmmword [rbp + 0x20]
movdqu xmm0, xmmword [r15 + 0x20]
pxor xmm0, xmm1
cmp rcx, 0x10
je 0x180066c0b
movdqu xmm1, xmmword [rbp + 0x30]
movdqu xmm2, xmmword [r15 + 0x30]
pxor xmm2, xmm1
por xmm0, xmm2
pshufd xmm1, xmm0, 0xee
por xmm1, xmm0
pshufd xmm0, xmm1, 0x55
por xmm0, xmm1
movdqa xmm1, xmm0
psrld xmm1, 0x10
por xmm1, xmm0
movdqa xmm0, xmm1
psrlw xmm0, 8
por xmm0, xmm1
movd edx, xmm0
cmp rax, rcx
je 0x180066c69
test al, 8
jne 0x180066b75
nop dword [rax + rax]
movzx r8d, byte [r12 + rcx]
xor r8b, byte [rbp + rcx + 0x20]
lea r9, [rcx + 1]
or dl, r8b
mov rcx, r9
cmp rax, r9
jne 0x180066c50
test dl, dl
je 0x180066ddb
lea rcx, [rbp - 0x38]
mov byte [rbp + 0x2cf], 0
mov byte [rbp + 0x2ce], 0
call fcn.18005dfd0
mov rax, qword [rbp + 0x2b0]
movzx r12d, byte [rax]
xor eax, eax
mov rdx, qword [rbp + 0x2c0]
mov dword [rbp + 0x2b8], eax
mov rax, qword [rdx + 0xb0]
mov rcx, qword [r15 + 0x40]
mov qword [rbp + 0x1e8], rcx
movups xmm0, xmmword [r15 + 0x20]
movups xmm1, xmmword [r15 + 0x30]
movups xmmword [rbp + 0x1d8], xmm1
movups xmmword [rbp + 0x1c8], xmm0
movups xmm0, xmmword [rdx]
movups xmm1, xmmword [rdx + 0x10]
movaps xmmword [rbp + 0xe0], xmm1
movaps xmmword [rbp + 0xd0], xmm0
movups xmm0, xmmword [r13]
movups xmm1, xmmword [r13 + 0x10]
movups xmm2, xmmword [r13 + 0x20]
movups xmm3, xmmword [r13 + 0x30]
movaps xmmword [rbp + 0x220], xmm3
movaps xmmword [rbp + 0x210], xmm2
movaps xmmword [rbp + 0x200], xmm1
movaps xmmword [rbp + 0x1f0], xmm0
movdqu xmm0, xmmword [rdx + 0xb8]
movdqu xmm1, xmmword [rdx + 0xc8]
movdqu xmm2, xmmword [rdx + 0xd8]
movdqu xmmword [rbp + 0x188], xmm0
movdqu xmmword [rbp + 0x1a8], xmm2
movdqu xmmword [rbp + 0x198], xmm1
mov rcx, qword [rdx + 0xe8]
mov qword [rbp + 0x1b8], rcx
mov qword [rbp + 0x180], rax
mov byte [rbp + 0x178], 2
mov byte [rbp + 0x230], r12b
mov qword [rbp + 0x1c0], rbx
mov byte [rbp + 0x231], r14b
mov eax, dword [rbp + 0x2a8]
mov byte [rbp + 0x232], al
movzx eax, byte [0x180222221]
mov ecx, 0x168
mov edx, 8
call fcn.180005f90
test rax, rax
je 0x1800673ca
mov rdi, rax
lea rdx, [rbp + 0xd0]
mov r8d, 0x168
mov rcx, rax
call sub.VCRUNTIME140.dll_memcpy
mov qword [rsi + 8], rdi
lea rax, fcn.18005db10
mov qword [rsi + 0x10], rax
mov byte [rsi], setsockopt
add rsp, 0x358
pop rbx
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
pop rbp
ret
mov rax, qword [0x1802220c0]
mov rax, qword [rax]
cmp rax, 4
jb 0x180066e4c
lea rax, str.Server_agreed_to_resume
mov qword [rbp + 0xd0], rax
mov qword [rbp + 0xd8], 1
lea rax, [0x1801576e8]
mov qword [rbp + 0xe0], rax
pxor xmm0, xmm0
movdqu xmmword [rbp + 0xe8], xmm0
mov byte [rbp + 0x2cb], 1
mov qword [rsp + 0x20], 0
lea r8, str.rustls::client::tls12::server_hello
lea rcx, [rbp + 0xd0]
mov edx, 4
mov r9d, WSAGetLastError
call fcn.1800d6430
mov rcx, qword [rbp - 0x40]
movzx edx, word [rcx + 0x50]
mov al, 0x29
cmp dx, word [rbx + 0x50]
jne 0x180066e8b
movzx edx, dx
cmp edx, 0x178
jne 0x180066e71
movzx ecx, word [rcx + 0x52]
cmp cx, word [rbx + 0x52]
jne 0x180066e8b
cmp byte [rbp + 0x48], 0
setne al
mov rcx, qword [rbp + 0x2b0]
cmp byte [rcx], 0
setne cl
xor cl, al
mov al, 0x2a
je 0x180066ead
mov byte [rsi], 8
mov byte [rsi + 1], al
lea rcx, [rbp - 0x38]
mov byte [rbp + 0x2cf], 0
mov byte [rbp + 0x2ce], 0
call fcn.18005dfd0
jmp 0x180066765
movdqu xmm0, xmmword [r13]
movdqu xmm1, xmmword [r13 + 0x10]
movdqu xmm2, xmmword [r13 + 0x20]
movups xmm3, xmmword [r13 + 0x30]
movups xmmword [rbp + 0x108], xmm3
movdqu xmmword [rbp + 0xf8], xmm2
movdqu xmmword [rbp + 0xe8], xmm1
movdqu xmmword [rbp + 0xd8], xmm0
mov rax, qword [rbp - 0x20]
mov rdx, qword [rbp - 0x10]
pxor xmm0, xmm0
movdqu xmmword [rbp + 0x118], xmm0
movdqu xmmword [rbp + 0x128], xmm0
movdqu xmmword [rbp + 0x138], xmm0
mov qword [rbp + 0xd0], rbx
cmp rdx, 0x30
jne 0x1800673db
lea rcx, [rbp + 0x118]
movups xmm0, xmmword [rax]
movups xmm1, xmmword [rax + 0x10]
movups xmm2, xmmword [rax + 0x20]
movups xmmword [rcx + 0x20], xmm2
movups xmmword [rcx + 0x10], xmm1
movups xmmword [rcx], xmm0
mov rax, qword [rbp + 0x140]
mov qword [rbp + 0xc0], rax
movups xmm0, xmmword [rbp + 0x130]
movaps xmmword [rbp + 0xb0], xmm0
movups xmm0, xmmword [rbp + 0x120]
movaps xmmword [rbp + 0xa0], xmm0
movups xmm0, xmmword [rbp + 0x110]
movaps xmmword [rbp + 0x90], xmm0
mov rax, qword [rbp + 0xd0]
mov rcx, qword [rbp + 0xd8]
movdqu xmm0, xmmword [rbp + 0xe0]
movdqu xmm1, xmmword [rbp + 0xf0]
movdqu xmm2, xmmword [rbp + 0x100]
movdqa xmmword [rbp + 0x80], xmm2
movdqa xmmword [rbp + 0x70], xmm1
movdqa xmmword [rbp + 0x60], xmm0
mov qword [rbp + 0x50], rax
mov qword [rbp + 0x58], rcx
mov rax, qword [rbp + 0x2c0]
mov rax, qword [rax + 0xb0]
mov rcx, qword [rax + 0x78]
mov rax, qword [rax + 0x80]
mov rdx, qword [rax + 0x10]
mov rax, qword [rax + 0x30]
dec rdx
and rdx, 0xfffffffffffffff0
add rcx, rdx
add rcx, 0x10
lea r9, [rbp + 0x58]
lea rdx, [rbp + 0x98]
mov byte [rbp + 0x2cd], 0
mov byte [rbp + 0x2cc], 1
mov qword [rsp + 0x28], rdx
mov qword [rsp + 0x30], 0x30
mov qword [rsp + 0x20], 0x20
lea rdx, str.CLIENT_RANDOM
mov r8d, reloc.WS2_32.dll_listen
call rax
mov rdi, qword [rdi]
mov byte [rbp + 0x2cd], 0
mov byte [rbp + 0x2cc], 1
lea rdx, [rbp + 0x50]
mov rcx, rdi
xor r8d, r8d
call fcn.180057970
lea rdx, [rbp - 8]
mov byte [rbp + 0x2cd], 0
mov byte [rbp + 0x2cc], 1
lea rcx, [rbp + 0xd0]
call fcn.1800729e0
mov rax, qword [rbp + 0xe0]
mov qword [rbp + 0x2a0], rax
movups xmm0, xmmword [rbp + 0xd0]
movaps xmmword [rbp + 0x290], xmm0
lea rbx, [rdi + 0x2f0]
cmp qword [rdi + 0x2f0], 0
je 0x1800670cc
mov qword [rbp + 0x2b8], rdi
mov qword [rbp + 0x2b0], rbx
mov rcx, rbx
call fcn.180030870
mov rax, qword [rbp + 0x2b8]
mov rax, qword [rax + 0x2f8]
test rax, rax
mov rbx, qword [rbp + 0x2b0]
je 0x1800670cc
mov rcx, qword [rbx]
shl rax, 3
lea rdx, [rax + rax*2]
mov r8d, 8
call fcn.180005fa0
mov rax, qword [rbp + 0x2a0]
mov qword [rbx + 0x10], rax
movaps xmm0, xmmword [rbp + 0x290]
movups xmmword [rbx], xmm0
mov r14, qword [rbp + 0x2c0]
lea rdi, [r14 + 0xb8]
cmp byte [rbp + 0x2a8], 0
je 0x180067250
mov rbx, qword [r14 + 0xb0]
mov rax, qword [rbp + 0xc0]
mov qword [rbp + 0x1f8], rax
movaps xmm0, xmmword [rbp + 0xb0]
movups xmmword [rbp + 0x1e8], xmm0
movaps xmm0, xmmword [rbp + 0xa0]
movups xmmword [rbp + 0x1d8], xmm0
movaps xmm0, xmmword [rbp + 0x90]
movups xmmword [rbp + 0x1c8], xmm0
movaps xmm0, xmmword [rbp + 0x50]
movaps xmm1, xmmword [rbp + 0x60]
movaps xmm2, xmmword [rbp + 0x70]
movaps xmm3, xmmword [rbp + 0x80]
movups xmmword [rbp + 0x1b8], xmm3
movups xmmword [rbp + 0x1a8], xmm2
movups xmmword [rbp + 0x198], xmm1
movups xmmword [rbp + 0x188], xmm0
lea rcx, [rbp + 0xf0]
lea rdx, [rbp - 0x40]
mov r8d, 0x90
call sub.VCRUNTIME140.dll_memcpy
mov rax, qword [r12 + 0x20]
mov qword [rbp + 0x258], rax
movups xmm0, xmmword [r12]
movups xmm1, xmmword [r12 + 0x10]
movups xmmword [rbp + 0x248], xmm1
movups xmmword [rbp + 0x238], xmm0
movups xmm0, xmmword [r14]
movups xmm1, xmmword [r14 + 0x10]
movaps xmmword [rbp + 0xd0], xmm0
movaps xmmword [rbp + 0xe0], xmm1
movzx eax, byte [r14 + 0x130]
mov rcx, qword [rdi + 0x30]
mov qword [rbp + 0x230], rcx
movdqu xmm0, xmmword [rdi]
movdqu xmm1, xmmword [rdi + 0x10]
movdqu xmm2, xmmword [rdi + 0x20]
movdqa xmmword [rbp + 0x220], xmm2
movdqa xmmword [rbp + 0x210], xmm1
movdqa xmmword [rbp + 0x200], xmm0
mov qword [rbp + 0x180], rbx
mov byte [rbp + 0x260], al
mov byte [rbp + 0x261], 1
movzx eax, byte [0x180222221]
mov ecx, 0x198
mov edx, 8
call fcn.180005f90
test rax, rax
je 0x1800673ee
mov rdi, rax
lea rdx, [rbp + 0xd0]
mov r8d, 0x198
mov rcx, rax
call sub.VCRUNTIME140.dll_memcpy
lea rax, fcn.18005d930
mov qword [rsi + 8], rdi
jmp 0x180066dc0
mov rbx, qword [r14 + 0xb0]
mov rax, qword [rbp + 0xc0]
mov qword [rbp + 0x1f8], rax
movaps xmm0, xmmword [rbp + 0xb0]
movups xmmword [rbp + 0x1e8], xmm0
movaps xmm0, xmmword [rbp + 0xa0]
movups xmmword [rbp + 0x1d8], xmm0
movaps xmm0, xmmword [rbp + 0x90]
movups xmmword [rbp + 0x1c8], xmm0
movaps xmm0, xmmword [rbp + 0x50]
movaps xmm1, xmmword [rbp + 0x60]
movaps xmm2, xmmword [rbp + 0x70]
movaps xmm3, xmmword [rbp + 0x80]
movups xmmword [rbp + 0x1b8], xmm3
movups xmmword [rbp + 0x1a8], xmm2
movups xmmword [rbp + 0x198], xmm1
movups xmmword [rbp + 0x188], xmm0
lea rcx, [rbp + 0xf0]
lea rdx, [rbp - 0x40]
mov r8d, 0x90
call sub.VCRUNTIME140.dll_memcpy
mov rax, qword [r12 + 0x20]
mov qword [rbp + 0x258], rax
movups xmm0, xmmword [r12]
movups xmm1, xmmword [r12 + 0x10]
movups xmmword [rbp + 0x248], xmm1
movups xmmword [rbp + 0x238], xmm0
movups xmm0, xmmword [r14]
movups xmm1, xmmword [r14 + 0x10]
movaps xmmword [rbp + 0xd0], xmm0
movaps xmmword [rbp + 0xe0], xmm1
movzx eax, byte [r14 + 0x130]
mov rcx, qword [rdi + 0x30]
mov qword [rbp + 0x230], rcx
movdqu xmm0, xmmword [rdi]
movdqu xmm1, xmmword [rdi + 0x10]
movdqu xmm2, xmmword [rdi + 0x20]
movdqa xmmword [rbp + 0x220], xmm2
movdqa xmmword [rbp + 0x210], xmm1
movdqa xmmword [rbp + 0x200], xmm0
mov qword [rbp + 0x180], rbx
mov byte [rbp + 0x280], al
mov qword [rbp + 0x260], 0
mov byte [rbp + 0x281], 1
movzx eax, byte [0x180222221]
mov ecx, 0x1b8
mov edx, 8
call fcn.180005f90
test rax, rax
je 0x1800673ff
mov rdi, rax
lea rdx, [rbp + 0xd0]
mov r8d, 0x1b8
mov rcx, rax
call sub.VCRUNTIME140.dll_memcpy
lea rax, fcn.18005d340
mov qword [rsi + 8], rdi
jmp 0x180066dc0
mov byte [rbp + 0x2cb], 1
lea r8, [0x18015fc98]
mov ecx, 0x20
mov edx, 0x20
call fcn.180137ee0
jmp 0x18006740e
mov ecx, 8
mov edx, 0x168
call fcn.180137c30
jmp 0x18006740e
lea r8, [0x180153d08]
mov ecx, 0x30
call fcn.180138450
jmp 0x18006740e
mov ecx, 8
mov edx, 0x198
call fcn.180137c30
jmp 0x18006740e
mov ecx, 8
mov edx, 0x1b8
call fcn.180137c30
ud2