Function at 0x140082c50
Capabilities:
Encode data using xor

Disassembly:
push rsi
push rdi
push r13
sub rsp, 0x10
mov rax, qword [rdx + 8]
mov r11, r8
sub rax, qword [rdx]
mov rsi, rdx
mov r13, qword [rsp + 0x60]
mov rdi, rcx
cmp rax, 4
jb 0x140082fca
mov qword [rsp + 0x30], rbx
mov rbx, r13
mov qword [rsp + 0x38], rbp
mov qword [rsp + 0x40], r12
mov r12, qword [rsp + 0x50]
mov qword [rsp + 8], r14
xor r14d, r14d
mov qword [rsp], r15
mov r15, qword [rsp + 0x58]
test r15, r15
je 0x140082ccf
xor edx, edx
mov rcx, r15
shr rcx, 2
mov rax, rbx
div rcx
mov eax, dword [r12 + rdx*4]
xor edx, edx
bswap eax
xor dword [r11], eax
lea rax, [rbx + 1]
div rcx
mov eax, dword [r12 + rdx*4]
bswap eax
xor dword [r9], eax
mov ebp, recv
nop dword [rax]
nop dword [rax + rax]
mov rax, qword [rdi + 0x20]
mov ecx, dword [rax + rbp - 0xc]
xor dword [r11], ecx
mov r8d, dword [r11]
mov r10, qword [rdi + 8]
mov eax, r8d
shr eax, 0x10
movzx ecx, al
mov eax, r8d
shr rax, 0x18
mov edx, dword [r10 + rcx*4 + 0x400]
add edx, dword [r10 + rax*4]
mov eax, r8d
shr eax, 8
movzx ecx, al
movzx eax, r8b
xor edx, dword [r10 + rcx*4 + 0x800]
add edx, dword [r10 + rax*4 + 0xc00]
xor dword [r9], edx
mov rax, qword [rdi + 0x20]
mov r10d, dword [r9]
xor r10d, dword [rax + rbp - 8]
mov dword [r9], r10d
mov eax, r10d
mov r8, qword [rdi + 8]
shr eax, 0x10
movzx ecx, al
mov eax, r10d
shr rax, 0x18
mov edx, dword [r8 + rcx*4 + 0x400]
add edx, dword [r8 + rax*4]
mov eax, r10d
shr eax, 8
movzx ecx, al
movzx eax, r10b
xor edx, dword [r8 + rcx*4 + 0x800]
add edx, dword [r8 + rax*4 + 0xc00]
xor dword [r11], edx
mov rax, qword [rdi + 0x20]
mov r10d, dword [r11]
xor r10d, dword [rax + rbp - 4]
mov dword [r11], r10d
mov eax, r10d
mov r8, qword [rdi + 8]
shr eax, 0x10
movzx ecx, al
mov eax, r10d
shr rax, 0x18
mov edx, dword [r8 + rcx*4 + 0x400]
add edx, dword [r8 + rax*4]
mov eax, r10d
shr eax, 8
movzx ecx, al
movzx eax, r10b
xor edx, dword [r8 + rcx*4 + 0x800]
add edx, dword [r8 + rax*4 + 0xc00]
xor dword [r9], edx
mov rax, qword [rdi + 0x20]
mov r10d, dword [r9]
xor r10d, dword [rax + rbp]
mov dword [r9], r10d
mov eax, r10d
mov r8, qword [rdi + 8]
shr eax, 0x10
movzx ecx, al
mov eax, r10d
shr rax, 0x18
mov edx, dword [r8 + rcx*4 + 0x400]
add edx, dword [r8 + rax*4]
mov eax, r10d
shr eax, 8
movzx ecx, al
movzx eax, r10b
xor edx, dword [r8 + rcx*4 + 0x800]
add edx, dword [r8 + rax*4 + 0xc00]
xor dword [r11], edx
mov rax, qword [rdi + 0x20]
mov r10d, dword [r11]
xor r10d, dword [rax + rbp + 4]
mov dword [r11], r10d
mov r8, qword [rdi + 8]
mov eax, r10d
shr eax, 0x10
movzx ecx, al
mov eax, r10d
shr rax, 0x18
mov edx, dword [r8 + rcx*4 + 0x400]
add edx, dword [r8 + rax*4]
mov eax, r10d
shr eax, 8
movzx ecx, al
movzx eax, r10b
xor edx, dword [r8 + rcx*4 + 0x800]
add edx, dword [r8 + rax*4 + 0xc00]
xor dword [r9], edx
mov rax, qword [rdi + 0x20]
mov r10d, dword [r9]
xor r10d, dword [rax + rbp + 8]
mov dword [r9], r10d
mov eax, r10d
mov r8, qword [rdi + 8]
shr eax, 0x10
movzx ecx, al
mov eax, r10d
shr rax, 0x18
mov edx, dword [r8 + rcx*4 + 0x400]
add edx, dword [r8 + rax*4]
mov eax, r10d
shr eax, 8
movzx ecx, al
movzx eax, r10b
xor edx, dword [r8 + rcx*4 + 0x800]
add edx, dword [r8 + rax*4 + 0xc00]
xor dword [r11], edx
mov rax, qword [rdi + 0x20]
mov r10d, dword [r11]
xor r10d, dword [rax + rbp + 0xc]
mov dword [r11], r10d
mov eax, r10d
mov r8, qword [rdi + 8]
shr eax, 0x10
movzx ecx, al
mov eax, r10d
shr rax, 0x18
mov edx, dword [r8 + rcx*4 + 0x400]
add edx, dword [r8 + rax*4]
mov eax, r10d
shr eax, 8
movzx ecx, al
movzx eax, r10b
xor edx, dword [r8 + rcx*4 + 0x800]
add edx, dword [r8 + rax*4 + 0xc00]
xor dword [r9], edx
mov rax, qword [rdi + 0x20]
mov r10d, dword [r9]
xor r10d, dword [rax + rbp + 0x10]
add rbp, 0x20
mov dword [r9], r10d
mov eax, r10d
mov r8, qword [rdi + 8]
shr eax, 0x10
movzx ecx, al
mov eax, r10d
shr rax, 0x18
mov edx, dword [r8 + rcx*4 + 0x400]
add edx, dword [r8 + rax*4]
mov eax, r10d
shr eax, 8
movzx ecx, al
movzx eax, r10b
xor edx, dword [r8 + rcx*4 + 0x800]
add edx, dword [r8 + rax*4 + 0xc00]
xor dword [r11], edx
mov edx, dword [r11]
cmp rbp, 0x4c
jne 0x140082ce0
mov rax, qword [rdi + 0x20]
add rbx, 2
mov ecx, dword [r9]
xor edx, dword [rax + 0x40]
mov dword [r9], edx
mov rax, qword [rdi + 0x20]
xor ecx, dword [rax + 0x44]
mov dword [r11], ecx
mov rax, qword [rsi]
mov dword [r14 + rax], ecx
mov rcx, qword [rsi]
mov eax, dword [r9]
mov dword [rcx + r14 + 4], eax
mov rax, rbx
mov rcx, qword [rsi + 8]
add r14, 8
sub rcx, qword [rsi]
sub rax, r13
sar rcx, 2
cmp rax, rcx
jne 0x140082ca0
mov r15, qword [rsp]
mov r14, qword [rsp + 8]
mov r12, qword [rsp + 0x40]
mov rbp, qword [rsp + 0x38]
mov rbx, qword [rsp + 0x30]
add rsp, 0x10
pop r13
pop rdi
pop rsi
ret