Function at 0x2d9e3b1ff0
Capabilities:
Encode data using xor

Disassembly:
mov qword [rsp + 0x10], rdx
mov qword [rsp + 8], rcx
push rbp
push rbx
push rsi
push rdi
push r13
mov rbp, rsp
sub rsp, 0x70
mov ebx, r8d
movzx r13d, r9b
mov rdi, rdx
mov rsi, rcx
test r8d, r8d
jg 0x2d9e3b2026
xor eax, eax
add rsp, 0x70
pop r13
pop rdi
pop rsi
pop rbx
pop rbp
ret
mov qword [rsp + 0x68], r14
movzx eax, r13b
mov qword [rsp + 0x60], r15
add eax, 0xfffffff1
xor r15d, r15d
mov dword [rbp + 0x40], ebx
mov qword [rbp - 0x38], r15
mov r14d, r15d
cmp eax, 0x50
ja case.0x2d9e3b2068.16
lea rdx, [0x2d9e3b0000]
cdqe
movzx eax, byte [rdx + rax + 0x2590]
mov ecx, dword [rdx + rax*4 + 0x2574]
add rcx, rdx
jmp rcx
mov rcx, rbx
mov dword [rbp + 0x40], ebx
call fcn.2d9e3da838
mov edx, r15d
mov r14, rax
cmp dword [rbp + 0x40], edx
jbe 0x2d9e3b2177
nop dword [rax]
nop dword [rax + rax]
mov ecx, edx
inc edx
movzx eax, byte [rcx + rdi]
xor al, 0x88
mov byte [rcx + r14], al
cmp edx, dword [rbp + 0x40]
jb 0x2d9e3b2090
jmp 0x2d9e3b2177
mov eax, 0x10624dd3
imul ebx
sar edx, 6
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rbx + 0xc]
add eax, edx
mov ecx, eax
mov dword [rbp + 0x40], eax
call fcn.2d9e3da838
mov r9d, ebx
lea rdx, [rbp + 0x40]
mov r8, rdi
mov rcx, rax
mov r14, rax
call fcn.2d9e3dbcd0
test eax, eax
je 0x2d9e3b2177
mov rcx, r14
call fcn.2d9e3da7f4
mov r14, r15
mov r13b, 0xf
mov dword [rbp + 0x40], ebx
jmp 0x2d9e3b2177
mov eax, 0x10624dd3
imul ebx
sar edx, 6
mov eax, edx
shr eax, 0x1f
add edx, eax
lea eax, [rbx + 0xc]
add eax, edx
mov ecx, eax
mov dword [rbp + 0x40], eax
call fcn.2d9e3da838
mov r9d, ebx
lea rdx, [rbp + 0x40]
mov r8, rdi
mov rcx, rax
mov r14, rax
call fcn.2d9e3dbcd0
test eax, eax
jne 0x2d9e3b20e5
mov ecx, r15d
cmp dword [rbp + 0x40], ecx
jbe 0x2d9e3b2177
nop dword [rax]
mov eax, ecx
inc ecx
xor byte [rax + r14], 0x88
cmp ecx, dword [rbp + 0x40]
jb 0x2d9e3b2140
jmp 0x2d9e3b2177
lea rax, [rbp + 0x40]
mov r8d, ebx
lea r9, [rbp - 0x38]
mov qword [rsp + 0x20], rax
mov rdx, rdi
mov rcx, rsi
call fcn.2d9e3b18a0
test eax, eax
je 0x2d9e3b20f0
mov r14, qword [rbp - 0x38]
mov eax, dword [rbp + 0x40]
lea rdx, [rsi + 0x70]
add eax, 0xa
mov qword [rsp + 0xb8], r12
xorps xmm0, xmm0
mov dword [rbp - 0x38], eax
mov r8d, 1
mov dword [rbp - 0x18], r15d
lea rcx, [rbp - 0x28]
movdqu xmmword [rbp - 0x28], xmm0
call fcn.2d9e3bde20
mov rdi, qword [rbp - 0x28]
mov esi, dword [rbp - 0x20]
mov r12d, dword [rbp - 0x28]
test rdi, rdi
jne 0x2d9e3b2208
mov eax, r15d
jmp 0x2d9e3b220d
lea rax, [rbp + 0x40]
mov r8d, ebx
lea r9, [rbp - 0x38]
mov qword [rsp + 0x20], rax
mov rdx, rdi
mov rcx, rsi
call fcn.2d9e3b18a0
test eax, eax
jne 0x2d9e3b21e3
mov r13b, 0xf
mov dword [rbp + 0x40], ebx
jmp 0x2d9e3b2177
mov ecx, r15d
cmp dword [rbp + 0x40], ecx
jbe 0x2d9e3b2173
mov r14, qword [rbp - 0x38]
nop
cmp ecx, 0x3c
jae 0x2d9e3b2177
mov eax, ecx
inc ecx
xor byte [rax + r14], 0x88
cmp ecx, dword [rbp + 0x40]
jb 0x2d9e3b21f0
jmp 0x2d9e3b2177
mov eax, esi
sub eax, r12d
lea ecx, [rax + 1]
mov edx, 0xfffffc00
mov eax, dword [rbp - 0x18]
mov dword [rbp + 0x50], eax
cmp ecx, eax
jb 0x2d9e3b227b
lea eax, [rcx + 0x3ff]
and eax, edx
mov ecx, eax
mov dword [rbp - 0x40], eax
call fcn.2d9e3da838
mov qword [rbp - 0x30], rax
test rax, rax
je 0x2d9e3b2278
test rdi, rdi
jne 0x2d9e3b2244
mov esi, r15d
jmp 0x2d9e3b2263
sub esi, r12d
je 0x2d9e3b2257
mov r8d, esi
mov rdx, rdi
mov rcx, rax
call fcn.2d9e3e2bb0
mov rcx, rdi
call fcn.2d9e3da7f4
mov rax, qword [rbp - 0x30]
mov rdi, rax
mov qword [rbp - 0x28], rax
add rsi, rax
mov r12d, edi
mov eax, dword [rbp - 0x40]
mov dword [rbp + 0x50], eax
jmp 0x2d9e3b227f
mov eax, dword [rbp - 0x18]
mov rsi, qword [rbp - 0x20]
mov byte [rsi], r13b
inc rsi
mov qword [rbp - 0x20], rsi
mov r13d, esi
test rdi, rdi
jne 0x2d9e3b2296
mov ecx, r15d
jmp 0x2d9e3b229c
mov ecx, r13d
sub ecx, r12d
add ecx, 4
cmp ecx, eax
jb 0x2d9e3b2307
lea eax, [rcx + 0x3ff]
mov ecx, 0xfffffc00
and eax, ecx
mov ecx, eax
mov dword [rbp - 0x40], eax
call fcn.2d9e3da838
mov qword [rbp - 0x30], rax
test rax, rax
je 0x2d9e3b2304
test rdi, rdi
jne 0x2d9e3b22cd
mov r13d, r15d
jmp 0x2d9e3b22ec
sub r13d, r12d
je 0x2d9e3b22e0
mov r8d, r13d
mov rdx, rdi
mov rcx, rax
call fcn.2d9e3e2bb0
mov rcx, rdi
call fcn.2d9e3da7f4
mov rax, qword [rbp - 0x30]
mov rdi, rax
mov esi, r13d
add rsi, rax
mov qword [rbp - 0x28], rax
mov eax, dword [rbp - 0x40]
mov r12d, edi
mov dword [rbp + 0x50], eax
jmp 0x2d9e3b2307
mov eax, dword [rbp + 0x50]
mov ecx, dword [rbp - 0x38]
mov dword [rsi], ecx
add rsi, 4
mov qword [rbp - 0x20], rsi
mov r13d, esi
test rdi, rdi
jne 0x2d9e3b2321
mov ecx, r15d
jmp 0x2d9e3b2327
mov ecx, r13d
sub ecx, r12d
add ecx, 4
cmp ecx, eax
jb 0x2d9e3b238f
lea eax, [rcx + 0x3ff]
mov ecx, 0xfffffc00
and eax, ecx
mov ecx, eax
mov dword [rbp - 0x38], eax
call fcn.2d9e3da838
mov qword [rbp - 0x30], rax
test rax, rax
je 0x2d9e3b238c
test rdi, rdi
jne 0x2d9e3b2358
mov r13d, r15d
jmp 0x2d9e3b2377
sub r13d, r12d
je 0x2d9e3b236b
mov r8d, r13d
mov rdx, rdi
mov rcx, rax
call fcn.2d9e3e2bb0
mov rcx, rdi
call fcn.2d9e3da7f4
mov rax, qword [rbp - 0x30]
mov rdi, rax
mov esi, r13d
add rsi, rax
mov qword [rbp - 0x28], rax
mov eax, dword [rbp - 0x38]
mov r12d, edi
jmp 0x2d9e3b238f
mov eax, dword [rbp + 0x50]
mov dword [rsi], ebx
add rsi, 4
mov qword [rbp - 0x20], rsi
mov ebx, esi
test r14, r14
jne 0x2d9e3b2429
mov r13d, dword [rbp + 0x40]
test rdi, rdi
jne 0x2d9e3b23b2
mov ecx, r15d
jmp 0x2d9e3b23b7
mov ecx, ebx
sub ecx, r12d
lea edx, [rcx + r13]
cmp edx, eax
jb 0x2d9e3b240e
lea ecx, [rdx + 0x3ff]
mov eax, 0xfffffc00
and rcx, rax
call fcn.2d9e3da838
mov r14, rax
test rax, rax
je 0x2d9e3b240e
test rdi, rdi
jne 0x2d9e3b23e4
mov ebx, r15d
jmp 0x2d9e3b23ff
sub ebx, r12d
je 0x2d9e3b23f7
mov r8d, ebx
mov rdx, rdi
mov rcx, r14
call fcn.2d9e3e2bb0
mov rcx, rdi
call fcn.2d9e3da7f4
mov esi, ebx
mov rdi, r14
add rsi, r14
mov qword [rbp - 0x28], r14
mov r12d, r14d
mov rdx, qword [rbp + 0x38]
mov r8, r13
mov rcx, rsi
call fcn.2d9e3e2bb0
add rsi, r13
mov qword [rbp - 0x20], rsi
jmp 0x2d9e3b24b3
mov edx, dword [rbp + 0x40]
mov dword [rbp + 0x50], edx
test rdi, rdi
jne 0x2d9e3b2439
mov ecx, r15d
jmp 0x2d9e3b243e
mov ecx, ebx
sub ecx, r12d
add edx, ecx
cmp edx, eax
jb 0x2d9e3b2493
lea ecx, [rdx + 0x3ff]
mov eax, 0xfffffc00
and rcx, rax
call fcn.2d9e3da838
mov r13, rax
test rax, rax
je 0x2d9e3b2493
test rdi, rdi
jne 0x2d9e3b2469
mov ebx, r15d
jmp 0x2d9e3b2484
sub ebx, r12d
je 0x2d9e3b247c
mov r8d, ebx
mov rdx, rdi
mov rcx, r13
call fcn.2d9e3e2bb0
mov rcx, rdi
call fcn.2d9e3da7f4
mov esi, ebx
mov rdi, r13
add rsi, r13
mov qword [rbp - 0x28], r13
mov r12d, r13d
mov ebx, dword [rbp + 0x50]
mov rdx, r14
mov r8d, ebx
mov rcx, rsi
call fcn.2d9e3e2bb0
add rsi, rbx
mov rcx, r14
mov qword [rbp - 0x20], rsi
call fcn.2d9e3da7f4
mov rbx, qword [rbp + 0x30]
movzx eax, word [rbx + 0xa0]
cmp ax, 1
jne 0x2d9e3b24f8
test rdi, rdi
jne 0x2d9e3b24d1
mov r8d, r15d
mov rdx, r15
jmp 0x2d9e3b24db
mov r8d, dword [rbp - 0x20]
mov rdx, rdi
sub r8d, r12d
mov rcx, qword [rbx + 0x38]
xor r9d, r9d
mov rax, qword [rcx]
call qword [rax + 0x10]
test eax, eax
jne 0x2d9e3b253a
mov rcx, qword [rbx + 0x38]
mov rax, qword [rcx]
call qword [rax + 8]
jmp 0x2d9e3b2540
cmp ax, 2
jne 0x2d9e3b253a
test rdi, rdi
jne 0x2d9e3b250b
mov r8d, r15d
mov rdx, r15
jmp 0x2d9e3b2515
mov r8d, dword [rbp - 0x20]
mov rdx, rdi
sub r8d, r12d
mov rcx, qword [rbx + 0x40]
xor r9d, r9d
add rcx, 8
mov rax, qword [rcx]
call qword [rax + 0x10]
test eax, eax
jne 0x2d9e3b253a
mov rcx, qword [rbx + 0x40]
add rcx, 8
mov rax, qword [rcx]
call qword [rax + 8]
jmp 0x2d9e3b2540
mov r15d, 1
mov r12, qword [rsp + 0xb8]
test rdi, rdi
je 0x2d9e3b2555
mov rcx, rdi
call fcn.2d9e3da7f4
mov eax, r15d
jmp 0x2d9e3b255c
xor eax, eax
mov r14, qword [rsp + 0x68]
mov r15, qword [rsp + 0x60]
add rsp, 0x70
pop r13
pop rdi
pop rsi
pop rbx
pop rbp
ret