Function at 0x4aee20
Capabilities:
Encode data using xor

Disassembly:
push r15
push r14
mov eax, 0x2e08
push r13
push r12
push rbp
push rdi
push rsi
push rbx
call fcn.004a3410
sub rsp, rax
test rcx, rcx
mov rbp, rcx
mov r12, r8
je 0x4aee60
mov rax, qword [rcx + 0x58]
test rax, rax
je 0x4aee60
cmp edx, dword [rcx + 0x10]
jae 0x4aee60
cmp dword [rcx + 0x14], 1
je 0x4aee80
nop dword [rax + rax]
xor eax, eax
add rsp, 0x2e08
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov rcx, qword [rax + 0x20]
mov edi, edx
mov qword [rsp + 0x60], r9
mov qword [rsp + 0x78], rdi
mov ebx, dword [rcx + rdi*4]
mov rcx, rbx
add rbx, qword [rax]
je 0x4aee60
movzx eax, word [rbx + 4]
mov dword [rsp + 0xb4], ecx
lea rdi, [rsp + 0x300]
movzx ecx, word [rbx + 0xc]
movzx r14d, word [rbx + 8]
movzx r15d, word [rbx + 0xa]
mov dword [rsp + 0xb0], edx
mov dword [rsp + 0x50], edx
mov qword [rsp + 0x70], rdi
mov word [rsp + 0xb8], ax
movzx eax, word [rbx + 6]
mov word [rsp + 0xbc], r14w
mov word [rsp + 0xbe], r15w
mov word [rsp + 0xba], ax
movzx eax, word [rbx + 0xe]
mov qword [rsp + 0x318], 0
mov dword [rsp + 0x320], 0xffffffff
mov r8d, eax
mov r10d, eax
sar eax, 5
and eax, 0xf
sar r10d, 9
and r8d, 0x1f
sub eax, 1
add r10d, 0x50
mov dword [rsp + 0x30c], r8d
mov dword [rsp + 0x310], eax
mov eax, ecx
mov dword [rsp + 0x314], r10d
sar eax, 0xb
mov dword [rsp + 0x308], eax
mov eax, ecx
sar eax, 5
and eax, 0x3f
mov dword [rsp + 0x304], eax
lea eax, [rcx + rcx]
mov rcx, rdi
and eax, 0x3e
mov dword [rsp + 0x300], eax
call qword [sym.imp.msvcrt.dll__mktime64]
mov qword [rsp + 0xc0], rax
mov eax, dword [rbx + 0x10]
mov ecx, 0x103
movzx r11d, word [rbx + 0x1c]
mov esi, dword [rbx + 0x18]
lea r8, [rsp + 0xb0]
mov r13d, dword [rbx + 0x2a]
mov edx, dword [rsp + 0x50]
mov dword [rsp + 0x6c], eax
mov dword [rsp + 0xc8], eax
mov eax, dword [rbx + 0x14]
mov r9, qword [rsp + 0x60]
mov qword [rsp + 0x48], rsi
cmp r11d, 0x103
lea rsi, [rbx + 0x2e]
mov qword [rsp + 0xe8], r13
mov qword [rsp + 0x58], rax
mov qword [rsp + 0x40], rax
movzx eax, word [rbx + 0x24]
movq xmm0, qword [rsp + 0x58]
movhps xmm0, qword [rsp + 0x48]
movaps xmmword [rsp + 0xd0], xmm0
mov word [rsp + 0xe0], ax
mov eax, dword [rbx + 0x26]
mov dword [rsp + 0xe4], eax
mov rax, r11
cmova r11d, ecx
cmp r11d, 8
lea rcx, [r8 + 0x44]
jae 0x4af1a0
test r11b, 4
jne 0x4af250
test r11d, r11d
mov r10d, r11d
je 0x4af02f
movzx edi, byte [rbx + 0x2e]
and r11d, 2
mov byte [r8 + 0x44], dil
jne 0x4af26a
movzx ecx, word [rbx + 0x20]
movzx r11d, word [rbx + 0x1e]
mov byte [rsp + r10 + 0xf4], 0
mov r10d, 0xff
cmp ecx, 0xff
lea rsi, [r11 + rax + 0x2e]
cmova ecx, r10d
lea r10, [r8 + 0x148]
add rsi, rbx
cmp ecx, 8
mov dword [rsp + 0xf0], ecx
jae 0x4af180
test cl, 4
jne 0x4af230
test ecx, ecx
mov eax, ecx
je 0x4af093
movzx r11d, byte [rsi]
and ecx, 2
mov byte [r8 + 0x148], r11b
jne 0x4af27b
cmp qword [rsp + 0x40], 0
mov byte [rsp + rax + 0x1f8], 0
je 0x4af170
mov rax, qword [rbp + 0x58]
test rax, rax
je 0x4af0bf
cmp edx, dword [rbp + 0x10]
jae 0x4af0bf
cmp dword [rbp + 0x14], 1
je 0x4af1f0
and r14d, 0x21
jne 0x4aee60
mov ebx, dword [rsp + 0x2e70]
and ebx, 0x400
je 0x4af1d1
mov rsi, qword [rsp + 0x40]
cmp rsi, r9
ja 0x4aee60
mov rcx, qword [rbp + 0x50]
mov r9d, 0x1e
lea r8, [rsp + 0x90]
mov rdx, r13
call qword [rbp + 0x40]
cmp rax, 0x1e
jne 0x4aee60
cmp dword [rsp + 0x90], 0x4034b50
jne 0x4aee60
movzx edx, word [rsp + 0xaa]
movzx eax, word [rsp + 0xac]
lea eax, [rdx + rax + 0x1e]
cdqe
add r13, rax
mov rax, qword [rsp + 0x40]
add rax, r13
cmp rax, qword [rbp]
ja 0x4aee60
test ebx, ebx
je 0x4af28b
mov rcx, qword [rbp + 0x50]
mov r9, rsi
mov r8, r12
mov rdx, r13
call qword [rbp + 0x40]
cmp rsi, rax
jne 0x4aee60
nop dword [rax]
mov eax, 1
jmp 0x4aee62
mov eax, ecx
sub ecx, 1
mov rdi, r10
mov r8, qword [rsi + rax - 8]
shr ecx, 3
mov qword [r10 + rax - 8], r8
rep movsq qword [rdi], qword [rsi]
jmp 0x4af093
mov r10, qword [rbx + 0x2e]
mov qword [rsp + 0xf4], r10
mov r10d, r11d
mov rdi, qword [rsi + r10 - 8]
mov qword [rcx + r10 - 8], rdi
lea rdi, [r8 + 0x48]
sub rcx, rdi
sub rsi, rcx
add ecx, r11d
shr ecx, 3
rep movsq qword [rdi], qword [rsi]
jmp 0x4af02f
test r15w, 0xfff7
jne 0x4aee60
mov rsi, qword [rsp + 0x48]
jmp 0x4af0e1
mov rdx, qword [rax + 0x20]
mov rsi, qword [rsp + 0x78]
mov edx, dword [rdx + rsi*4]
add rdx, qword [rax]
je 0x4af0bf
movzx eax, word [rdx + 0x1c]
test ax, ax
je 0x4af219
cmp byte [rdx + rax + 0x2d], 0x2f
je 0x4af170
test byte [rdx + 0x26], 0x10
je 0x4af0bf
jmp 0x4af170
mov eax, dword [rsi]
mov dword [r8 + 0x148], eax
mov eax, ecx
mov ecx, dword [rsi + rax - 4]
mov dword [r10 + rax - 4], ecx
jmp 0x4af093
mov r10d, dword [rbx + 0x2e]
mov dword [r8 + 0x44], r10d
mov r10d, r11d
mov r11d, dword [rsi + r10 - 4]
mov dword [rcx + r10 - 4], r11d
jmp 0x4af02f
movzx r11d, word [rsi + r10 - 2]
mov word [rcx + r10 - 2], r11w
jmp 0x4af02f
movzx ecx, word [rsi + rax - 2]
mov word [r10 + rax - 2], cx
jmp 0x4af093
test r15w, r15w
je 0x4af3c3
mov rax, qword [rbp + 0x58]
mov dword [rsp + 0x300], 0
mov r14, qword [rax + 0x68]
test r14, r14
je 0x4af487
mov rbx, qword [rsp + 0x40]
add r14, r13
mov qword [rsp + 0x40], 0
mov qword [rsp + 0x2e80], rbx
lea rax, [rsp + 0x80]
lea r15, [rsp + 0x88]
xor edi, edi
xor esi, esi
mov qword [rsp + 0x50], rax
mov rax, r15
mov r15, rbp
mov rbp, rdi
mov rdi, rax
jmp 0x4af39a
mov rax, qword [r15 + 0x58]
cmp qword [rax + 0x68], 0
jne 0x4af3b3
mov rax, qword [rsp + 0x40]
cmp rax, qword [rsp + 0x2e80]
mov r8, r14
cmova rax, qword [rsp + 0x2e80]
mov rcx, qword [r15 + 0x50]
mov rdx, r13
mov rbx, rax
mov r9, rax
call qword [r15 + 0x40]
cmp rbx, rax
jne 0x4af4d5
sub qword [rsp + 0x40], rbx
add r13, rbx
mov rdx, r14
xor ebp, ebp
cmp qword [rsp + 0x40], 0
mov qword [rsp + 0x80], rbx
je 0x4af3b9
mov dword [rsp + 0x30], 6
lea rax, [r12 + rsi]
mov r8, qword [rsp + 0x50]
mov rcx, qword [rsp + 0x70]
mov qword [rsp + 0x28], rdi
mov r9, r12
mov qword [rsp + 0x20], rax
call fcn.004bb400
mov rdx, qword [rsp + 0x80]
add rsi, qword [rsp + 0x88]
sub rbx, rdx
add rbp, rdx
cmp eax, 1
jne 0x4af43d
mov rax, qword [rsp + 0x48]
sub rax, rsi
test rbx, rbx
mov qword [rsp + 0x88], rax
je 0x4af2f4
lea rdx, [r14 + rbp]
jmp 0x4af343
mov dword [rsp + 0x30], 4
jmp 0x4af35b
mov rcx, qword [rbp + 0x50]
mov r9, rsi
mov r8, r12
mov rdx, r13
call qword [rbp + 0x40]
cmp rsi, rax
jne 0x4aee60
test r12, r12
je 0x4af439
mov rax, qword [rsp + 0x48]
or ecx, 0xffffffff
test rax, rax
je 0x4af429
add rax, r12
lea r8, [0x004ea440]
mov r9, rax
add r12, 1
movzx edx, byte [r12 - 1]
mov eax, ecx
shr eax, 4
xor ecx, edx
shr dl, 4
and ecx, 0xf
xor eax, dword [r8 + rcx*4]
mov ecx, eax
xor eax, edx
and eax, 0xf
shr ecx, 4
xor ecx, dword [r8 + rax*4]
cmp r12, r9
jne 0x4af3fb
not ecx
xor eax, eax
cmp ecx, dword [rsp + 0x6c]
sete al
jmp 0x4aee62
xor ecx, ecx
jmp 0x4af42b
test eax, eax
mov rbp, r15
jne 0x4af452
or eax, 0xffffffff
cmp rsi, qword [rsp + 0x48]
je 0x4af4e0
mov rdx, qword [rbp + 0x58]
cmp qword [rdx + 0x68], 0
jne 0x4af47a
cmp qword [rsp + 0x2e78], 0
jne 0x4af47a
mov dword [rsp + 0x40], eax
mov rcx, qword [rbp + 0x38]
mov rdx, r14
call qword [rbp + 0x28]
mov eax, dword [rsp + 0x40]
test eax, eax
sete al
movzx eax, al
jmp 0x4aee62
cmp qword [rsp + 0x2e78], 0
jne 0x4af53c
mov rsi, qword [rsp + 0x40]
mov eax, 0x10000
mov rcx, qword [rbp + 0x38]
mov edx, 1
cmp rsi, 0x10000
cmovbe rax, rsi
mov qword [rsp + 0x2e80], rax
mov r8, rax
call qword [rbp + 0x20]
test rax, rax
mov r14, rax
je 0x4aee60
xor ebx, ebx
jmp 0x4af2ca
mov rbp, r15
or eax, 0xffffffff
jmp 0x4af452
test r12, r12
je 0x4af55a
xor r8d, r8d
mov ecx, eax
lea r9, [0x004ea440]
jmp 0x4af520
movzx r10d, byte [r12 + r8]
mov edx, ecx
mov eax, ecx
shr eax, 4
add r8, 1
xor edx, r10d
shr r10b, 4
and edx, 0xf
xor eax, dword [r9 + rdx*4]
mov ecx, eax
xor eax, r10d
and eax, 0xf
shr ecx, 4
xor ecx, dword [r9 + rax*4]
cmp qword [rsp + 0x48], r8
jne 0x4af4f3
mov eax, ecx
not eax
cmp eax, dword [rsp + 0x6c]
setne al
movzx eax, al
neg eax
jmp 0x4af452
cmp qword [rsp + 0x2e80], 0
je 0x4aee60
mov r14, qword [rsp + 0x2e78]
xor ebx, ebx
jmp 0x4af2ca
xor eax, eax
jmp 0x4af52b