Function at 0x10105c80
Capabilities:
Encode data using xor

Disassembly:
sub esp, 0x3c
mov edx, dword [esp + 0x40]
xorps xmm0, xmm0
push ebx
push ebp
push esi
mov ebp, dword [edx]
xor ecx, ecx
push edi
mov edi, dword [edx + 0x14]
xor esi, esi
imul edi, dword [edx + 0x10]
movsd qword [esp + 0x34], xmm0
mov dword [esp + 0x14], 0
test edi, edi
je 0x10105d4d
cmp edi, 8
jb 0x10105d1b
cmp dword [0x10594d40], 2
jl 0x10105d1b
mov eax, dword [edx + 8]
mov ecx, edi
and ecx, 0xfffffff8
xorps xmm1, xmm1
xorps xmm2, xmm2
nop dword [eax]
movups xmm0, xmmword [eax + esi*4]
pabsd xmm0, xmm0
pmaxsd xmm1, xmm0
movups xmm0, xmmword [eax + esi*4 + 0x10]
add esi, 8
pabsd xmm0, xmm0
pmaxsd xmm2, xmm0
cmp esi, ecx
jb 0x10105cd0
pmaxsd xmm1, xmm2
movaps xmm0, xmm1
psrldq xmm0, 8
pmaxsd xmm1, xmm0
movups xmm0, xmm1
psrldq xmm0, 4
pmaxsd xmm1, xmm0
movd ecx, xmm1
cmp esi, edi
jae 0x10105d34
mov ebx, dword [edx + 8]
nop
mov eax, dword [ebx + esi*4]
cdq
xor eax, edx
sub eax, edx
cmp ecx, eax
cmovg eax, ecx
inc esi
mov ecx, eax
cmp esi, edi
jb 0x10105d20
test ecx, ecx
je 0x10105d4d
xor eax, eax
cmp ecx, 1
jle 0x10105d48
nop
shr ecx, 1
inc eax
cmp ecx, 1
ja 0x10105d40
lea esi, [eax - 5]
jmp 0x10105d4f
xor esi, esi
mov ebx, dword [esp + 0x54]
push ebp
mov dword [esp + 0x14], 2
mov dword [ebx + 0x1c], esi
call fcn.10107a20
push 0x2e
push 0
push 0x12
push ebp
call fcn.10107ab0
push 3
push 0
push 0x11
push ebp
call fcn.10107ab0
push 4
push 0
push 0
push ebp
call fcn.10107ab0
push dword [ebx]
push ebp
call fcn.10107ae0
mov edx, dword [esp + 0xac]
xor edi, edi
add esp, 0x3c
mov dword [esp + 0x24], edi
add esi, 0xffffffff
js 0x1010600b
mov ecx, esi
mov eax, 1
rol eax, cl
mov ecx, dword [esp + 0x58]
mov dword [esp + 0x18], eax
mov eax, edx
and eax, 4
mov dword [esp + 0x2c], eax
mov eax, edx
and eax, 2
mov dword [esp + 0x30], eax
xor eax, eax
mov dword [esp + 0x28], eax
mov edi, dword [ebx + 8]
add edi, eax
mov dword [esp + 0x20], 3
mov eax, dword [ebx + 0x1c]
sub eax, 4
cmp esi, eax
mov eax, dword [esp + 0x10]
jge 0x10105dfc
cmp eax, 2
jae 0x10105dfc
mov byte [esp + 0x1c], 1
test dl, 1
jne 0x10105e01
mov byte [esp + 0x1c], 0
sub eax, 0
je 0x10105e4f
sub eax, 1
je 0x10105e36
sub eax, 1
jne 0x10105e6b
push edx
lea eax, [esp + 0x18]
push eax
push ecx
push esi
push dword [esp + 0x60]
call fcn.10105440
add esp, 0x14
test byte [esp + 0x70], 0x20
je 0x10105e67
push ebp
call fcn.10107f10
add esp, 4
jmp 0x10105e67
push edx
push dword [esp + 0x20]
lea eax, [esp + 0x1c]
push eax
push esi
push dword [esp + 0x60]
call fcn.10105830
add esp, 0x14
jmp 0x10105e67
push edx
push dword [esp + 0x20]
lea eax, [esp + 0x1c]
push eax
push ecx
push esi
push dword [esp + 0x64]
call fcn.10105a00
add esp, 0x18
mov ecx, dword [esp + 0x58]
movsd xmm0, qword [0x103efa68]
mov eax, dword [esp + 0x7c]
movsd qword [esp + 0x44], xmm0
test eax, eax
je 0x10105e90
mov edx, dword [esp + 0x5c]
movsd xmm0, qword [eax + edx*8]
movsd qword [esp + 0x44], xmm0
cmp dword [esp + 0x64], 1
push ecx
push dword [esp + 0x64]
jne 0x10105ea3
call fcn.10100900
jmp 0x10105ea8
call fcn.10100f20
mov edx, dword [esp + 0x20]
xorps xmm0, xmm0
fstp qword [esp + 0x44]
movsd xmm1, qword [esp + 0x44]
xorps xmm2, xmm2
mulsd xmm1, qword [esp + 0x4c]
add esp, 8
cmp dword [esp + 0x2c], 0
cvtsi2sd xmm2, dword [esp + 0x14]
mov eax, dword [esp + 0x78]
mov ecx, dword [esp + 0x10]
mulsd xmm1, qword [esp + 0x68]
cvtsi2sd xmm0, edx
mulsd xmm1, xmm0
mulsd xmm2, xmm1
mulsd xmm2, qword [0x102aadb0]
mulsd xmm2, xmm1
movaps xmm0, xmm2
addsd xmm0, qword [esp + 0x34]
addsd xmm2, qword [eax + 0x20]
movsd qword [esp + 0x34], xmm0
movsd qword [eax + 0x20], xmm2
je 0x10105f35
cmp ecx, 2
jne 0x10105f1a
test esi, esi
jle 0x10105f35
push ebp
call fcn.10107bc0
mov edx, dword [esp + 0x1c]
add esp, 4
or dword [edi + 0x14], 1
mov dword [esp + 0x20], 1
jmp 0x10105f47
mov eax, dword [ebx + 0x1c]
add eax, 0xfffffffc
cmp esi, eax
jge 0x10105f8b
test ecx, ecx
jne 0x10105f92
and dword [edi + 0x14], 0xfffffffe
mov ecx, dword [esp + 0x10]
mov eax, dword [edi + 0x14]
inc ecx
mov dword [esp + 0x10], ecx
cmp ecx, 3
jne 0x10105f65
xor ecx, ecx
dec esi
ror edx, 1
mov dword [esp + 0x10], ecx
mov dword [esp + 0x18], edx
test al, 1
je 0x10105fbd
test esi, esi
jle 0x10105fbd
mov eax, dword [ebx + 0x1c]
sub eax, 4
cmp esi, eax
jge 0x10105fb4
cmp ecx, 2
jae 0x10105fb4
test byte [esp + 0x70], 1
je 0x10105fb4
push ebp
call fcn.10107c10
jmp 0x10105fba
jne 0x10105f43
cmp ecx, 2
jne 0x10105f43
test byte [esp + 0x70], 1
je 0x10105f43
push ebp
call fcn.10107bc0
mov edx, dword [esp + 0x1c]
add esp, 4
or dword [edi + 0x14], 1
mov dword [esp + 0x20], 1
jmp 0x10105f47
push ebp
call fcn.10107e10
add esp, 4
movsd xmm0, qword [esp + 0x34]
push ebp
movsd qword [edi + 8], xmm0
call fcn.10107a10
add eax, dword [esp + 0x24]
add esp, 4
cmp dword [esp + 0x30], 0
mov dword [edi], eax
je 0x10105fe7
push ebp
call fcn.10107cc0
add esp, 4
mov edi, dword [esp + 0x24]
mov eax, dword [esp + 0x28]
inc edi
mov edx, dword [esp + 0x70]
add eax, 0x18
mov ecx, dword [esp + 0x58]
mov dword [esp + 0x24], edi
mov dword [esp + 0x28], eax
test esi, esi
jns 0x10105dd2
test dl, 0x10
je 0x10106018
push ebp
call fcn.10107e50
jmp 0x10106023
test dl, 1
jne 0x10106026
push ebp
call fcn.10107bc0
add esp, 4
mov dword [ebx + 0x2c], edi
xor edi, edi
cmp dword [esp + 0x24], edi
jbe 0x10106093
mov eax, ebx
mov esi, dword [eax + 8]
lea ebx, [edi + edi*2]
shl ebx, 3
push ebp
add esi, ebx
call fcn.10107a10
add esp, 4
cmp dword [esi], eax
jbe 0x10106056
push ebp
call fcn.10107a10
add esp, 4
mov dword [esi], eax
mov edx, dword [esi]
mov ecx, edx
cmp edx, 1
jbe 0x10106071
mov eax, dword [esp + 0x54]
mov eax, dword [eax]
cmp byte [edx + eax - 1], 0xff
jne 0x10106071
lea ecx, [edx - 1]
mov dword [esi], ecx
test edi, edi
jne 0x10106079
xor eax, eax
jmp 0x10106084
mov eax, dword [esp + 0x54]
mov eax, dword [eax + 8]
mov eax, dword [ebx + eax - 0x18]
sub ecx, eax
inc edi
mov eax, dword [esp + 0x54]
mov dword [esi + 0x10], ecx
cmp edi, dword [eax + 0x2c]
jb 0x10106033
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x3c
ret