Function at 0x14000d8d0
Capabilities:
Encode data using xor
Generate random numbers using the delphi lcg

Disassembly:
push rbp
push rbx
push r12
push r14
push r15
lea rbp, [rsp - 0x37]
sub rsp, 0xa0
mov rax, qword [0x1400c7398]
xor rax, rsp
mov qword [rbp + 0x17], rax
cmp byte [rcx + 0x38], 0
mov r12, rdx
mov r14, rcx
jne 0x14000dc9a
cmp dword [rcx + 0x30], 0
jbe 0x14000dc8a
cmp byte [rcx + 0x4d], 0
jne 0x14000dc9a
xor r15d, r15d
cmp byte [rcx + 0x4c], r15b
jne 0x14000dc7b
mov ebx, r15d
nop word [rax + rax]
mov r8d, 0xc
lea rdx, [rbp + 7]
sub r8, rbx
add rdx, rbx
mov r9d, 1
mov rcx, r14
call fcn.14000bb30
test rax, rax
js 0x14000d967
je 0x14000d960
add rbx, rax
cmp rbx, 0xc
jb 0x14000d930
jmp 0x14000d975
mov byte [r14 + 0x4c], 1
jmp 0x14000d975
mov byte [r14 + 0x4d], 1
test rbx, rbx
je 0x14000dc9a
test rbx, rbx
js 0x14000dc9a
cmp rbx, 0xc
jne 0x14000dc7b
movzx eax, word [r12 + 0x18]
mov ebx, dword [r12 + 0x18]
mov qword [rsp + 0xe0], rsi
mov esi, dword [r12 + 0x14]
mov qword [rsp + 0x98], rdi
mov edi, dword [r12 + 0x10]
mov qword [rsp + 0x90], r13
mov r13, r15
nop dword [rax + rax]
movzx eax, ax
lea rdx, [rbp - 0x49]
or eax, 2
not edi
mov ecx, eax
mov r8d, 1
xor ecx, 1
imul ecx, eax
shr ecx, 8
xor cl, byte [rbp + r13 + 7]
mov byte [rbp - 0x49], cl
mov byte [rbp + r13 + 7], cl
mov ecx, edi
call fcn.140010630
mov edi, eax
lea rdx, [rbp - 0x49]
not eax
not ebx
mov dword [r12 + 0x10], eax
mov r8d, 1
movzx eax, al
mov ecx, ebx
add eax, esi
imul esi, eax, 0x8088405
inc esi
mov eax, esi
mov dword [r12 + 0x14], esi
shr eax, 0x18
mov byte [rbp - 0x49], al
call fcn.140010630
mov ebx, eax
lea rdx, [rbp - 0x49]
not eax
mov r8d, 1
movzx ecx, ax
mov dword [r12 + 0x18], eax
or ecx, 2
mov eax, ecx
xor eax, 1
imul eax, ecx
mov ecx, edi
shr eax, 8
xor al, byte [rbp + r13 + 8]
mov byte [rbp - 0x49], al
mov byte [rbp + r13 + 8], al
call fcn.140010630
mov edi, eax
lea rdx, [rbp - 0x49]
not eax
mov r8d, 1
mov dword [r12 + 0x10], eax
mov ecx, ebx
movzx eax, al
add eax, esi
imul esi, eax, 0x8088405
inc esi
mov eax, esi
mov dword [r12 + 0x14], esi
shr eax, 0x18
mov byte [rbp - 0x49], al
call fcn.140010630
mov ebx, eax
lea rdx, [rbp - 0x49]
not eax
mov r8d, 1
movzx ecx, ax
mov dword [r12 + 0x18], eax
or ecx, 2
mov eax, ecx
xor eax, 1
imul eax, ecx
mov ecx, edi
shr eax, 8
xor al, byte [rbp + r13 + 9]
mov byte [rbp - 0x49], al
mov byte [rbp + r13 + 9], al
call fcn.140010630
mov edi, eax
not eax
mov dword [r12 + 0x10], eax
movzx eax, al
add eax, esi
lea rdx, [rbp - 0x49]
imul esi, eax, 0x8088405
mov r8d, 1
mov ecx, ebx
inc esi
mov eax, esi
mov dword [r12 + 0x14], esi
shr eax, 0x18
mov byte [rbp - 0x49], al
call fcn.140010630
mov ebx, eax
lea rdx, [rbp - 0x49]
not eax
mov r8d, 1
movzx ecx, ax
mov dword [r12 + 0x18], eax
or ecx, 2
mov eax, ecx
xor eax, 1
imul eax, ecx
mov ecx, edi
shr eax, 8
xor al, byte [rbp + r13 + 0xa]
mov byte [rbp - 0x49], al
mov byte [rbp + r13 + 0xa], al
call fcn.140010630
mov edi, eax
lea rdx, [rbp - 0x49]
not edi
mov r8d, 1
movzx eax, dil
mov ecx, ebx
add eax, esi
mov dword [r12 + 0x10], edi
imul esi, eax, 0x8088405
inc esi
mov eax, esi
mov dword [r12 + 0x14], esi
shr eax, 0x18
mov byte [rbp - 0x49], al
call fcn.140010630
not eax
add r13, 4
mov dword [r12 + 0x18], eax
mov ebx, eax
cmp r13, 0xc
jb 0x14000d9c0
mov r13, qword [rsp + 0x90]
mov rdi, qword [rsp + 0x98]
mov rsi, qword [rsp + 0xe0]
cmp byte [r14 + 0x38], r15b
jne 0x14000dbf1
mov rcx, qword [r14]
mov qword [rbp - 0x39], r15
mov qword [rbp - 0x31], r15
mov qword [rbp - 0x29], 0xffffffffffffffff
mov qword [rbp - 9], r15
mov qword [rbp - 0x11], 0xffffffffffffffff
mov qword [rbp - 0x21], r15
mov qword [rbp - 0x19], r15
test rcx, rcx
je 0x14000dbf8
lea rdx, [rbp - 0x39]
call fcn.14000b3a0
test eax, eax
jns 0x14000dbf8
mov rcx, qword [r14]
lea rdx, [r14 + 0x18]
test rdx, rdx
je 0x14000dbf1
mov eax, dword [rcx + 0x18]
mov dword [rdx], eax
mov eax, dword [rcx + 0x1c]
mov dword [rdx + 4], eax
xor eax, eax
jmp 0x14000dcb5
mov r9d, 3
lea rdx, [rbp - 0x39]
mov rcx, r14
lea r8d, [r9 + 0x3d]
call fcn.14000bb30
test rax, rax
js 0x14000dbf1
mov rax, qword [rbp - 0x11]
lea rcx, [rbp - 0x41]
mov qword [rbp - 0x41], rax
call qword [0x140071830]
test rax, rax
jne 0x14000dc30
movzx r8d, r15w
jmp 0x14000dc59
cmp dword [rax + 0x14], 0x50
jge 0x14000dc3d
mov dword [rax + 0x14], 0x50
movzx r8d, word [rax + 8]
shl r8w, 6
add r8w, word [rax + 4]
mov eax, dword [rax]
sar eax, 1
shl r8w, 5
add r8w, ax
mov edx, dword [rbp - 9]
movzx eax, byte [rbp + 0x12]
shr edx, 0x18
cmp al, dl
je 0x14000dbf1
shr r8w, 8
cmp al, r8b
je 0x14000dbf1
mov qword [r12], 0x1b
jmp 0x14000dcb0
test r12, r12
je 0x14000dcb0
mov qword [r12], 0x11
jmp 0x14000dcb0
lea rax, [rcx + 0x18]
test rax, rax
je 0x14000dc9a
mov qword [rax], 0x12
test r12, r12
je 0x14000dcb0
mov eax, dword [r14 + 0x18]
mov dword [r12], eax
mov eax, dword [r14 + 0x1c]
mov dword [r12 + 4], eax
mov eax, 0xffffffff
mov rcx, qword [rbp + 0x17]
xor rcx, rsp
call fcn.1400595c0
add rsp, 0xa0
pop r15
pop r14
pop r12
pop rbx
pop rbp
ret