tufffta
-
Posts
3 -
Joined
-
Last visited
Content Type
Profiles
Forums
Events
Posts posted by tufffta
-
-
Alright, thanks!
-
Hello,
I am a bit confused by this statement that I found on a sha256 digestvalue calculation here: http://www.w3.org/TR/2002/REC-xmlenc-core-20021210/Overview.html#sha256
A SHA-256 digest is a 256-bit string. The content of the DigestValue element shall be the base64 encoding of this bit string viewed as a 32-octet octet stream.
Does that mean that the sha256 hash value has to be converted to a 32-bit string before encoding it to base64? If yes, could someone please tell me how this can be done? I'm a kind of a n00b, but I haven't found info on how to do that on the internet.
Help: How does URI reference work in xml dsig? Calculating digestvalue?
in XML
Posted
I am analyzing an XML-DSIG file in order to know how to write my piece of software code that generates XML-DSIGnatures. I am having this trouble and desperately need help...
This is a bit I am trying to understand from an attached signatures0.xml:
From what I understand, this refers to a SignedPropertiesElem_0 element in the same file. I am trying to determine exactly what it refers to - what piece of code should be selected and used later on for canonicalization and then calculating a digest value. Is it this:
Or this:
Or this:
Or some other part of it?
I tried the first one, then letting it through a StylusStudio canonicalization OR http://www.soapclient.com/xmlcanon.html (both seem to return identical results), which results in this:
and then calculating the digest value using these tools:
http://www.webutils.pl/index.php?idx=sha1
http://hash.online-convert.com/sha256-generator
http://www.freeformatter.com/message-digest.html#ad-output
They all returned the same result, but that result is different from the one in the xml file: kOlNXyBs6oSP9hbh+4niZMNQ9OsOCzYhkSYYG4YdHQU=.
What am I doing wrong? What part of the xml document should I copy and paste into the canonicalizer and then into digest calculator? I've spent several days trying different things and looking for answers and haven't got anything... I am sure I missed something, therefore I am asking for your help.