2 // RSAPKCS1KeyExchangeDeformatter.cs - Handles PKCS#1 v.1.5 keyex decryption.
5 // Sebastien Pouliot (spouliot@motus.com)
7 // (C) 2002 Motus Technologies Inc. (http://www.motus.com)
11 using Mono.Security.Cryptography;
13 namespace System.Security.Cryptography {
15 public class RSAPKCS1KeyExchangeDeformatter : AsymmetricKeyExchangeDeformatter {
19 private RandomNumberGenerator random;
21 public RSAPKCS1KeyExchangeDeformatter ()
26 public RSAPKCS1KeyExchangeDeformatter (AsymmetricAlgorithm key)
31 public override string Parameters {
33 set { param = value; }
36 public RandomNumberGenerator RNG {
37 get { return random; }
38 set { random = value; }
41 public override byte[] DecryptKeyExchange (byte[] rgbData)
44 throw new CryptographicException ();
45 return PKCS1.Decrypt_v15 (rsa, rgbData);
48 public override void SetKey (AsymmetricAlgorithm key)
54 throw new CryptographicException ();