Function at 0x4a1670
Capabilities:
Encode data using xor

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x868
lea rsi, [rsp + 0x60]
mov r12, rcx
mov ebx, r9d
mov qword [rsp + 0x8c0], r8
mov rcx, rsi
mov qword [rsp + 0x58], rsi
call fcn.004a1560
mov rdx, r12
mov rcx, rsi
call fcn.004a15a0
lea rax, [rsp + 0x460]
mov rdx, rsi
mov rcx, rax
mov qword [rsp + 0x48], rax
call fcn.004a1560
test ebx, ebx
jne 0x4a1ed8
mov r13, qword [rsp + 0x58]
mov qword [rsp + 0x50], r13
nop dword [rax + rax]
mov rax, qword [r13 + 0x20]
mov rdx, qword [r13]
mov r15, qword [r13 + 0x78]
mov r8d, eax
mov ecx, edx
add rdx, rax
imul rcx, r8
mov r8, qword [r13 + 0x60]
lea rcx, [rdx + rcx*2]
mov rdx, qword [r13 + 0x40]
xor r8, rcx
rol r8, 0x20
mov r9d, edx
mov r10d, r8d
add rdx, r8
imul r9, r10
lea rdx, [rdx + r9*2]
mov r9d, ecx
xor rax, rdx
ror rax, 0x18
mov r10d, eax
add rcx, rax
imul r9, r10
lea r12, [rcx + r9*2]
mov ecx, edx
xor r8, r12
ror r8, 0x10
mov r9d, r8d
add rdx, r8
imul rcx, r9
lea rdi, [rdx + rcx*2]
mov rcx, qword [r13 + 0x28]
xor rax, rdi
mov qword [rsp + 0x40], rdi
rol rax, 1
mov r9d, ecx
mov qword [rsp + 0x38], rax
mov rax, qword [r13 + 8]
mov edx, eax
add rax, rcx
imul rdx, r9
lea r9, [rax + rdx*2]
mov rdx, qword [r13 + 0x68]
mov rax, qword [r13 + 0x48]
xor rdx, r9
mov r10d, eax
rol rdx, 0x20
mov r11d, edx
add rax, rdx
imul r10, r11
lea rax, [rax + r10*2]
mov r10d, r9d
xor rcx, rax
ror rcx, 0x18
mov r11d, ecx
add r9, rcx
imul r10, r11
lea rdi, [r9 + r10*2]
mov r10, qword [r13 + 0x30]
xor rdx, rdi
ror rdx, 0x10
mov rsi, rdx
mov edx, eax
mov r9d, esi
add rax, rsi
mov qword [rsp + 0x30], rsi
imul rdx, r9
mov r9d, r10d
lea rdx, [rax + rdx*2]
mov rax, qword [r13 + 0x10]
xor rcx, rdx
mov qword [rsp + 0x28], rdx
mov edx, eax
rol rcx, 1
imul rdx, r9
add rax, r10
mov r9, qword [r13 + 0x70]
lea rdx, [rax + rdx*2]
mov rax, qword [r13 + 0x50]
xor r9, rdx
rol r9, 0x20
mov ebx, eax
mov r11d, r9d
add rax, r9
imul r11, rbx
mov ebx, edx
lea rax, [rax + r11*2]
xor r10, rax
ror r10, 0x18
mov r11d, r10d
add rdx, r10
imul r11, rbx
lea rbx, [rdx + r11*2]
mov r11d, eax
xor r9, rbx
ror r9, 0x10
mov edx, r9d
add rax, r9
imul rdx, r11
lea rbp, [rax + rdx*2]
mov rax, qword [r13 + 0x38]
mov rdx, qword [r13 + 0x18]
xor r10, rbp
mov esi, edx
mov r11d, eax
add rdx, rax
rol r10, 1
imul r11, rsi
mov rsi, qword [r13 + 0x58]
lea r11, [rdx + r11*2]
xor r15, r11
mov rdx, r15
mov r15d, esi
rol rdx, 0x20
mov r14d, edx
add rsi, rdx
imul r14, r15
lea rsi, [rsi + r14*2]
mov r14d, r11d
xor rax, rsi
ror rax, 0x18
mov r15d, eax
add r11, rax
imul r14, r15
lea r11, [r11 + r14*2]
mov r14d, esi
xor rdx, r11
ror rdx, 0x10
mov r15d, edx
add rsi, rdx
imul r14, r15
mov r15d, ecx
lea rsi, [rsi + r14*2]
mov r14d, r12d
xor rax, rsi
rol rax, 1
imul r14, r15
add r12, rcx
lea r12, [r12 + r14*2]
mov r14d, ebp
xor rdx, r12
rol rdx, 0x20
mov r15d, edx
add rbp, rdx
imul r14, r15
lea rbp, [rbp + r14*2]
mov r14d, r12d
xor rcx, rbp
ror rcx, 0x18
mov r15d, ecx
add r12, rcx
imul r14, r15
lea r12, [r12 + r14*2]
mov r14d, ebp
xor rdx, r12
mov qword [r13], r12
ror rdx, 0x10
mov r12d, edx
mov qword [r13 + 0x78], rdx
add rdx, rbp
imul r12, r14
lea rdx, [rdx + r12*2]
xor rcx, rdx
mov qword [r13 + 0x50], rdx
mov edx, edi
add rdi, r10
rol rcx, 1
mov qword [r13 + 0x28], rcx
mov ecx, r10d
imul rdx, rcx
mov ecx, esi
lea rdx, [rdi + rdx*2]
xor r8, rdx
rol r8, 0x20
mov edi, r8d
add rsi, r8
imul rcx, rdi
lea rcx, [rsi + rcx*2]
mov esi, edx
xor r10, rcx
ror r10, 0x18
mov edi, r10d
add rdx, r10
imul rsi, rdi
mov rdi, qword [rsp + 0x40]
lea rdx, [rdx + rsi*2]
xor r8, rdx
mov qword [r13 + 8], rdx
mov edx, ecx
ror r8, 0x10
mov esi, r8d
mov qword [r13 + 0x60], r8
add r8, rcx
mov ecx, ebx
imul rdx, rsi
mov rsi, qword [rsp + 0x30]
lea rdx, [r8 + rdx*2]
mov r8d, edi
mov qword [r13 + 0x58], rdx
xor r10, rdx
mov edx, eax
rol r10, 1
imul rdx, rcx
add rbx, rax
sub r13, 0xffffffffffffff80
mov qword [r13 - 0x50], r10
lea rcx, [rbx + rdx*2]
xor rsi, rcx
mov ebx, ecx
mov rdx, rsi
rol rdx, 0x20
mov r10d, edx
imul r10, r8
lea r8, [rdx + rdi]
lea r8, [r8 + r10*2]
xor rax, r8
ror rax, 0x18
mov r10d, eax
add rcx, rax
imul r10, rbx
lea rcx, [rcx + r10*2]
mov r10d, r8d
xor rdx, rcx
mov qword [r13 - 0x70], rcx
ror rdx, 0x10
mov ecx, edx
mov qword [r13 - 0x18], rdx
add rdx, r8
imul rcx, r10
lea rdx, [rdx + rcx*2]
mov qword [r13 - 0x40], rdx
xor rax, rdx
mov rbx, qword [rsp + 0x38]
mov edx, r11d
rol rax, 1
mov rdi, qword [rsp + 0x28]
mov qword [r13 - 0x48], rax
mov eax, ebx
add r11, rbx
imul rax, rdx
lea rdx, [r11 + rax*2]
mov eax, edi
xor r9, rdx
mov r10d, edx
rol r9, 0x20
mov ecx, r9d
imul rcx, rax
lea rax, [r9 + rdi]
lea rcx, [rax + rcx*2]
mov rax, rbx
xor rax, rcx
ror rax, 0x18
mov r8d, eax
add rdx, rax
imul r8, r10
lea rdx, [rdx + r8*2]
mov r8d, ecx
xor r9, rdx
mov qword [r13 - 0x68], rdx
ror r9, 0x10
mov edx, r9d
mov qword [r13 - 0x10], r9
add r9, rcx
imul rdx, r8
lea rdx, [r9 + rdx*2]
xor rax, rdx
mov qword [r13 - 0x38], rdx
rol rax, 1
mov qword [r13 - 0x60], rax
cmp qword [rsp + 0x48], r13
jne 0x4a16e0
mov rax, qword [rsp + 0x58]
mov rsi, qword [rsp + 0x50]
sub rax, 0xffffffffffffff80
mov qword [rsp + 0x50], rax
nop
mov rax, qword [rsi + 0x100]
mov rdx, qword [rsi]
mov r9, qword [rsi + 0x300]
mov r8d, eax
mov ecx, edx
add rdx, rax
imul rcx, r8
lea rcx, [rdx + rcx*2]
mov rdx, qword [rsi + 0x200]
xor r9, rcx
rol r9, 0x20
mov r8d, edx
mov r10d, r9d
add rdx, r9
imul r8, r10
lea rdx, [rdx + r8*2]
mov r8d, ecx
xor rax, rdx
ror rax, 0x18
mov r10d, eax
add rcx, rax
imul r8, r10
lea r13, [rcx + r8*2]
mov ecx, edx
xor r9, r13
ror r9, 0x10
mov r8d, r9d
add rdx, r9
imul rcx, r8
lea rdi, [rdx + rcx*2]
mov rcx, qword [rsi + 0x108]
xor rax, rdi
mov qword [rsp + 0x40], rdi
rol rax, 1
mov r8d, ecx
mov qword [rsp + 0x38], rax
mov rax, qword [rsi + 8]
mov edx, eax
add rax, rcx
imul rdx, r8
lea r8, [rax + rdx*2]
mov rdx, qword [rsi + 0x308]
mov rax, qword [rsi + 0x208]
xor rdx, r8
mov r10d, eax
rol rdx, 0x20
mov r11d, edx
add rax, rdx
imul r10, r11
lea rax, [rax + r10*2]
mov r10d, r8d
xor rcx, rax
ror rcx, 0x18
mov r11d, ecx
add r8, rcx
imul r10, r11
lea rbp, [r8 + r10*2]
xor rdx, rbp
ror rdx, 0x10
mov rdi, rdx
mov edx, eax
mov r8d, edi
add rax, rdi
mov qword [rsp + 0x30], rdi
imul rdx, r8
lea rdx, [rax + rdx*2]
mov rax, qword [rsi + 0x80]
xor rcx, rdx
mov qword [rsp + 0x28], rdx
mov rdx, qword [rsi + 0x180]
mov r8d, eax
rol rcx, 1
mov r10d, edx
imul r8, r10
add rax, rdx
lea r10, [rax + r8*2]
mov r8, qword [rsi + 0x380]
mov rax, qword [rsi + 0x280]
xor r8, r10
mov ebx, eax
rol r8, 0x20
mov r11d, r8d
add rax, r8
imul r11, rbx
mov ebx, r10d
lea rax, [rax + r11*2]
xor rdx, rax
ror rdx, 0x18
mov r11d, edx
add r10, rdx
imul r11, rbx
lea rbx, [r10 + r11*2]
mov r11d, eax
xor r8, rbx
ror r8, 0x10
mov r10d, r8d
add rax, r8
imul r10, r11
lea r12, [rax + r10*2]
mov rax, qword [rsi + 0x188]
mov r10, qword [rsi + 0x88]
xor rdx, r12
mov edi, r10d
mov r11d, eax
add r10, rax
rol rdx, 1
imul r11, rdi
mov rdi, qword [rsi + 0x288]
mov r15d, edi
lea r11, [r10 + r11*2]
mov r10, qword [rsi + 0x388]
xor r10, r11
rol r10, 0x20
mov r14d, r10d
add rdi, r10
imul r14, r15
mov r15d, r11d
lea rdi, [rdi + r14*2]
xor rax, rdi
ror rax, 0x18
mov r14d, eax
add r11, rax
imul r14, r15
mov r15d, edi
lea r11, [r11 + r14*2]
xor r10, r11
ror r10, 0x10
mov r14d, r10d
add rdi, r10
imul r14, r15
mov r15d, r13d
lea rdi, [rdi + r14*2]
mov r14d, ecx
xor rax, rdi
rol rax, 1
imul r14, r15
add r13, rcx
mov r15d, r12d
lea r13, [r13 + r14*2]
xor r10, r13
rol r10, 0x20
mov r14d, r10d
add r12, r10
imul r14, r15
mov r15d, r13d
lea r12, [r12 + r14*2]
xor rcx, r12
ror rcx, 0x18
mov r14d, ecx
add r13, rcx
imul r14, r15
lea r13, [r13 + r14*2]
xor r10, r13
mov qword [rsi], r13
mov r13d, r12d
ror r10, 0x10
mov r14d, r10d
mov qword [rsi + 0x388], r10
add r10, r12
imul r13, r14
lea r10, [r10 + r13*2]
xor rcx, r10
mov qword [rsi + 0x280], r10
mov r10d, ebp
add rbp, rdx
rol rcx, 1
mov qword [rsi + 0x108], rcx
mov ecx, edx
imul rcx, r10
lea rcx, [rbp + rcx*2]
mov ebp, edi
xor r9, rcx
rol r9, 0x20
mov r10d, r9d
add rdi, r9
imul r10, rbp
mov ebp, ecx
lea r10, [rdi + r10*2]
xor rdx, r10
ror rdx, 0x18
mov edi, edx
add rcx, rdx
imul rdi, rbp
lea rcx, [rcx + rdi*2]
xor r9, rcx
mov qword [rsi + 8], rcx
mov ecx, r10d
ror r9, 0x10
mov edi, r9d
mov qword [rsi + 0x300], r9
add r9, r10
imul rcx, rdi
mov rdi, qword [rsp + 0x30]
lea rcx, [r9 + rcx*2]
xor rdx, rcx
mov qword [rsi + 0x288], rcx
mov ecx, eax
rol rdx, 1
mov qword [rsi + 0x180], rdx
mov edx, ebx
imul rdx, rcx
add rbx, rax
add rsi, 0x10
lea r9, [rbx + rdx*2]
xor rdi, r9
mov rcx, rdi
mov rdi, qword [rsp + 0x40]
rol rcx, 0x20
mov edx, ecx
mov r10d, edi
imul r10, rdx
lea rdx, [rcx + rdi]
lea r10, [rdx + r10*2]
mov edx, r9d
xor rax, r10
ror rax, 0x18
mov ebx, eax
add r9, rax
imul rdx, rbx
lea rdx, [r9 + rdx*2]
mov qword [rsi + 0x70], rdx
xor rdx, rcx
mov ecx, r10d
ror rdx, 0x10
mov r9d, edx
mov qword [rsi + 0x2f8], rdx
add rdx, r10
imul rcx, r9
lea rdx, [rdx + rcx*2]
mov qword [rsi + 0x1f0], rdx
mov rbx, qword [rsp + 0x38]
xor rdx, rax
mov eax, r11d
rol rdx, 1
mov rdi, qword [rsp + 0x28]
mov qword [rsi + 0x178], rdx
mov edx, ebx
add r11, rbx
imul rax, rdx
lea rdx, [r11 + rax*2]
mov eax, edi
xor r8, rdx
rol r8, 0x20
mov ecx, r8d
imul rax, rcx
lea rcx, [r8 + rdi]
lea r9, [rcx + rax*2]
mov rax, rbx
xor rax, r9
ror rax, 0x18
mov rcx, rax
mov eax, edx
mov r10d, ecx
add rdx, rcx
imul rax, r10
lea rax, [rdx + rax*2]
xor r8, rax
mov qword [rsi + 0x78], rax
mov eax, r9d
ror r8, 0x10
mov edx, r8d
mov qword [rsi + 0x370], r8
add r8, r9
imul rax, rdx
lea rax, [r8 + rax*2]
mov qword [rsi + 0x1f8], rax
xor rax, rcx
rol rax, 1
mov qword [rsi + 0xf0], rax
cmp qword [rsp + 0x50], rsi
jne 0x4a1aa0
mov rdx, qword [rsp + 0x48]
mov rcx, qword [rsp + 0x8c0]
call fcn.004a1560
mov rdx, qword [rsp + 0x58]
mov rcx, qword [rsp + 0x8c0]
call fcn.004a15a0
nop
add rsp, 0x868
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov rdx, qword [rsp + 0x8c0]
mov rcx, qword [rsp + 0x48]
call fcn.004a15a0
jmp 0x4a16ce