ComputeHash() public static method

Computes the hash of a given InputStream. This is a wrapper over the HashAlgorithm crypto functions.
public static ComputeHash ( this stream, ChecksumAlgorithm hashType = ChecksumAlgorithm.SHA256, long maxBodySize = null ) : byte[]
stream this the source stream. Use a MemoryStream if uncertain.
hashType ChecksumAlgorithm the Algorithm to use to compute the hash
maxBodySize long
return byte[]
示例#1
0
 public void ComputeHashNullTest()
 {
     Assert.IsNull(ExtensionMethods.ComputeHash(null));
 }