Pergunta

I'd like to implement a blind RSA signature in .NET. Is there any way to use the standard System.Security.Cryptography APIs to achieve this?

The "obvious" idea doesn't work:

using (var rsa = new RSACryptoServiceProvider())
  signed = rsa.Decrypt(messageBytes, false);
                // CryptographicException: bad data

I appreciate the dangers of blind signature but let's ignore those for a moment. Also, I'm not interested in other types of digital signatures.

Foi útil?

Solução

You are going to have to roll you own. You can use the BigInteger class of .NET 4 or just use the Bouncycastle C# library.

Outras dicas

You can use the "SignData" method to sign any data you like. It has overloads for byte arrays and streams. As far as the blinding goes, you would probably want to use encrypted data (using a key not available to the signer) and then sign that.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top