Inheritance: System.Security.Cryptography.Xml.SignedXml
Exemple #1
0
		public void GetPublicKey () 
		{
			XmlDocument doc = new XmlDocument ();
			doc.LoadXml (signature);

			SignedXmlEx sxe = new SignedXmlEx ();
			sxe.LoadXml (doc.DocumentElement);
			
			AsymmetricAlgorithm aa1 = sxe.PublicGetPublicKey ();
			Assert.IsTrue ((aa1 is RSA), "First Public Key is RSA");
			
			AsymmetricAlgorithm aa2 = sxe.PublicGetPublicKey ();
			Assert.IsNull (aa2, "Second Public Key is null");
		}
Exemple #2
0
		public void SigningKeyName () 
		{
			SignedXmlEx sxe = new SignedXmlEx ();
			Assert.IsNull (sxe.SigningKeyName, "SigningKeyName");
			sxe.SigningKeyName = "mono";
			Assert.AreEqual ("mono", sxe.SigningKeyName, "SigningKeyName");
		}
		public void SigningKeyName () 
		{
			SignedXmlEx sxe = new SignedXmlEx ();
			AssertNull ("SigningKeyName", sxe.SigningKeyName);
			sxe.SigningKeyName = "mono";
			AssertEquals ("SigningKeyName", "mono", sxe.SigningKeyName);
		}