SHA1: ComputeHash

ComputeHash

Computes the hash for a give source.



 Public Function ComputeHash(
	  ByRef Source As Variant,
	  Optional ByRef Index As Variant,
	  Optional ByRef Count As Variant ) As Byte ( ) :

Parameters

Source
[ByRef] Variant. The source to compute the hash for.
Index
[ByRef] Optional. Variant. The starting index in a byte array to begin computing the hash.
Count
[ByRef] Optional. Variant. The number of bytes to use to compute the hash.

Return Values

Byte() -  A 20-byte array containing the computed hash.

Remarks

The Source can be either a byte-array or a Stream object.

If the source is a Stream object, then the hash continues to read the stream until no more data is can be read. The hash is computed from all data read from the stream.

See Also

Project CorLib Overview

Class SHA1 Overview