Function at 0x22dbb6bb0
Capabilities:
Encode data using xor

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x58
lea rbx, [0x22dddfe80]
mov eax, dword [rcx + 0x80]
mov r12, rcx
mov rdi, rdx
mov rsi, r8
test eax, eax
je 0x22dbb6bfd
jmp 0x22dbb6c1a
lea rdx, [rax + 1]
mov qword [r12 + 0x28], rdx
movzx eax, byte [rax]
cmp al, 0x4f
je 0x22dbb6c43
mov r8d, dword [r12 + 0x80]
test r8d, r8d
jne 0x22dbb6c1a
mov rax, qword [r12 + 0x28]
test rax, rax
je 0x22dbb6c30
cmp rax, qword [r12 + 0x38]
jb 0x22dbb6be0
mov dword [r12 + 0x80], 1
xor eax, eax
add rsp, 0x58
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov rcx, qword [r12 + 0x18]
call sub.msvcrt.dll_fgetc
cmp eax, 0xffffffff
je 0x22dbb6c0e
cmp al, 0x4f
jne 0x22dbb6bf0
cmp byte [r12 + 0x44], 0
jne 0x22dbb6e50
mov rax, qword [r12 + 0x28]
test rax, rax
je 0x22dbb6ec2
mov rdx, rax
sub rdx, qword [r12 + 0x30]
mov r13d, edx
sub edx, 0x19
cmp edx, dword [r12 + 0x40]
ja 0x22dbb6c1a
mov rdx, qword [r12 + 0x38]
movzx r8d, byte [0x22dd0d701]
cmp rdx, rax
jbe 0x22dbb6de0
lea rcx, [rax + 1]
mov qword [r12 + 0x28], rcx
cmp byte [rax], r8b
jne 0x22dbb6e90
movzx r8d, byte [0x22dd0d702]
cmp rcx, rdx
jae 0x22dbb6e1d
lea rax, [rcx + 1]
mov qword [r12 + 0x28], rax
cmp byte [rcx], r8b
jne 0x22dbb6e90
cmp rax, rdx
jae 0x22dbb6c0e
lea rdx, [rax + 1]
mov qword [r12 + 0x28], rdx
movzx eax, byte [rax]
cmp al, byte [0x22dd0d703]
mov edx, dword [r12 + 0x80]
jne 0x22dbb713b
test edx, edx
jne 0x22dbb6c1a
mov eax, dword [str.OggS]
lea rbp, [rsp + 0x34]
lea r15, [rsp + 0x30]
lea r14, [rsp + 0x4b]
mov dword [rsp + 0x30], eax
jmp 0x22dbb6d2a
mov dword [r12 + 0x80], 1
xor eax, eax
mov byte [rbp], al
add rbp, 1
cmp rbp, r14
je 0x22dbb6d57
mov rax, qword [r12 + 0x28]
test rax, rax
je 0x22dbb6dc0
cmp rax, qword [r12 + 0x38]
jae 0x22dbb6d10
lea rcx, [rax + 1]
add rbp, 1
mov qword [r12 + 0x28], rcx
movzx eax, byte [rax]
mov byte [rbp - 1], al
cmp rbp, r14
jne 0x22dbb6d2a
mov edx, dword [r12 + 0x80]
test edx, edx
jne 0x22dbb6c1a
cmp byte [rsp + 0x34], 0
je 0x22dbb6edd
cmp byte [r12 + 0x44], 0
jne 0x22dbb6ea8
cmp qword [r12 + 0x28], 0
mov dword [r12 + 0x80], 0
je 0x22dbb6f96
mov rax, qword [r12 + 0x38]
add r13, qword [r12 + 0x30]
cmp r13, rax
jb 0x22dbb6eb8
mov qword [r12 + 0x28], rax
mov dword [r12 + 0x80], 1
jmp 0x22dbb6c1a
mov rcx, qword [r12 + 0x18]
call sub.msvcrt.dll_fgetc
cmp eax, 0xffffffff
jne 0x22dbb6d1e
jmp 0x22dbb6d10
cmp byte [0x22dd0d701], 0
mov dword [r12 + 0x80], 1
jne 0x22dbb6c1a
mov rcx, qword [r12 + 0x28]
test rcx, rcx
je 0x22dbb6ff0
mov rdx, qword [r12 + 0x38]
movzx r8d, byte [0x22dd0d702]
cmp rcx, rdx
jb 0x22dbb6cab
cmp byte [0x22dd0d702], 0
mov dword [r12 + 0x80], 1
jne 0x22dbb6c1a
mov rax, qword [r12 + 0x28]
test rax, rax
je 0x22dbb7014
mov rdx, qword [r12 + 0x38]
jmp 0x22dbb6cbd
mov eax, 0xffffffe7
xor r13d, r13d
cmp dword [r12 + 0x40], eax
jb 0x22dbb6c1a
mov rax, qword [r12 + 0x28]
test rax, rax
jne 0x22dbb6c72
mov rcx, qword [r12 + 0x18]
call sub.msvcrt.dll_fgetc
cmp eax, 0xffffffff
je 0x22dbb6de0
cmp byte [0x22dd0d701], al
je 0x22dbb6df9
mov ecx, dword [r12 + 0x80]
test ecx, ecx
je 0x22dbb6d72
jmp 0x22dbb6c1a
mov eax, dword [r12 + 0x80]
jmp 0x22dbb6bd6
mov qword [r12 + 0x28], r13
jmp 0x22dbb6bfd
mov rcx, qword [r12 + 0x18]
call sub.msvcrt.dll_ftell
sub eax, dword [r12 + 0x20]
mov r13d, eax
lea eax, [r13 - 0x19]
jmp 0x22dbb6e58
movzx eax, byte [rsp + 0x47]
xor ebp, ebp
shl eax, 8
mov edx, eax
movzx eax, byte [rsp + 0x46]
add edx, eax
movzx eax, byte [rsp + 0x48]
shl eax, 0x10
add edx, eax
movzx eax, byte [rsp + 0x49]
mov dword [rsp + 0x46], 0
shl eax, 0x18
add eax, edx
mov dword [rsp + 0x2c], eax
mov eax, ebp
add r15, 1
shl ebp, 8
shr eax, 0x18
xor al, byte [r15 - 1]
movzx eax, al
xor ebp, dword [rbx + rax*4]
cmp r14, r15
jne 0x22dbb6f10
movzx r8d, byte [rsp + 0x4a]
test r8d, r8d
je 0x22dbb706a
xor r15d, r15d
xor r14d, r14d
jmp 0x22dbb6f71
lea rcx, [rax + 1]
mov qword [r12 + 0x28], rcx
movzx ecx, byte [rax]
add r15d, ecx
mov eax, ebp
add r14d, 1
shl ebp, 8
shr eax, 0x18
xor eax, ecx
xor ebp, dword [rbx + rax*4]
cmp r14d, r8d
je 0x22dbb70c0
mov rax, qword [r12 + 0x28]
test rax, rax
je 0x22dbb702c
cmp rax, qword [r12 + 0x38]
jb 0x22dbb6f48
mov dword [r12 + 0x80], 1
xor ecx, ecx
jmp 0x22dbb6f57
mov edx, r13d
add edx, dword [r12 + 0x20]
jb 0x22dbb7054
test r13d, r13d
js 0x22dbb7054
mov rcx, qword [r12 + 0x18]
xor r8d, r8d
call sub.msvcrt.dll_fseek
test eax, eax
je 0x22dbb6ea8
mov edx, dword [r12 + 0x20]
mov rcx, qword [r12 + 0x18]
mov dword [r12 + 0x80], 1
mov r8d, 2
call sub.msvcrt.dll_fseek
mov eax, dword [r12 + 0x80]
jmp 0x22dbb6bd6
mov rcx, qword [r12 + 0x18]
call sub.msvcrt.dll_fgetc
cmp eax, 0xffffffff
je 0x22dbb6e1d
cmp byte [0x22dd0d702], al
je 0x22dbb6e36
jmp 0x22dbb6e90
mov rcx, qword [r12 + 0x18]
call sub.msvcrt.dll_fgetc
cmp eax, 0xffffffff
jne 0x22dbb6cd2
jmp 0x22dbb6c0e
mov rcx, qword [r12 + 0x18]
mov dword [rsp + 0x28], r8d
call sub.msvcrt.dll_fgetc
mov r8d, dword [rsp + 0x28]
cmp eax, 0xffffffff
je 0x22dbb6f86
movzx ecx, al
add r15d, ecx
jmp 0x22dbb6f57
mov dword [r12 + 0x80], 1
mov edx, 0x7fffffff
jmp 0x22dbb6fad
cmp dword [rsp + 0x2c], ebp
jne 0x22dbb6d72
test rdi, rdi
je 0x22dbb7098
xor eax, eax
cmp byte [r12 + 0x44], 0
jne 0x22dbb7096
mov rax, qword [r12 + 0x28]
test rax, rax
je 0x22dbb7148
sub eax, dword [r12 + 0x30]
mov dword [rdi], eax
test rsi, rsi
je 0x22dbb70a9
xor eax, eax
test byte [rsp + 0x35], 4
setne al
mov dword [rsi], eax
lea edx, [r13 - 1]
mov rcx, r12
call fcn.22dce7b90
mov eax, 1
jmp 0x22dbb6c1c
test r15d, r15d
je 0x22dbb706a
mov eax, dword [r12 + 0x80]
test eax, eax
jne 0x22dbb6c1a
xor r14d, r14d
jmp 0x22dbb7108
mov dword [r12 + 0x80], 1
xor ecx, ecx
mov eax, ebp
add r14d, 1
shl ebp, 8
shr eax, 0x18
xor eax, ecx
xor ebp, dword [rbx + rax*4]
cmp r14d, r15d
je 0x22dbb706a
mov rax, qword [r12 + 0x28]
test rax, rax
je 0x22dbb7127
cmp rax, qword [r12 + 0x38]
jae 0x22dbb70e0
lea rcx, [rax + 1]
mov qword [r12 + 0x28], rcx
movzx ecx, byte [rax]
jmp 0x22dbb70ee
mov rcx, qword [r12 + 0x18]
call sub.msvcrt.dll_fgetc
cmp eax, 0xffffffff
je 0x22dbb70e0
movzx ecx, al
jmp 0x22dbb70ee
test edx, edx
je 0x22dbb6d72
jmp 0x22dbb6c1a
mov rcx, qword [r12 + 0x18]
call sub.msvcrt.dll_ftell
sub eax, dword [r12 + 0x20]
jmp 0x22dbb7096