Пример #1
0
        public (byte[], bool) Run(byte[] inputData)
        {
            Metrics.Ripemd160Precompile++;

            // missing in .NET Core
//            return _ripemd.ComputeHash(inputData).PadLeft(32);
            return(Ripemd.Compute(inputData).PadLeft(32), true);
        }
Пример #2
0
        public (ReadOnlyMemory <byte>, bool) Run(ReadOnlyMemory <byte> inputData, IReleaseSpec releaseSpec)
        {
            Metrics.Ripemd160Precompile++;

            // missing in .NET Core
//            return _ripemd.ComputeHash(inputData).PadLeft(32);
            return(Ripemd.Compute(inputData.ToArray()).PadLeft(32), true);
        }
Пример #3
0
        public void Empty_byte_array()
        {
            string result = Ripemd.ComputeString(new byte[] { });

            Assert.AreEqual(RipemdOfEmptyString, result);
        }
Пример #4
0
        public void Empty_string()
        {
            string result = Ripemd.ComputeString(string.Empty);

            Assert.AreEqual(RipemdOfEmptyString, result);
        }
        public (byte[], bool) Run(byte[] inputData)
        {
            // missing in .NET Core
//            return _ripemd.ComputeHash(inputData).PadLeft(32);
            return(Ripemd.Compute(inputData).PadLeft(32), true);
        }