Function at 0x4a5d10
Capabilities:
Encode data using xor

Disassembly:
mov eax, 0x14
call fcn.004e2da0
cmp dword [esp + 0x2c], 0
push ebx
push ebp
push esi
push edi
je 0x4a5f55
mov ebx, dword [esp + 0x38]
movzx eax, byte [ebx + 1]
movzx ecx, byte [ebx]
movzx edx, byte [ebx + 2]
shl eax, 8
or ecx, eax
movzx eax, byte [ebx + 3]
shl edx, 0x10
or ecx, edx
movzx edx, byte [ebx + 5]
mov esi, dword [esp + 0x2c]
mov edi, dword [esp + 0x28]
shl eax, 0x18
or ecx, eax
movzx eax, byte [ebx + 4]
shl edx, 8
or eax, edx
movzx edx, byte [ebx + 6]
shl edx, 0x10
or eax, edx
movzx edx, byte [ebx + 7]
shl edx, 0x18
or eax, edx
mov edx, dword [esp + 0x30]
add edx, 0xfffffff8
mov dword [esp + 0x3c], eax
js 0x4a5e54
lea eax, [edx + 8]
shr eax, 3
mov dword [esp + 0x14], eax
neg eax
lea eax, [edx + eax*8]
mov dword [esp + 0x30], eax
jmp 0x4a5da0
movzx edx, byte [edi + 1]
movzx eax, byte [edi]
movzx ebp, byte [edi + 4]
shl edx, 8
or eax, edx
movzx edx, byte [edi + 2]
shl edx, 0x10
or eax, edx
movzx edx, byte [edi + 3]
shl edx, 0x18
or eax, edx
movzx edx, byte [edi + 5]
shl edx, 8
or ebp, edx
movzx edx, byte [edi + 6]
shl edx, 0x10
or ebp, edx
movzx edx, byte [edi + 7]
xor eax, ecx
shl edx, 0x18
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x34]
or ebp, edx
xor ebp, dword [esp + 0x3c]
push eax
lea ecx, [esp + 0x20]
push ecx
add edi, 8
mov dword [esp + 0x28], ebp
call fcn.004a5a90
mov eax, dword [esp + 0x24]
mov byte [esi], al
mov edx, eax
shr edx, 8
mov byte [esi + 1], dl
mov edx, eax
shr edx, 0x10
mov byte [esi + 2], dl
mov ecx, eax
shr eax, 0x18
mov byte [esi + 3], al
mov eax, dword [esp + 0x28]
mov byte [esi + 4], al
mov edx, eax
shr edx, 8
mov byte [esi + 5], dl
mov edx, eax
shr edx, 0x10
mov dword [esp + 0x44], eax
shr eax, 0x18
mov byte [esi + 6], dl
mov byte [esi + 7], al
add esp, 8
add esi, 8
dec dword [esp + 0x14]
jne 0x4a5da0
mov edx, dword [esp + 0x30]
mov eax, dword [esp + 0x3c]
cmp edx, 0xfffffff8
je 0x4a5f1c
lea edi, [edi + edx + 8]
add edx, 7
xor ebp, ebp
xor eax, eax
cmp edx, 7
ja case.default.0x4a5e6d
jmp dword [edx*4 + 0x4a6198]
movzx ebp, byte [edi - 1]
dec edi
shl ebp, 0x18
movzx eax, byte [edi - 1]
dec edi
shl eax, 0x10
or ebp, eax
movzx edx, byte [edi - 1]
dec edi
shl edx, 8
or ebp, edx
movzx eax, byte [edi - 1]
dec edi
or ebp, eax
movzx eax, byte [edi - 1]
dec edi
shl eax, 0x18
movzx edx, byte [edi - 1]
dec edi
shl edx, 0x10
or eax, edx
movzx edx, byte [edi - 1]
dec edi
shl edx, 8
or eax, edx
movzx edx, byte [edi - 1]
or eax, edx
xor ebp, dword [esp + 0x3c]
xor eax, ecx
mov dword [esp + 0x1c], eax
mov eax, dword [esp + 0x34]
push eax
lea ecx, [esp + 0x20]
push ecx
mov dword [esp + 0x28], ebp
call fcn.004a5a90
mov eax, dword [esp + 0x24]
mov byte [esi], al
mov edx, eax
shr edx, 8
mov byte [esi + 1], dl
mov edx, eax
shr edx, 0x10
mov byte [esi + 2], dl
mov ecx, eax
shr eax, 0x18
mov byte [esi + 3], al
mov eax, dword [esp + 0x28]
mov edx, eax
mov byte [esi + 4], al
shr edx, 8
mov byte [esi + 5], dl
mov edx, eax
mov dword [esp + 0x44], eax
shr edx, 0x10
add esp, 8
shr eax, 0x18
mov byte [esi + 6], dl
mov byte [esi + 7], al
mov eax, dword [esp + 0x3c]
mov byte [ebx], cl
mov edx, ecx
shr edx, 8
mov byte [ebx + 1], dl
mov edx, ecx
shr edx, 0x10
mov byte [ebx + 2], dl
shr ecx, 0x18
mov byte [ebx + 3], cl
mov byte [ebx + 4], al
mov ecx, eax
pop edi
mov edx, eax
shr ecx, 8
mov byte [ebx + 5], cl
shr edx, 0x10
pop esi
mov byte [ebx + 6], dl
shr eax, 0x18
pop ebp
mov byte [ebx + 7], al
pop ebx
add esp, 0x14
ret
mov ebp, dword [esp + 0x38]
movzx eax, byte [ebp + 1]
movzx ebx, byte [ebp]
movzx ecx, byte [ebp + 2]
movzx edx, byte [ebp + 3]
mov edi, dword [esp + 0x2c]
mov esi, dword [esp + 0x28]
shl eax, 8
or ebx, eax
movzx eax, byte [ebp + 4]
shl ecx, 0x10
or ebx, ecx
movzx ecx, byte [ebp + 5]
shl edx, 0x18
shl ecx, 8
or eax, ecx
movzx ecx, byte [ebp + 7]
or ebx, edx
movzx edx, byte [ebp + 6]
shl edx, 0x10
shl ecx, 0x18
or eax, edx
or eax, ecx
mov ecx, dword [esp + 0x30]
add ecx, 0xfffffff8
mov dword [esp + 0x3c], eax
mov dword [esp + 0x30], ecx
js 0x4a608e
lea eax, [ecx + 8]
shr eax, 3
mov dword [esp + 0x18], eax
neg eax
lea edx, [ecx + eax*8]
mov dword [esp + 0x30], edx
jmp 0x4a5fd0
movzx ecx, byte [esi + 1]
movzx eax, byte [esi]
movzx edx, byte [esi + 2]
shl ecx, 8
or eax, ecx
movzx ecx, byte [esi + 3]
shl edx, 0x10
or eax, edx
movzx edx, byte [esi + 5]
shl ecx, 0x18
or eax, ecx
movzx ecx, byte [esi + 6]
mov dword [esp + 0x10], eax
mov dword [esp + 0x1c], eax
movzx eax, byte [esi + 4]
shl edx, 8
or eax, edx
movzx edx, byte [esi + 7]
shl ecx, 0x10
or eax, ecx
shl edx, 0x18
or eax, edx
mov dword [esp + 0x14], eax
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x34]
push eax
lea ecx, [esp + 0x20]
push ecx
add esi, 8
call fcn.004a5bc0
mov ecx, dword [esp + 0x44]
xor ecx, dword [esp + 0x28]
mov eax, ebx
xor eax, dword [esp + 0x24]
mov ebx, dword [esp + 0x18]
mov byte [edi], al
mov edx, eax
shr edx, 8
mov byte [edi + 1], dl
mov edx, eax
shr edx, 0x10
mov byte [edi + 2], dl
shr eax, 0x18
mov byte [edi + 3], al
mov byte [edi + 4], cl
mov eax, ecx
shr eax, 8
mov edx, ecx
mov byte [edi + 5], al
mov eax, dword [esp + 0x1c]
shr edx, 0x10
shr ecx, 0x18
mov byte [edi + 6], dl
mov byte [edi + 7], cl
add esp, 8
add edi, 8
dec dword [esp + 0x18]
mov dword [esp + 0x3c], eax
jne 0x4a5fd0
mov ecx, dword [esp + 0x30]
cmp ecx, 0xfffffff8
je 0x4a615b
movzx ecx, byte [esi + 1]
movzx eax, byte [esi]
movzx edx, byte [esi + 2]
shl ecx, 8
or eax, ecx
movzx ecx, byte [esi + 3]
shl edx, 0x10
or eax, edx
movzx edx, byte [esi + 5]
shl ecx, 0x18
or eax, ecx
movzx ecx, byte [esi + 7]
mov dword [esp + 0x10], eax
mov dword [esp + 0x1c], eax
movzx eax, byte [esi + 4]
shl edx, 8
or eax, edx
movzx edx, byte [esi + 6]
shl ecx, 8
or ecx, edx
shl ecx, 0x10
or eax, ecx
mov dword [esp + 0x14], eax
mov dword [esp + 0x20], eax
mov eax, dword [esp + 0x34]
push eax
lea ecx, [esp + 0x20]
push ecx
call fcn.004a5bc0
mov ecx, dword [esp + 0x38]
mov eax, dword [esp + 0x44]
xor ebx, dword [esp + 0x24]
xor eax, dword [esp + 0x28]
lea edi, [edi + ecx + 8]
add ecx, 7
add esp, 8
cmp ecx, 7
ja case.default.0x4a6112
jmp dword [ecx*4 + 0x4a61b8]
dec edi
mov edx, eax
shr edx, 0x18
mov byte [edi], dl
dec edi
mov ecx, eax
shr ecx, 0x10
mov byte [edi], cl
dec edi
mov edx, eax
shr edx, 8
mov byte [edi], dl
dec edi
mov byte [edi], al
dec edi
mov eax, ebx
shr eax, 0x18
mov byte [edi], al
dec edi
mov ecx, ebx
shr ecx, 0x10
mov byte [edi], cl
dec edi
mov edx, ebx
shr edx, 8
mov byte [edi], dl
mov byte [edi - 1], bl
mov eax, dword [esp + 0x14]
mov ebx, dword [esp + 0x10]
mov dword [esp + 0x3c], eax
mov byte [ebp], bl
mov ecx, ebx
shr ecx, 8
mov byte [ebp + 1], cl
mov edx, ebx
shr edx, 0x10
mov byte [ebp + 2], dl
shr ebx, 0x18
mov byte [ebp + 3], bl
mov byte [ebp + 4], al
mov ecx, eax
mov edx, eax
shr ecx, 8
pop edi
mov byte [ebp + 5], cl
shr edx, 0x10
mov byte [ebp + 6], dl
shr eax, 0x18
pop esi
mov byte [ebp + 7], al
pop ebp
pop ebx
add esp, 0x14
ret