Function at 0x140227960
Capabilities:
Encode data using xor

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x18], r8
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x20
mov rbp, qword [r8 + 8]
mov rsi, r8
mov rbx, rdx
mov dword [rsp + 0x78], r9d
movzx r12d, r9b
xor edx, edx
mov r8d, 0x138
mov edi, r9d
mov r13, qword [rbp + 0xa0]
mov r14, rcx
and r12b, 0x80
call fcn.14025e440
movzx r15d, byte [rsp + 0x80]
xor r8d, r8d
test dil, 2
jne 0x140227d01
test r15b, r15b
jne 0x140227d01
cmp byte [rbx + 0x191], r8b
jne 0x140227b83
mov eax, r8d
cmp byte [rbx + 0x190], r8b
jne 0x1402279f9
movzx edx, r12b
mov rcx, rbx
call fcn.140229080
test eax, eax
jne 0x140227dac
xor r8d, r8d
cmp byte [rbx + 0x191], 0
jne 0x140227b7b
cmp dword [rbx + 0x124], 0
mov esi, r8d
mov r15, qword [rbx]
jbe 0x140227a96
nop dword [rax]
mov rax, qword [r15 + 0x3a0]
mov r10d, dword [rbx + 0x6c]
mov r11d, esi
movsx ecx, word [rax + r11*2]
mov eax, ecx
mov r9d, ecx
neg eax
sar r9d, 0x1f
and r9d, 0xfffffffe
inc r9d
test cx, cx
cmovns eax, ecx
mov ecx, r9d
movsxd r8, eax
neg ecx
mov eax, r10d
cdq
xor eax, edx
sub eax, edx
cdqe
imul r8, rax
add r8, 0x8000
sar r8, 0x10
test r10d, r10d
mov eax, r8d
cmovns ecx, r9d
neg eax
test ecx, ecx
cmovle r8d, eax
mov rax, qword [rbx + 0x128]
inc esi
mov dword [rax + r11*4], r8d
cmp esi, dword [rbx + 0x124]
jb 0x140227a20
xor r8d, r8d
mov edx, r8d
cmp r8w, word [rbx + 0x14c]
jae 0x140227ae8
mov eax, edx
inc edx
lea rcx, [rax*8]
mov rax, qword [rbx + 0x150]
mov dword [rcx + rax], r8d
mov rax, qword [rbx + 0x150]
mov dword [rcx + rax + 4], r8d
mov rax, qword [rbx + 0x158]
mov dword [rcx + rax], r8d
mov rax, qword [rbx + 0x158]
mov dword [rcx + rax + 4], r8d
movzx eax, word [rbx + 0x14c]
cmp edx, eax
jb 0x140227aa3
mov edx, r8d
cmp r8w, word [rbx + 0x130]
jae 0x140227b1a
nop word [rax + rax]
mov rax, qword [rbx + 0x138]
mov ecx, edx
inc edx
mov dword [rax + rcx*4], r8d
movzx eax, word [rbx + 0x130]
cmp edx, eax
jb 0x140227b00
movaps xmm0, xmmword [0x140374240]
movzx edx, r12b
movaps xmm1, xmmword [0x140374250]
mov rcx, rbx
mov eax, dword [reloc.WS2_32.dll_accept]
movups xmmword [rbx + 0xe0], xmm0
movaps xmm0, xmmword [0x140374260]
movups xmmword [rbx + 0xf0], xmm1
movaps xmm1, xmmword [0x140374270]
movups xmmword [rbx + 0x100], xmm0
movups xmmword [rbx + 0x110], xmm1
mov dword [rbx + 0x120], eax
call fcn.140228e10
test eax, eax
jne 0x140227dac
mov byte [rbx + 0x191], 1
jmp 0x140227b83
test eax, eax
jne 0x140227dac
cmp byte [rbx + 0x180], 0
je 0x140227b95
mov rsi, qword [rbx + 0x188]
jmp 0x140227ba0
mov rax, qword [rbp + 0x90]
mov rsi, qword [rax + 0x50]
test rsi, rsi
jne 0x140227baf
mov eax, 0x99
jmp 0x140227dac
and edi, 0xf0000
mov r8, rbx
cmp edi, 0x20000
mov rdx, rbp
mov rcx, rsi
setne dil
call fcn.140229af0
cmp dil, byte [rsi + 0x368]
je 0x140227c6e
xor r15d, r15d
mov byte [rsi + 0x368], dil
cmp dword [rbx + 0x124], r15d
jbe 0x140227c62
nop dword [rax]
mov rax, qword [rbp + 0x3a0]
mov r11d, dword [rbx + 0x6c]
movsx ecx, word [rax + r15*2]
mov eax, r11d
cdq
mov r10d, ecx
xor eax, edx
sar r10d, 0x1f
sub eax, edx
and r10d, 0xfffffffe
movsxd r9, eax
inc r10d
mov eax, ecx
neg eax
test cx, cx
cmovns eax, ecx
mov ecx, r10d
cdqe
neg ecx
imul r9, rax
add r9, 0x8000
sar r9, 0x10
test r11d, r11d
mov eax, r9d
cmovns ecx, r10d
neg eax
test ecx, ecx
cmovle r9d, eax
mov rax, qword [rbx + 0x128]
mov dword [rax + r15*4], r9d
inc r15d
cmp r15d, dword [rbx + 0x124]
jb 0x140227bf0
movzx edx, r12b
mov rcx, rbx
call fcn.140228e10
movzx ecx, byte [rsi + 0x1f0]
mov edi, dword [rsp + 0x78]
movzx eax, cl
or edi, 2
and al, 1
cmove edi, dword [rsp + 0x78]
test cl, 2
je 0x140227ccf
movaps xmm0, xmmword [0x140374240]
movaps xmm1, xmmword [0x140374250]
mov eax, dword [reloc.WS2_32.dll_accept]
movups xmmword [rsi + 0x1bc], xmm0
movaps xmm0, xmmword [0x140374260]
movups xmmword [rsi + 0x1cc], xmm1
movaps xmm1, xmmword [0x140374270]
movups xmmword [rsi + 0x1dc], xmm0
movups xmmword [rsi + 0x1ec], xmm1
mov dword [rsi + 0x1fc], eax
movzx r15d, byte [rsp + 0x80]
movzx eax, dil
and al, 0x80
mov byte [rsi + 0x315], al
xor r8d, r8d
mov qword [r14 + 0xf0], rsi
mov rax, qword [rsi + 0x238]
mov rsi, qword [rsp + 0x70]
mov qword [r14 + 0xf8], rax
mov rax, qword [rbp + 0xd0]
cmp qword [rax + 0x48], 0
je 0x140227d14
mov eax, r8d
jmp 0x140227d42
xor r9d, r9d
mov r8, r13
mov edx, 0x676c7966
mov rcx, rbp
call qword [rbp + 0x290]
cmp eax, 0x8e
jne 0x140227d37
xor r8d, r8d
mov eax, r8d
jmp 0x140227d42
test eax, eax
jne 0x140227dac
mov eax, dword [r13 + 0xc]
xor r8d, r8d
mov dword [r14 + 0x68], eax
test r15b, r15b
jne 0x140227d97
mov rax, qword [rsi + 0xf0]
mov rcx, qword [rax]
mov dword [rcx + 0x18], 0
mov dword [rcx + 0x50], r8d
movups xmm0, xmmword [rcx + 0x18]
movups xmmword [rcx + 0x60], xmm0
movups xmm1, xmmword [rcx + 0x28]
movups xmmword [rcx + 0x70], xmm1
movups xmm0, xmmword [rcx + 0x38]
movups xmmword [rcx + 0x80], xmm0
movups xmm1, xmmword [rcx + 0x48]
movups xmmword [rcx + 0x90], xmm1
movsd xmm0, qword [rcx + 0x58]
movsd qword [rcx + 0xa0], xmm0
mov qword [r14 + 0x18], rcx
mov dword [r14 + 0x20], edi
xor eax, eax
mov qword [r14], rbp
mov qword [r14 + 8], rbx
mov qword [r14 + 0x10], rsi
mov qword [r14 + 0x28], r13
mov rbx, qword [rsp + 0x60]
add rsp, 0x20
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret