Function at 0x140001d10
Capabilities:
Encode data using xor

Disassembly:
sub rsp, 0x58
mov dword [rsp + 0x28], 0
mov dword [rsp + 0x20], 2
cmp dword [0x140035960], 0
je 0x1400020b3
mov eax, dword [0x14003594c]
shl eax, 5
mov ecx, dword [0x140035954]
add ecx, 2
mov ecx, ecx
mov rdx, qword [0x1400441a8]
movzx ecx, byte [rdx + rcx]
xor eax, ecx
and eax, 0x7fff
mov dword [0x14003594c], eax
mov eax, dword [0x14003594c]
mov rcx, qword [0x1400441a0]
movzx eax, word [rcx + rax*2 + 0x10000]
mov dword [rsp + 0x24], eax
mov eax, dword [0x140035954]
and eax, 0x7fff
mov eax, eax
mov rcx, qword [0x1400441a0]
movzx edx, word [rsp + 0x24]
mov word [rcx + rax*2], dx
mov eax, dword [0x14003594c]
mov rcx, qword [0x1400441a0]
movzx edx, word [0x140035954]
mov word [rcx + rax*2 + 0x10000], dx
mov eax, dword [rsp + 0x20]
mov dword [0x140035950], eax
mov eax, dword [0x140035958]
mov dword [rsp + 0x2c], eax
mov dword [rsp + 0x20], 2
cmp dword [rsp + 0x24], 0
je 0x140001e40
mov eax, dword [0x140035968]
cmp dword [0x140035950], eax
jae 0x140001e40
mov eax, dword [rsp + 0x24]
mov ecx, dword [0x140035954]
sub ecx, eax
mov eax, ecx
cmp eax, 0x7efa
ja 0x140001e40
mov ecx, dword [rsp + 0x24]
call fcn.140002470
mov dword [rsp + 0x20], eax
mov eax, dword [0x140035960]
cmp dword [rsp + 0x20], eax
jbe 0x140001e18
mov eax, dword [0x140035960]
mov dword [rsp + 0x20], eax
cmp dword [rsp + 0x20], 3
jne 0x140001e40
mov eax, dword [0x140035958]
mov ecx, dword [0x140035954]
sub ecx, eax
mov eax, ecx
cmp eax, 0x1000
jbe 0x140001e40
mov eax, dword [rsp + 0x20]
dec eax
mov dword [rsp + 0x20], eax
cmp dword [0x140035950], 3
jb 0x140001fcc
mov eax, dword [0x140035950]
cmp dword [rsp + 0x20], eax
ja 0x140001fcc
mov eax, dword [0x140035950]
sub eax, 3
mov ecx, dword [0x140035954]
dec ecx
sub ecx, dword [rsp + 0x2c]
mov edx, eax
call fcn.14002b100
mov dword [rsp + 0x30], eax
mov eax, dword [0x140035950]
dec eax
mov ecx, dword [0x140035960]
sub ecx, eax
mov eax, ecx
mov dword [0x140035960], eax
mov eax, dword [0x140035950]
sub eax, 2
mov dword [0x140035950], eax
mov eax, dword [0x140035954]
inc eax
mov dword [0x140035954], eax
mov eax, dword [0x14003594c]
shl eax, 5
mov ecx, dword [0x140035954]
add ecx, 2
mov ecx, ecx
mov rdx, qword [0x1400441a8]
movzx ecx, byte [rdx + rcx]
xor eax, ecx
and eax, 0x7fff
mov dword [0x14003594c], eax
mov eax, dword [0x14003594c]
mov rcx, qword [0x1400441a0]
movzx eax, word [rcx + rax*2 + 0x10000]
mov dword [rsp + 0x24], eax
mov eax, dword [0x140035954]
and eax, 0x7fff
mov eax, eax
mov rcx, qword [0x1400441a0]
movzx edx, word [rsp + 0x24]
mov word [rcx + rax*2], dx
mov eax, dword [0x14003594c]
mov rcx, qword [0x1400441a0]
movzx edx, word [0x140035954]
mov word [rcx + rax*2 + 0x10000], dx
mov eax, dword [0x140035950]
dec eax
mov dword [0x140035950], eax
cmp dword [0x140035950], 0
jne 0x140001ea4
mov dword [rsp + 0x28], 0
mov dword [rsp + 0x20], 2
mov eax, dword [0x140035954]
inc eax
mov dword [0x140035954], eax
cmp dword [rsp + 0x30], 0
je 0x140001fc7
cmp dword [0x140035948], 0
jl 0x140001f93
mov eax, dword [0x140035948]
mov rcx, qword [0x1400441a8]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x38], rax
jmp 0x140001f9c
mov qword [rsp + 0x38], 0
mov eax, dword [0x140035948]
mov ecx, dword [0x140035954]
sub ecx, eax
mov eax, ecx
xor r8d, r8d
mov edx, eax
mov rcx, qword [rsp + 0x38]
call fcn.14002b3a0
mov eax, dword [0x140035954]
mov dword [0x140035948], eax
jmp 0x140002092
cmp dword [rsp + 0x28], 0
je 0x14000206e
mov eax, dword [0x140035954]
dec eax
mov eax, eax
mov rcx, qword [0x1400441a8]
movzx eax, byte [rcx + rax]
mov edx, eax
xor ecx, ecx
call fcn.14002b100
test eax, eax
je 0x140002050
cmp dword [0x140035948], 0
jl 0x14000201c
mov eax, dword [0x140035948]
mov rcx, qword [0x1400441a8]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x40], rax
jmp 0x140002025
mov qword [rsp + 0x40], 0
mov eax, dword [0x140035948]
mov ecx, dword [0x140035954]
sub ecx, eax
mov eax, ecx
xor r8d, r8d
mov edx, eax
mov rcx, qword [rsp + 0x40]
call fcn.14002b3a0
mov eax, dword [0x140035954]
mov dword [0x140035948], eax
mov eax, dword [0x140035954]
inc eax
mov dword [0x140035954], eax
mov eax, dword [0x140035960]
dec eax
mov dword [0x140035960], eax
jmp 0x140002092
mov dword [rsp + 0x28], 1
mov eax, dword [0x140035954]
inc eax
mov dword [0x140035954], eax
mov eax, dword [0x140035960]
dec eax
mov dword [0x140035960], eax
cmp dword [0x140035960], 0x106
jae 0x1400020ae
cmp dword [0x14003595c], 0
jne 0x1400020ae
call fcn.140002130
jmp 0x140002092
jmp 0x140001d24
cmp dword [rsp + 0x28], 0
je 0x1400020d8
mov eax, dword [0x140035954]
dec eax
mov eax, eax
mov rcx, qword [0x1400441a8]
movzx eax, byte [rcx + rax]
mov edx, eax
xor ecx, ecx
call fcn.14002b100
cmp dword [0x140035948], 0
jl 0x1400020fb
mov eax, dword [0x140035948]
mov rcx, qword [0x1400441a8]
add rcx, rax
mov rax, rcx
mov qword [rsp + 0x48], rax
jmp 0x140002104
mov qword [rsp + 0x48], 0
mov eax, dword [0x140035948]
mov ecx, dword [0x140035954]
sub ecx, eax
mov eax, ecx
mov r8d, 1
mov edx, eax
mov rcx, qword [rsp + 0x48]
call fcn.14002b3a0
add rsp, 0x58
ret