Function at 0x48a5a0
Capabilities:
Encode data using xor

Disassembly:
push ebp
mov ebp, esp
and esp, 0xfffffff0
sub esp, 0x98
mov eax, dword [ebp + 0x10]
mov edx, ecx
or eax, dword [ebp + 0x14]
mov dword [esp + 0x10], edx
push esi
push edi
test al, 0xf
jne 0x48a82d
cmp dword [0x5781c4], 3
jl 0x48a82d
mov ecx, dword [edx + 0xc]
imul ecx, dword [ebp + 0xc]
mov eax, dword [edx + 0x1c]
mov esi, dword [edx + 4]
mov edi, dword [edx]
mov dword [esp + 0xc], esi
add ecx, dword [ebp + 8]
mov ecx, dword [eax + ecx*4]
xor eax, eax
lea esi, [ecx*4]
mov ecx, dword [edx + 4]
mov dword [esp + 0x1c], esi
mov dword [esp + 8], ecx
mov dword [esp + 0x14], ecx
mov esi, dword [esi + ecx]
mov dword [esp + 0x10], ecx
mov ecx, dword [ecx + eax*4]
add ecx, esi
lea edx, [edi + ecx*4]
movzx ecx, byte [edx]
mov byte [esp + eax + 0x30], cl
mov ecx, dword [edx]
shr ecx, 8
mov byte [esp + eax + 0x70], cl
mov ecx, dword [esp + 0x10]
add dword [esp + 0x10], 0x40
mov ecx, dword [ecx]
add ecx, esi
lea edx, [edi + ecx*4]
movzx ecx, byte [edx]
mov byte [esp + eax + 0x20], cl
mov ecx, dword [edx]
shr ecx, 8
mov byte [esp + eax + 0x60], cl
mov ecx, dword [esp + 0x14]
add dword [esp + 0x14], 0x400
mov ecx, dword [ecx]
add ecx, esi
lea edx, [edi + ecx*4]
movzx ecx, byte [edx]
mov byte [esp + eax + 0x40], cl
mov ecx, dword [edx]
shr ecx, 8
mov byte [esp + eax + 0x80], cl
mov ecx, dword [esp + 8]
add dword [esp + 8], 0x4000
mov ecx, dword [ecx]
add ecx, esi
lea edx, [edi + ecx*4]
movzx ecx, byte [edx]
mov byte [esp + eax + 0x50], cl
mov ecx, dword [edx]
shr ecx, 8
mov byte [esp + eax + 0x90], cl
inc eax
mov ecx, dword [esp + 0xc]
cmp eax, 0x10
jb 0x48a607
movaps xmm4, xmmword [0x50fe30]
xor eax, eax
mov edi, dword [ebp + 0x18]
movaps xmm7, xmm4
movaps xmm2, xmmword [0x50fe20]
mov ecx, dword [ebp + 0x14]
mov edx, dword [ebp + 0x10]
psllw xmm7, 4
cmp edi, 0x20
jb 0x48a7e2
mov eax, edx
mov dword [esp + 8], 0x10
sub dword [esp + 8], ecx
lea esi, [ecx + 0x10]
sub eax, ecx
xor ecx, ecx
mov dword [esp + 0xc], eax
lea esp, [esp]
movaps xmm1, xmmword [eax + esi]
movaps xmm5, xmmword [ecx + edx]
movaps xmm0, xmm1
psrlw xmm0, 8
pand xmm1, xmm2
movaps xmm6, xmm5
mov eax, dword [esp + 8]
pand xmm5, xmm2
psrlw xmm6, 8
packuswb xmm5, xmm1
add ecx, 0x20
packuswb xmm6, xmm0
movaps xmm3, xmm5
movaps xmm0, xmmword [esp + 0x30]
pand xmm3, xmm4
pshufb xmm0, xmm3
movaps xmm1, xmmword [esp + 0x60]
movaps xmm2, xmm6
pand xmm2, xmm4
pand xmm5, xmm7
movaps xmm4, xmmword [esp + 0x20]
pand xmm6, xmm7
psrlw xmm5, 4
psrlw xmm6, 4
pshufb xmm4, xmm5
pshufb xmm1, xmm5
pxor xmm4, xmm0
movaps xmm0, xmmword [esp + 0x40]
pshufb xmm0, xmm2
pxor xmm4, xmm0
movaps xmm0, xmmword [esp + 0x50]
pshufb xmm0, xmm6
pxor xmm4, xmm0
movaps xmm0, xmmword [esp + 0x70]
pshufb xmm0, xmm3
pxor xmm1, xmm0
movaps xmm0, xmmword [esp + 0x80]
pshufb xmm0, xmm2
movaps xmm2, xmmword [0x50fe20]
pxor xmm1, xmm0
movaps xmm0, xmmword [esp + 0x90]
pshufb xmm0, xmm6
pxor xmm1, xmm0
movaps xmm0, xmm4
punpckhbw xmm4, xmm1
pxor xmm4, xmmword [esi]
punpcklbw xmm0, xmm1
pxor xmm0, xmmword [esi - 0x10]
movaps xmmword [esi], xmm4
movaps xmm4, xmmword [0x50fe30]
movaps xmmword [esi - 0x10], xmm0
add esi, 0x20
add eax, esi
cmp eax, edi
mov eax, dword [esp + 0xc]
jbe 0x48a6e0
mov dword [esp + 0xc], ecx
mov ecx, dword [ebp + 0x14]
mov eax, dword [esp + 0xc]
cmp eax, edi
jae 0x48a823
sub edi, eax
lea esi, [eax + ecx]
dec edi
sub edx, ecx
shr edi, 1
mov dword [ebp + 0x10], edx
inc edi
mov ecx, dword [esp + 0x18]
lea esi, [esi + 2]
movzx eax, word [esi + edx - 2]
mov ecx, dword [ecx + 4]
mov edx, dword [ecx + eax*4]
mov eax, dword [esp + 0x1c]
add edx, dword [ecx + eax]
mov eax, dword [esp + 0x18]
mov eax, dword [eax]
mov ax, word [eax + edx*4]
xor word [esi - 2], ax
mov edx, dword [ebp + 0x10]
sub edi, 1
jne 0x48a7f4
mov al, 1
pop edi
pop esi
mov esp, ebp
pop ebp
ret 0x14
pop edi
xor al, al
pop esi
mov esp, ebp
pop ebp
ret 0x14