public override bool Encrypt(NetOutgoingMessage message)
        {
            if (message == null)
            {
                throw new ArgumentNullException(nameof(message));
            }

            int unEncLenBits = message.BitLength;

            var ms = new MemoryStream();

            using (var encryptor = Algorithm.CreateEncryptor())
                using (var cs = new CryptoStream(ms, encryptor, CryptoStreamMode.Write, true))
                    cs.Write(message.GetBuffer().AsSpan(0, message.ByteLength));

            int length = (int)ms.Length;

            message.BitPosition = 0;
            message.EnsureByteCapacity(length + 4);
            message.Write((uint)unEncLenBits);
            message.Write(ms.GetBuffer().AsSpan(0, length));
            message.ByteLength = length + 4;

            return(true);
        }