Function at 0xa6be84a
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
test esi, esi
je 0xa6beda1
mov ebx, dword [ebp + 0x14]
test ebx, ebx
je 0xa6beda1
mov ecx, dword [ebp + 0xc]
cmp ecx, 0x10
je 0xa6be882
cmp ecx, 0x18
je 0xa6be882
cmp ecx, 0x20
je 0xa6be882
push 3
jmp 0xa6beda3
cmp dword [ebp + 0x10], 0
je 0xa6be8a6
mov eax, ecx
cdq
and edx, 7
add eax, edx
sar eax, 3
lea eax, [eax*2 + 6]
cmp dword [ebp + 0x10], eax
je 0xa6be8a6
push 4
jmp 0xa6beda3
mov eax, ecx
lea edi, [ebx + 0xf]
cdq
and edi, 0xfffffff0
and edx, 7
mov dword [ebx + 0x1f0], edi
add eax, edx
sar eax, 3
lea eax, [eax*2 + 6]
mov dword [ebx + 0x1f8], eax
lea eax, [edi + 0xf0]
mov dword [ebx + 0x1f4], eax
movzx edx, byte [esi]
movzx eax, byte [esi + 1]
shl edx, 8
or edx, eax
movzx eax, byte [esi + 2]
shl edx, 8
or edx, eax
movzx eax, byte [esi + 3]
shl edx, 8
or edx, eax
mov dword [edi], edx
movzx eax, byte [esi + 5]
mov dword [ebp + 8], edx
movzx edx, byte [esi + 4]
shl edx, 8
or edx, eax
movzx eax, byte [esi + 6]
shl edx, 8
or edx, eax
movzx eax, byte [esi + 7]
shl edx, 8
or edx, eax
mov dword [edi + 4], edx
movzx eax, byte [esi + 9]
mov dword [ebp - 4], edx
movzx edx, byte [esi + 8]
shl edx, 8
or edx, eax
movzx eax, byte [esi + 0xa]
shl edx, 8
or edx, eax
movzx eax, byte [esi + 0xb]
shl edx, 8
or edx, eax
mov dword [edi + 8], edx
movzx eax, byte [esi + 0xd]
mov dword [ebp - 8], edx
movzx edx, byte [esi + 0xc]
shl edx, 8
or edx, eax
movzx eax, byte [esi + 0xe]
shl edx, 8
or edx, eax
movzx eax, byte [esi + 0xf]
shl edx, 8
or edx, eax
mov dword [ebp - 0xc], edx
mov dword [edi + 0xc], edx
cmp ecx, 0x10
jne 0xa6be9e6
push edx
call fcn.0a6bf9d5
xor eax, dword [ebp + 8]
lea edx, [edi + 0x10]
xor eax, 0x1000000
mov dword [ebp + 8], 0xa5e143c
pop ecx
mov ecx, dword [ebp - 8]
mov dword [edx], eax
xor eax, dword [ebp - 4]
xor ecx, eax
mov dword [edi + 0x14], eax
mov eax, dword [ebp - 0xc]
xor eax, ecx
mov dword [edi + 0x18], ecx
push 4
mov dword [edi + 0x1c], eax
pop ebx
mov edi, dword [edx + 0xc]
mov esi, edx
add edx, 0x10
push edi
mov dword [ebp - 0xc], edx
call fcn.0a6bf9d5
xor eax, dword [esi]
mov edx, dword [ebp - 0xc]
mov esi, dword [ebp + 8]
pop ecx
xor eax, dword [esi]
add esi, ebx
mov dword [edx], eax
mov ecx, dword [edx - 0xc]
xor ecx, eax
mov dword [ebp + 8], esi
mov dword [edx + 4], ecx
mov eax, dword [edx - 8]
xor eax, ecx
mov dword [edx + 8], eax
xor eax, edi
mov dword [edx + 0xc], eax
cmp esi, 0xa5e1460
jne 0xa6be9a1
jmp 0xa6bec29
cmp ecx, 0x18
jne 0xa6beadb
movzx ecx, byte [esi + 0x10]
movzx eax, byte [esi + 0x11]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0x12]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0x13]
shl ecx, 8
or ecx, eax
mov dword [edi + 0x10], ecx
movzx ecx, byte [esi + 0x14]
movzx eax, byte [esi + 0x15]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0x16]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0x17]
shl ecx, 8
or ecx, eax
mov eax, edi
mov dword [edi + 0x14], ecx
mov ecx, dword [ebx + 0x1f0]
sub eax, ecx
sar eax, 2
push dword [ecx + eax*4 + 0x14]
call fcn.0a6bf9d5
xor eax, dword [ebp + 8]
xor eax, 0x1000000
mov dword [ebp + 8], 0xa5e143c
pop ecx
mov ecx, dword [ebp - 8]
mov dword [edi + 0x18], eax
xor eax, dword [ebp - 4]
xor ecx, eax
mov dword [edi + 0x1c], eax
mov eax, dword [ebp - 0xc]
xor eax, ecx
mov dword [edi + 0x20], ecx
push 4
mov dword [edi + 0x24], eax
add edi, 0x28
pop ebx
mov ecx, dword [edi - 0x18]
xor ecx, dword [edi - 4]
mov eax, dword [edi - 0x14]
xor eax, ecx
mov dword [edi], ecx
mov dword [edi + 4], eax
lea edi, [edi + 0x18]
mov eax, dword [ebp + 0x14]
mov ecx, dword [eax + 0x1f0]
lea eax, [edi - 0x28]
sub eax, ecx
sar eax, 2
push dword [ecx + eax*4 + 0x14]
call fcn.0a6bf9d5
xor eax, dword [edi - 0x28]
mov esi, dword [ebp + 8]
pop ecx
xor eax, dword [esi]
add esi, ebx
mov dword [edi - 0x10], eax
mov ecx, dword [edi - 0x24]
xor ecx, eax
mov dword [ebp + 8], esi
mov dword [edi - 0xc], ecx
mov edx, dword [edi - 0x20]
xor edx, ecx
mov dword [edi - 8], edx
mov eax, dword [edi - 0x1c]
xor eax, edx
mov dword [edi - 4], eax
cmp esi, 0xa5e1458
jne 0xa6bea78
jmp 0xa6bec29
cmp ecx, 0x20
jne 0xa6bed9c
movzx ecx, byte [esi + 0x10]
movzx eax, byte [esi + 0x11]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0x12]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0x13]
shl ecx, 8
or ecx, eax
mov dword [edi + 0x10], ecx
movzx ecx, byte [esi + 0x14]
movzx eax, byte [esi + 0x15]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0x16]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0x17]
shl ecx, 8
or ecx, eax
mov dword [edi + 0x14], ecx
movzx ecx, byte [esi + 0x18]
movzx eax, byte [esi + 0x19]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0x1a]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0x1b]
shl ecx, 8
or ecx, eax
mov dword [edi + 0x18], ecx
movzx ecx, byte [esi + 0x1c]
movzx eax, byte [esi + 0x1d]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0x1e]
shl ecx, 8
or ecx, eax
movzx eax, byte [esi + 0x1f]
shl ecx, 8
or ecx, eax
mov eax, edi
mov dword [edi + 0x1c], ecx
mov ecx, dword [ebx + 0x1f0]
sub eax, ecx
sar eax, 2
push dword [ecx + eax*4 + 0x1c]
call fcn.0a6bf9d5
xor eax, dword [ebp + 8]
xor eax, 0x1000000
mov dword [ebp + 8], 0xa5e143c
pop ecx
mov ecx, dword [ebp - 8]
mov dword [edi + 0x20], eax
xor eax, dword [ebp - 4]
xor ecx, eax
mov dword [edi + 0x24], eax
mov eax, dword [ebp - 0xc]
xor eax, ecx
mov dword [edi + 0x28], ecx
push 4
mov dword [edi + 0x2c], eax
add edi, 0x30
pop ebx
mov eax, dword [edi - 4]
ror eax, 8
push eax
call fcn.0a6bf9d5
xor eax, dword [edi - 0x20]
mov ecx, dword [edi - 0x1c]
mov edx, dword [edi - 0x18]
xor ecx, eax
mov dword [edi], eax
xor edx, ecx
mov eax, dword [edi - 0x14]
lea edi, [edi + 0x20]
xor eax, edx
mov dword [edi - 0x1c], ecx
mov dword [edi - 0x14], eax
mov eax, dword [ebp + 0x14]
mov dword [edi - 0x18], edx
mov ecx, dword [eax + 0x1f0]
lea eax, [edi - 0x30]
sub eax, ecx
sar eax, 2
push dword [ecx + eax*4 + 0x1c]
call fcn.0a6bf9d5
xor eax, dword [edi - 0x30]
mov esi, dword [ebp + 8]
pop ecx
pop ecx
xor eax, dword [esi]
add esi, ebx
mov dword [edi - 0x10], eax
mov ecx, dword [edi - 0x2c]
xor ecx, eax
mov dword [ebp + 8], esi
mov dword [edi - 0xc], ecx
mov edx, dword [edi - 0x28]
xor edx, ecx
mov dword [edi - 8], edx
mov eax, dword [edi - 0x24]
xor eax, edx
mov dword [edi - 4], eax
cmp esi, 0xa5e1454
jne 0xa6bebb1
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp + 0xc]
add ecx, 0x18
mov esi, dword [eax + 0x1f4]
mov edx, esi
mov eax, dword [eax + 0x1f0]
lea edi, [eax + ecx*4]
mov ecx, edi
mov eax, dword [ecx]
add ecx, ebx
mov dword [edx], eax
add edx, ebx
mov eax, dword [ecx]
mov dword [edx], eax
mov eax, dword [ecx + ebx]
mov dword [edx + ebx], eax
mov eax, dword [ecx + ebx + 4]
xor ecx, ecx
mov dword [edx + ebx + 4], eax
inc ecx
mov eax, dword [ebp + 0x14]
mov dword [ebp + 8], ecx
cmp dword [eax + 0x1f8], ecx
jle 0xa6bed78
mov ebx, eax
sub edi, 0x10
add esi, 0x10
mov edx, dword [edi]
mov eax, edx
shr eax, 0x10
movzx ecx, al
mov eax, edx
shr eax, 8
movzx eax, al
mov ecx, dword [ecx*4 + 0xa5e0838]
xor ecx, dword [eax*4 + 0xa5e0c38]
mov eax, edx
shr eax, 0x18
xor ecx, dword [eax*4 + 0xa5e0438]
movzx eax, dl
xor ecx, dword [eax*4 + 0xa5e1038]
mov dword [esi], ecx
mov edx, dword [edi + 4]
mov eax, edx
shr eax, 0x10
movzx ecx, al
mov eax, edx
shr eax, 8
movzx eax, al
mov ecx, dword [ecx*4 + 0xa5e0838]
xor ecx, dword [eax*4 + 0xa5e0c38]
mov eax, edx
shr eax, 0x18
xor ecx, dword [eax*4 + 0xa5e0438]
movzx eax, dl
xor ecx, dword [eax*4 + 0xa5e1038]
mov dword [esi + 4], ecx
mov edx, dword [edi + 8]
mov eax, edx
shr eax, 0x10
movzx ecx, al
mov eax, edx
shr eax, 8
movzx eax, al
mov ecx, dword [ecx*4 + 0xa5e0838]
xor ecx, dword [eax*4 + 0xa5e0c38]
mov eax, edx
shr eax, 0x18
xor ecx, dword [eax*4 + 0xa5e0438]
movzx eax, dl
xor ecx, dword [eax*4 + 0xa5e1038]
mov dword [esi + 8], ecx
mov edx, dword [edi + 0xc]
mov eax, edx
shr eax, 0x10
movzx ecx, al
mov eax, edx
shr eax, 8
movzx eax, al
mov ecx, dword [ecx*4 + 0xa5e0838]
xor ecx, dword [eax*4 + 0xa5e0c38]
mov eax, edx
shr eax, 0x18
xor ecx, dword [eax*4 + 0xa5e0438]
movzx eax, dl
xor ecx, dword [eax*4 + 0xa5e1038]
mov eax, dword [ebp + 8]
inc eax
mov dword [esi + 0xc], ecx
mov dword [ebp + 8], eax
cmp eax, dword [ebx + 0x1f8]
jl 0xa6bec76
push 4
pop ebx
sub edi, 0x10
add esi, 0x10
mov eax, dword [edi]
add edi, ebx
mov dword [esi], eax
add esi, ebx
mov eax, dword [edi]
mov dword [esi], eax
mov eax, dword [edi + ebx]
mov dword [esi + ebx], eax
mov eax, dword [edi + ebx + 4]
mov dword [esi + ebx + 4], eax
xor eax, eax
jmp 0xa6beda4
xor eax, eax
inc eax
jmp 0xa6beda4
push 0x10
pop eax
pop edi
pop esi
pop ebx
leave
ret