Function at 0x10154060
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x10
push ebx
mov ebx, dword [ebp + 0x10]
xor ecx, ecx
push esi
push edi
xor edi, edi
lea eax, [ebx - 4]
mov dword [ebp - 4], edi
mov dword [ebp - 0xc], eax
test eax, eax
js 0x1015410e
mov eax, dword [ebp + 0xc]
mov edx, dword [ebp + 8]
mov esi, edx
sub esi, eax
mov dword [ebp - 8], esi
lea ebx, [eax + 3]
lea eax, [edx + 1]
mov dword [ebp - 4], eax
jmp 0x101540a0
movsx edx, byte [eax + ecx - 1]
lea ebx, [ebx + 4]
movsx eax, byte [ebx - 7]
sub edx, eax
mov eax, edx
cdq
mov esi, eax
mov eax, dword [ebp - 4]
xor esi, edx
sub esi, edx
movsx edx, byte [eax + ecx + 1]
movsx eax, byte [ebx - 5]
sub edx, eax
mov eax, edx
cdq
xor eax, edx
sub eax, edx
add esi, eax
mov eax, dword [ebp - 4]
movsx edx, byte [eax + ecx]
add ecx, 4
movsx eax, byte [ebx - 6]
sub edx, eax
mov eax, edx
cdq
xor eax, edx
sub eax, edx
add esi, eax
mov eax, dword [ebp - 8]
movsx edx, byte [eax + ebx - 4]
movsx eax, byte [ebx - 4]
sub edx, eax
mov eax, edx
cdq
xor eax, edx
sub eax, edx
add edi, eax
mov eax, dword [ebp - 4]
add edi, esi
cmp ecx, dword [ebp - 0xc]
jle 0x101540a0
mov ebx, dword [ebp + 0x10]
mov dword [ebp - 4], edi
mov eax, ebx
sub eax, ecx
cmp ecx, ebx
jge 0x101541e6
cmp eax, 8
jb 0x101541e6
cmp dword [0x101fe438], 2
jl 0x101541e6
and eax, 0x80000007
jns 0x1015413c
dec eax
or eax, 0xfffffff8
inc eax
mov esi, dword [ebp + 8]
mov edx, ebx
sub edx, eax
mov edi, esi
mov dword [ebp - 0xc], edx
xorps xmm3, xmm3
mov edx, dword [ebp + 0xc]
movdqa xmm2, xmm3
sub edi, edx
mov dword [ebp - 8], edi
mov edi, dword [ebp - 4]
lea eax, [ecx + edx]
lea edx, [esi + 4]
mov esi, dword [ebp - 0xc]
mov dword [ebp - 0x10], edx
mov edx, dword [ebp - 8]
mov ebx, dword [ebp - 0x10]
lea esp, [esp]
movd xmm0, dword [eax + edx]
lea eax, [eax + 8]
pmovsxbd xmm1, xmm0
movd xmm0, dword [eax - 8]
pmovsxbd xmm0, xmm0
psubd xmm1, xmm0
pabsd xmm0, xmm1
paddd xmm3, xmm0
movd xmm0, dword [ebx + ecx]
pmovsxbd xmm1, xmm0
movd xmm0, dword [eax - 4]
add ecx, 8
pmovsxbd xmm0, xmm0
psubd xmm1, xmm0
pabsd xmm0, xmm1
paddd xmm2, xmm0
cmp ecx, esi
jl 0x10154170
mov ebx, dword [ebp + 0x10]
paddd xmm2, xmm3
movdqa xmm0, xmm2
psrldq xmm0, 8
paddd xmm2, xmm0
movdqa xmm0, xmm2
psrldq xmm0, 4
paddd xmm2, xmm0
movd eax, xmm2
add edi, eax
mov dword [ebp - 4], edi
mov edx, dword [ebp + 0xc]
xor esi, esi
mov dword [ebp - 8], esi
cmp ecx, ebx
jge 0x10154292
mov eax, ebx
sub eax, ecx
cmp eax, 2
jl 0x10154267
lea eax, [ebx - 1]
mov dword [ebp - 8], eax
lea esi, [ecx + edx]
mov eax, dword [ebp + 8]
mov ebx, eax
sub ebx, edx
inc eax
mov dword [ebp - 0x10], ebx
xor ebx, ebx
mov dword [ebp - 0xc], eax
xor edi, edi
lea ebx, [ebx]
mov eax, dword [ebp - 0x10]
lea esi, [esi + 2]
movsx edx, byte [esi + eax - 2]
movsx eax, byte [esi - 2]
sub edx, eax
mov eax, edx
cdq
xor eax, edx
sub eax, edx
add ebx, eax
mov eax, dword [ebp - 0xc]
movsx edx, byte [eax + ecx]
add ecx, 2
movsx eax, byte [esi - 1]
sub edx, eax
mov eax, edx
cdq
xor eax, edx
sub eax, edx
add edi, eax
cmp ecx, dword [ebp - 8]
jl 0x10154220
mov dword [ebp - 0x10], ebx
mov ebx, dword [ebp + 0x10]
mov esi, dword [ebp - 0x10]
mov dword [ebp - 8], edi
mov edi, dword [ebp - 4]
cmp ecx, ebx
jge 0x10154284
mov eax, dword [ebp + 8]
movsx edx, byte [ecx + eax]
mov eax, dword [ebp + 0xc]
movsx eax, byte [ecx + eax]
sub edx, eax
mov eax, edx
cdq
xor eax, edx
sub eax, edx
add edi, eax
mov eax, dword [ebp - 8]
add eax, esi
add eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret