Function at 0x180004a70
Capabilities:
Encode data using xor

Disassembly:
push rbx
push rsi
push rdi
sub rsp, 0x500
mov rax, qword [0x18002d0a0]
xor rax, rsp
mov qword [rsp + 0x4e0], rax
xor edx, edx
mov rsi, rcx
lea rcx, [rsp + 0x70]
lea r8d, [rdx + 0x64]
call fcn.180016a80
cmp qword [rsi + 0x20], 0xffffffffffffffff
je 0x180004e7b
xor edi, edi
mov ebx, edi
nop
mov r10, qword [rsi + 0x10]
mov rcx, qword [rsi + 0x20]
movsxd rax, ebx
mov r8d, 0xd
lea rdx, [rsp + rax + 0x70]
xor r9d, r9d
sub r8d, ebx
call qword [r10 + 0x58]
test eax, eax
jle 0x180004e7b
add ebx, eax
cmp ebx, 0xd
jl 0x180004ab0
mov r8d, edi
lea r9, [rsp + 0x70]
nop word [rax + rax]
movzx ecx, byte [r9]
mov eax, 0x51eb851f
inc r9
xor cl, 0xb2
mul r8d
shr edx, 5
mov al, 0x64
imul dl
add al, cl
sub al, r8b
inc r8d
mov byte [r9 - 1], al
cmp r8d, 0xd
jb 0x180004af0
cmp byte [rsp + 0x78], 1
lea rcx, [rsp + 0x70]
lea rdx, [rsp + 0x48]
mov rax, qword [rcx]
mov qword [rdx], rax
mov eax, dword [rcx + 8]
mov dword [rdx + 8], eax
movzx eax, byte [rcx + 0xc]
mov byte [rdx + 0xc], al
jne 0x180004e7b
mov qword [rsp + 0x528], rbp
mov ebp, dword [rsp + 0x79]
mov qword [rsp + 0x530], r12
mov rcx, rbp
call fcn.180005500
mov r8, rbp
xor edx, edx
mov rcx, rax
mov r12, rax
call fcn.180016a80
cmp qword [rsi + 0x20], 0xffffffffffffffff
je 0x180004e74
lea rcx, [rsi + 8]
mov r8d, ebp
mov rdx, r12
call fcn.1800047c0
test al, al
je 0x180004e74
mov qword [rsp + 0x4f8], r13
mov ecx, 0x1400000
mov qword [rsp + 0x4f0], r14
mov r14d, edi
mov r13, rdi
mov dword [rsp + 0x40], 0x1400000
call fcn.180014984
mov rbx, rax
test rax, rax
jne 0x180004bc8
mov ebx, edi
jmp 0x180004c61
mov ebp, dword [rsp + 0x51]
lea rdx, [rsp + 0x40]
mov r8, r12
mov r9d, ebp
mov rcx, rax
call fcn.1800057d0
test eax, eax
je 0x180004c23
cmp eax, 0xfffffffb
jne 0x180004c38
mov rcx, rbx
call fcn.1800148a0
mov r11d, dword [rsp + 0x40]
add r11d, 0x100000
mov ecx, r11d
mov dword [rsp + 0x40], r11d
call fcn.180014984
lea rdx, [rsp + 0x40]
mov r9d, ebp
mov rcx, rax
mov r8, r12
mov rbx, rax
call fcn.1800057d0
test eax, eax
jne 0x180004be3
mov ecx, dword [rsp + 0x40]
call fcn.180014984
mov rbp, rax
test rax, rax
jne 0x180004c44
mov ebx, edi
jmp 0x180004c61
mov rcx, rbx
call fcn.1800148a0
mov ebx, edi
jmp 0x180004c61
mov r8d, dword [rsp + 0x40]
mov rdx, rbx
mov rcx, rax
call fcn.180016730
mov r14d, dword [rsp + 0x40]
mov r13, rbp
mov ebx, 1
mov rcx, r12
call fcn.1800148a0
test ebx, ebx
jne 0x180004cb2
mov rcx, r13
call fcn.1800148a0
xor eax, eax
mov r13, qword [rsp + 0x4f8]
mov r14, qword [rsp + 0x4f0]
mov rbp, qword [rsp + 0x528]
mov r12, qword [rsp + 0x530]
mov rcx, qword [rsp + 0x4e0]
xor rcx, rsp
call fcn.1800147e0
add rsp, 0x500
pop rdi
pop rsi
pop rbx
ret
mov qword [rsp + 0x38], rdi
lea rax, [0x180002320]
lea r9, [0x1800022f0]
mov qword [rsp + 0x30], rax
lea rax, [0x180002310]
lea r8, [0x1800022e0]
mov qword [rsp + 0x28], rax
lea rax, [0x180002300]
mov edx, r14d
mov rcx, r13
mov qword [rsp + 0x20], rax
call fcn.180002330
mov rcx, r13
mov rbx, rax
call fcn.1800148a0
mov dword [rsp + 0x54], 2
test rbx, rbx
jne 0x180004dc3
lea rcx, [rsp + 0xe0]
xor edx, edx
mov r8d, 0x400
mov dword [rsp + 0x50], edi
mov dword [rsp + 0x58], 1
call fcn.180016a80
mov r10, qword [rsi + 0x20]
lea rcx, [rsp + 0x48]
lea r11, [rsp + 0xe0]
mov rax, qword [rcx]
mov qword [r11], rax
mov rax, qword [rcx + 8]
mov qword [r11 + 8], rax
mov eax, dword [rcx + 0x10]
mov dword [r11 + 0x10], eax
cmp r10, 0xffffffffffffffff
je 0x180004dbc
lea r8, [rsp + 0xe0]
nop word [rax + rax]
mov eax, 0x51eb851f
inc r8
mul edi
mov al, 0x64
shr edx, 5
imul dl
mov cl, al
movzx eax, dil
inc edi
sub al, cl
add al, byte [r8 - 1]
xor al, 0xb2
mov byte [r8 - 1], al
cmp edi, 0x14
jb 0x180004d70
mov rax, qword [rsi + 0x10]
xor r9d, r9d
lea rdx, [rsp + 0xe0]
lea r8d, [r9 + 0x14]
mov rcx, r10
call qword [rax + 0x50]
cmp eax, 0xffffffff
jne 0x180004e6c
xor eax, eax
jmp 0x180004c77
lea rcx, [rsp + 0xe0]
xor edx, edx
mov r8d, 0x400
mov dword [rsp + 0x50], edi
mov dword [rsp + 0x58], 2
call fcn.180016a80
mov r10, qword [rsi + 0x20]
lea rcx, [rsp + 0x48]
lea r11, [rsp + 0xe0]
mov rax, qword [rcx]
mov qword [r11], rax
mov rax, qword [rcx + 8]
mov qword [r11 + 8], rax
mov eax, dword [rcx + 0x10]
mov dword [r11 + 0x10], eax
cmp r10, 0xffffffffffffffff
je 0x180004dbc
lea r8, [rsp + 0xe0]
nop dword [rax + rax]
mov eax, 0x51eb851f
inc r8
mul edi
mov al, 0x64
shr edx, 5
imul dl
mov cl, al
movzx eax, byte [r8 - 1]
sub al, cl
add al, dil
inc edi
xor al, 0xb2
mov byte [r8 - 1], al
cmp edi, 0x14
jb 0x180004e20
mov rax, qword [rsi + 0x10]
xor r9d, r9d
lea rdx, [rsp + 0xe0]
lea r8d, [r9 + 0x14]
mov rcx, r10
call qword [rax + 0x50]
cmp eax, 0xffffffff
je 0x180004dbc
mov rax, rbx
jmp 0x180004c77
xor eax, eax
jmp 0x180004c87
xor eax, eax
jmp 0x180004c97