[Mono-list] Mono support of W3C xmldsig?

Atsushi Eno atsushi@ximian.com
Sat, 17 Jul 2004 10:17:19 +0900


Hello,

your code could not be compiled. Can you provide the complete
standalone runnable example?

Basically xmldsig support should work, but there are missing
supports (such as XPath here() function) and some bugs.

Atsushi Eno

John Gonsalves wrote:

> Will the following .NET code work with Mono?
> 
> public class XmlDigitalSigning
> {
>                public const String MS_DEF_PROV = "Microsoft Base 
> Cryptographic Provider v1.0";
>                public const int PROV_RSA_FULL = 1;
> 
>     public SignedXml Sign(String Uri, XmlDocument doc, 
> RSACryptoServiceProvider rsa, SigType type, String serialNumber)
>     {
> 
>                     SignedXml xmlSign = new SignedXml();
>         xmlSign.SigningKey = rsa;
> 
>         Reference reference = new Reference();
>         if (type == SigType.Detached)
>         {
>             reference.Uri = Uri;
>         }
>         else if (type == SigType.Enveloping)
>         {
>             DataObject obj = new DataObject();
>             obj.Data = doc.ChildNodes;
>             obj.Id = serialNumber;
>             reference.Uri = "#" + serialNumber;
> 
>             xmlSign.AddObject(obj);
>         }
>         xmlSign.AddReference(reference);
> 
>         xmlSign.ComputeSignature();
>         return xmlSign;
>     }
> 
> }
> 
> _________________________________________________________________
> Don’t just search. Find. Check out the new MSN Search! 
> http://search.msn.click-url.com/go/onm00200636ave/direct/01/
> 
> _______________________________________________
> Mono-list maillist  -  Mono-list@lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-list
>