Function at 0x1001a300
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
mov ecx, dword [ebp + 0x24]
sub esp, 0x20
test ecx, ecx
je 0x1001a6b8
mov eax, dword [ebp + 0x20]
and dword [ebp + 0xc], 0xfffffffe
add eax, 0xfffffffc
and dword [ebp + 0x14], 0xfffffffe
and dword [ebp + 0x1c], 0xfffffffe
mov edx, dword [ebp + 0x10]
push esi
mov esi, dword [ebp + 0x18]
mov dword [ebp - 0xc], eax
mov eax, dword [ebp + 8]
push edi
dec ecx
mov dword [ebp + 0x24], ecx
xor ecx, ecx
cmp byte [0x101fd8ec], cl
mov edi, dword [ebp + 0x20]
mov dword [ebp - 0x10], edi
je 0x1001a44e
lea eax, [edi - 0x10]
mov dword [ebp - 0x14], eax
test eax, eax
js 0x1001a3ec
mov ecx, dword [ebp + 0x18]
lea eax, [edx + 0x10]
sub ecx, edx
mov dword [ebp - 8], esi
mov esi, dword [ebp + 8]
mov dword [ebp - 0x18], ecx
sub esi, edx
mov ecx, dword [ebp + 8]
sub ecx, dword [ebp + 0x18]
mov edi, dword [ebp - 0x18]
mov dword [ebp - 0x1c], ecx
mov ecx, dword [ebp - 0x14]
add ecx, 0x10
mov dword [ebp - 4], esi
mov esi, dword [ebp - 8]
mov edx, dword [ebp - 4]
shr ecx, 4
mov dword [ebp - 0x14], ecx
shl ecx, 4
mov dword [ebp - 0x20], ecx
mov ecx, dword [ebp - 0x1c]
dec dword [ebp - 0x14]
lea esi, [esi + 0x20]
movdqu xmm2, xmmword [ecx + esi - 0x20]
lea eax, [eax + 0x20]
movdqu xmm1, xmmword [eax - 0x30]
movdqu xmm4, xmmword [edx + eax - 0x20]
movdqu xmm3, xmmword [eax - 0x20]
movdqa xmm0, xmm2
psubusw xmm0, xmm1
psubusw xmm1, xmm2
paddw xmm0, xmm1
movdqu xmmword [esi - 0x20], xmm0
movdqa xmm0, xmm4
psubusw xmm0, xmm3
psubusw xmm3, xmm4
paddw xmm0, xmm3
movdqu xmmword [edi + eax - 0x20], xmm0
jne 0x1001a394
mov ecx, dword [ebp - 0x20]
mov edx, dword [ebp + 0x10]
mov edi, dword [ebp - 0x10]
mov esi, dword [ebp + 0x18]
cmp ecx, dword [ebp - 0xc]
jg 0x1001a514
mov esi, dword [ebp + 8]
lea eax, [edx + ecx*2]
sub esi, edx
mov edx, dword [ebp + 0x10]
mov dword [ebp - 0x20], esi
mov esi, dword [ebp + 0x18]
mov dword [ebp - 8], esi
sub dword [ebp - 8], edx
mov edx, dword [ebp - 0xc]
mov esi, dword [ebp - 0x20]
sub edx, ecx
mov edi, dword [ebp - 8]
shr edx, 2
inc edx
lea ecx, [ecx + edx*4]
mov edi, edi
movq xmm2, qword [eax + esi]
lea eax, [eax + 8]
movq xmm1, qword [eax - 8]
movdqa xmm0, xmm2
psubusw xmm0, xmm1
psubusw xmm1, xmm2
paddw xmm0, xmm1
movq qword [eax + edi - 8], xmm0
dec edx
jne 0x1001a420
mov esi, dword [ebp + 0x18]
jmp 0x1001a511
cmp dword [ebp - 0xc], ecx
jl 0x1001a514
lea edi, [edx + 4]
mov dword [ebp - 0x14], esi
sub dword [ebp - 0x14], eax
mov dword [ebp - 4], edi
lea edi, [eax + 2]
mov dword [ebp - 8], edi
mov edi, edx
sub edi, eax
mov eax, esi
sub eax, edx
mov dword [ebp - 0x18], edi
mov edx, dword [ebp - 4]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 8]
lea ecx, [ecx]
movzx edi, word [edi + eax]
movzx esi, word [eax]
movzx eax, word [eax - 2]
movzx edx, word [edx - 4]
sub eax, edx
cdq
xor eax, edx
sub eax, edx
mov edx, dword [ebp + 0x18]
mov word [edx + ecx*2], ax
mov eax, esi
mov esi, dword [ebp - 0x14]
sub eax, edi
cdq
xor eax, edx
sub eax, edx
mov edx, dword [ebp - 8]
mov word [esi + edx], ax
movzx esi, word [edx + 4]
mov eax, dword [ebp - 4]
movzx edi, word [eax + 2]
movzx eax, word [edx + 2]
mov edx, dword [ebp - 4]
mov dword [ebp - 0x1c], edi
mov edi, dword [ebp - 0x20]
movzx edx, word [edx]
sub eax, edx
cdq
xor eax, edx
sub eax, edx
mov edx, dword [ebp - 4]
mov word [edi + edx], ax
mov eax, esi
mov edi, dword [ebp - 0x1c]
mov esi, dword [ebp + 0x18]
movzx edx, di
mov edi, dword [ebp - 0x18]
sub eax, edx
cdq
xor eax, edx
sub eax, edx
mov edx, dword [ebp - 4]
mov word [esi + ecx*2 + 6], ax
add edx, 8
mov eax, dword [ebp - 8]
add ecx, 4
add eax, 8
mov dword [ebp - 4], edx
mov dword [ebp - 8], eax
cmp ecx, dword [ebp - 0xc]
jle 0x1001a480
mov edi, dword [ebp - 0x10]
mov eax, edi
sub eax, ecx
mov dword [ebp - 0x1c], eax
cmp ecx, edi
jge 0x1001a693
cmp eax, 8
jb 0x1001a64f
cmp dword [0x101fe438], 2
mov edx, dword [ebp + 0x10]
jl 0x1001a652
lea eax, [esi + ecx*2]
mov dword [ebp - 0x14], eax
lea eax, [edx + ecx*2]
mov dword [ebp - 8], eax
lea eax, [edx - 2]
lea eax, [eax + edi*2]
cmp dword [ebp - 0x14], eax
ja 0x1001a562
lea eax, [edi - 1]
lea eax, [esi + eax*2]
cmp eax, dword [ebp - 8]
jae 0x1001a652
mov eax, dword [ebp + 8]
lea edx, [eax + ecx*2]
lea eax, [eax + edi*2]
mov dword [ebp - 0x20], edx
mov edx, dword [ebp + 0x10]
add eax, 0xfffffffe
cmp dword [ebp - 0x14], eax
ja 0x1001a588
lea eax, [edi - 1]
lea eax, [esi + eax*2]
cmp eax, dword [ebp - 0x20]
jae 0x1001a652
mov eax, dword [ebp - 0x1c]
and eax, 0x80000007
jns 0x1001a597
dec eax
or eax, 0xfffffff8
inc eax
mov dword [ebp - 0x14], edi
mov edx, esi
sub dword [ebp - 0x14], eax
mov eax, dword [ebp + 8]
mov esi, dword [ebp + 0x10]
sub esi, dword [ebp + 8]
sub edx, dword [ebp + 8]
mov edi, dword [ebp + 0x18]
lea eax, [eax + ecx*2]
add eax, 8
mov dword [ebp - 0x20], esi
sub edi, dword [ebp + 0x10]
mov esi, dword [ebp - 8]
mov dword [ebp - 0x1c], edi
mov edi, dword [ebp - 0x20]
mov dword [ebp - 0x18], edx
jmp 0x1001a5d0
movq xmm0, qword [eax - 8]
lea esi, [esi + 0x10]
mov edx, dword [ebp - 0x1c]
lea eax, [eax + 0x10]
pmovzxwd xmm1, xmm0
movq xmm0, qword [esi - 0x10]
add ecx, 8
pmovzxwd xmm0, xmm0
psubd xmm1, xmm0
pabsd xmm0, xmm1
pshuflw xmm0, xmm0, 0xd8
pshufhw xmm0, xmm0, 0xd8
pshufd xmm0, xmm0, 0xd8
movq qword [edx + esi - 0x10], xmm0
movq xmm0, qword [eax - 0x10]
mov edx, dword [ebp - 0x18]
pmovzxwd xmm1, xmm0
movq xmm0, qword [eax + edi - 0x10]
pmovzxwd xmm0, xmm0
psubd xmm1, xmm0
pabsd xmm0, xmm1
pshuflw xmm0, xmm0, 0xd8
pshufhw xmm0, xmm0, 0xd8
pshufd xmm0, xmm0, 0xd8
movq qword [eax + edx - 0x10], xmm0
cmp ecx, dword [ebp - 0x14]
jl 0x1001a5d0
mov edi, dword [ebp - 0x10]
mov esi, dword [ebp + 0x18]
mov edx, dword [ebp + 0x10]
cmp ecx, edi
jge 0x1001a693
mov eax, dword [ebp + 8]
lea esi, [edx + ecx*2]
sub eax, edx
mov dword [ebp - 0x14], eax
mov eax, dword [ebp + 0x18]
sub eax, edx
sub edi, ecx
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x14]
mov edi, edi
movzx eax, word [esi + eax]
lea esi, [esi + 2]
movzx ecx, word [esi - 2]
sub eax, ecx
mov ecx, dword [ebp - 0x20]
cdq
xor eax, edx
sub eax, edx
mov word [esi + ecx - 2], ax
mov eax, dword [ebp - 0x14]
dec edi
jne 0x1001a670
mov esi, dword [ebp + 0x18]
mov eax, dword [ebp + 8]
mov edx, dword [ebp + 0x10]
add eax, dword [ebp + 0xc]
add edx, dword [ebp + 0x14]
add esi, dword [ebp + 0x1c]
mov ecx, dword [ebp + 0x24]
mov dword [ebp + 8], eax
mov dword [ebp + 0x10], edx
mov dword [ebp + 0x18], esi
test ecx, ecx
jne 0x1001a331
pop edi
pop esi
mov esp, ebp
pop ebp
ret