RSA Decryption with public key?



We have an .NET 2.0 application that requires verifying that an external
application knows the private key in a public key, private key pair.

The verification protocol developed by manufacturer of the external
application involves sending the external application known data, allowing
the external application to encrypt the data using the private key, and then
verifying that the returned cipher text matches the original data once
decrypted by our application with the public key.

Note: The returned data is encrypted by the private key -not signed!

From our research, the RSACryptoServiceProvider in the Framework does not
directly support this type of protocol. For reference:

http://social.msdn.microsoft.com/Forums/en-US/netfxbcl/thread/7fd9ab50-40c7-47c2-ae80-04e5ccad839d/

http://www.eggheadcafe.com/software/aspnet/31582085/no-way-to-encrypt-with-pr.aspx

Has anyone found a suitable workaround for this? We have had some success
with Bouncy Castle. (http://www.bouncycastle.org/) However, we would prefer
not to include additional third party libraries due to legal concerns and
additional product requirements.

Thanks in advance!


.



Relevant Pages

  • RE: PGP scripting...
    ... cryptosystems, ... In these systems divulging your private key compromises the public ... Here is a quick over view of the public key encryption routines (the ...
    (SecProg)
  • Re: Private & Public Key storage location
    ... with that you complete the 'certificate' to have both public and private key ... To view the complete cert, you access the cert mmc, ... its end & send only the public key to the CA along with the other websites ... The CA never know the private key of the website. ...
    (microsoft.public.inetserver.iis.security)
  • CryptImportKey NTE_BAD_KEY error.
    ... of the private key is just fine but when I try to import the public key I ... // This Asymetric key set will be used to create the Autherization Code. ... delete psBuffer; ...
    (microsoft.public.platformsdk.security)
  • CryptImportKey NTE_BAD_KEY error.
    ... of the private key is just fine but when I try to import the public key I ... // This Asymetric key set will be used to create the Autherization Code. ... delete psBuffer; ...
    (microsoft.public.security)
  • Re: Private & Public Key storage location
    ... client use the public key to ... corresponds to this certiticate' when you view the cert. ... it will has the private key as well. ... installed for your website, it will be sent to all the clients who connect ...
    (microsoft.public.inetserver.iis.security)