EldoS | Feel safer!

Software components for data protection, secure storage and transfer

porting code for xml signature validation

Also by EldoS: CallbackDisk
Create virtual disks backed by memory or custom location, expose disk images as disks and more.
Posted: 01/14/2014 12:39:33
by Jose Simoes (Basic support level)
Joined: 01/14/2014
Posts: 2


I'm evaluating your XML signing library for a WinRT app I'm working.
Tried to use the XMLBlackbox WinRT sample for guidance without success.

This is a simple XML doc signature validation that is working for ages in a .NET 2.0 software. Now I need to port the code to an WinRT app.
Follows the existing code:

            // Load an XML file into the XmlDocument object.
            xmlDoc.PreserveWhitespace = true;
            // read file stream

            // Create a new SignedXml object and pass it
            SignedXml signedXml = new SignedXml(xmlDoc);

            string sk = "XXXXXXXXXXXXXXXXXXXXXXX"; // remove actual key

            RSACryptoServiceProvider rsaKey = new RSACryptoServiceProvider();
            // Load the first <signature> node.  

            // Check the signature and return the result.
            if (!signedXml.CheckSignature(rsaKey))
                // signature not valid!

Appreciate your help on how to do this (if possible!).

Posted: 01/14/2014 12:44:19
by Eugene Mayevski (Team)

Thank you for contacting us.

Jose Simoes wrote:
Tried to use the XMLBlackbox WinRT sample for guidance without success.

What problems did you have? Did the sample in its unmodified form work?

In regards to your code, SecureBlackbox is much more powerful than .NET classes, and as such its interfaces are a bit more complicated, so there's no one-to-one mapping available for your code.

Sincerely yours
Eugene Mayevski
Posted: 01/14/2014 13:22:36
by Jose Simoes (Basic support level)
Joined: 01/14/2014
Posts: 2

Hi Eugene,

Thank you for the prompt reply.
Yes the sample worked fine.

My problem is with porting the code to use SecureBlackbox.
Understand that there is no one-to-one mapping but appreciate if you could give some pointers on how to achieve my goal because, as you put it, SecureBlackbox is very powerful and has hundreds of classes so I'm rather lost there. The XML sample is rather comprehensive and touches all the different possibilities with XML signing so it doesn't help much either as everything is there too.

Posted: 01/14/2014 13:33:42
by Eugene Mayevski (Team)

We have extensive how-to's in the help file which is installed on your computer. You can check those instructions also online:

Verify the XML signature

Verify the references in signed XML

Sincerely yours
Eugene Mayevski



Topic viewed 1624 times

Number of guests: 1, registered members: 0, in total hidden: 0


Back to top

As of July 15, 2016 EldoS business operates as a division of /n software, inc. For more information, please read the announcement.

Got it!