Use my your own HashAlgorithm Class

From: meno abels (
Date: 03/22/04

Date: Mon, 22 Mar 2004 11:12:43 +0100


i just tried to write my own "very complex" hash algorithm.
And to use this with RSACryptoProvider.SignData(), but I get only
the exception CryptographicException "unknown objectidentifier (OID)".
I have no idea why this happend, the only thing i knew is there is
something in the classes around HashAlgorithm which I have to set
but the documentation gives no hints.

Here the easy implementation: My Array that i pass to the SignData is
only 5 byte long.
        class MyHash : HashAlgorithm
                private byte[] mArray;
                public override void Initialize()
                protected override void HashCore(byte[] array, int ibStart, int cbSize)
                        mArray = array;
                protected override byte[] HashFinal()
                        return mArray;

thanks in advance