I am using the following code:
private static readonly HashAlgorithm m_annotativeStateIDHasher = new MD5CryptoServiceProvider();
//Get the hashed bytes
byte[] annotativeStateIDHashedBytes = m_annotativeStateIDHasher.ComputeHash(annotativeStateIDBytes);
Getting the following error very often:
Error: System.Security.Cryptography.CryptographicException: Hash not valid for use in specified state.
at System.Security.Cryptography.CryptographicException.ThrowCryptogaphicException(Int32 hr)
at System.Security.Cryptography.Utils._HashData(SafeHashHandle hHash, Byte[] data, Int32 ibStart, Int32 cbSize)
at System.Security.Cryptography.MD5CryptoServiceProvider.HashCore(Byte[] rgb, Int32 ibStart, Int32 cbSize)
at System.Security.Cryptography.HashAlgorithm.ComputeHash(Byte[] buffer)
Any help is really appreciated
agolovan