SHA256 algorithm implementation.
Наследование: System.Security.Cryptography.HashAlgorithm
Пример #1
0
 public void InputBlockSizeTest()
 {
     SHA256Hash target = new SHA256Hash(); // TODO: Initialize to an appropriate value
     int actual;
     actual = target.InputBlockSize;
     Assert.Inconclusive("Verify the correctness of this test method.");
 }
Пример #2
0
 public void CanTransformMultipleBlocksTest()
 {
     SHA256Hash target = new SHA256Hash(); // TODO: Initialize to an appropriate value
     bool actual;
     actual = target.CanTransformMultipleBlocks;
     Assert.Inconclusive("Verify the correctness of this test method.");
 }
 /// <summary>
 /// Hashes the specified data bytes.
 /// </summary>
 /// <param name="hashBytes">Data to hash.</param>
 /// <returns>
 /// Hashed bytes
 /// </returns>
 protected override byte[] Hash(byte[] hashBytes)
 {
     using (var md = new SHA256Hash())
     {
         return md.ComputeHash(hashBytes);
     }
 }
Пример #4
0
 public void InitializeTest()
 {
     SHA256Hash target = new SHA256Hash(); // TODO: Initialize to an appropriate value
     target.Initialize();
     Assert.Inconclusive("A method that does not return a value cannot be verified.");
 }
Пример #5
0
 public void SHA256HashConstructorTest()
 {
     SHA256Hash target = new SHA256Hash();
     Assert.Inconclusive("TODO: Implement code to verify target");
 }
 /// <summary>
 /// Hashes the specified data bytes.
 /// </summary>
 /// <param name="hashBytes">Data to hash.</param>
 /// <returns>
 /// Hashed bytes
 /// </returns>
 protected override byte[] Hash(IEnumerable<byte> hashBytes)
 {
     using (var md = new SHA256Hash())
     {
         return md.ComputeHash(hashBytes.ToArray());
     }
 }