Use my your own HashAlgorithm Class
From: meno abels (meno.abels_at_adviser.com)
Date: 03/22/04
- Next message: Hernan de Lahitte: "Re: How to use SecurityAction.RequestMinimum for UnmanagedCode"
- Previous message: serge calderara: "How to display Network login Window ???"
- Next in thread: Shawn Farkas: "RE: Use my your own HashAlgorithm Class"
- Reply: Shawn Farkas: "RE: Use my your own HashAlgorithm Class"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]
Date: Mon, 22 Mar 2004 11:12:43 +0100
hi,
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()
{
Console.WriteLine("MyHash.Initialize()");
}
protected override void HashCore(byte[] array, int ibStart, int cbSize)
{
Console.WriteLine("MyHash.HashCore");
mArray = array;
}
protected override byte[] HashFinal()
{
Console.WriteLine("MyHash.HashFinal");
return mArray;
}
};
thanks in advance
Meno
- Next message: Hernan de Lahitte: "Re: How to use SecurityAction.RequestMinimum for UnmanagedCode"
- Previous message: serge calderara: "How to display Network login Window ???"
- Next in thread: Shawn Farkas: "RE: Use my your own HashAlgorithm Class"
- Reply: Shawn Farkas: "RE: Use my your own HashAlgorithm Class"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ attachment ]