Skip to content

Instantly share code, notes, and snippets.

@drawcode
Created June 14, 2019 23:31
Show Gist options
  • Save drawcode/63eb00328561e61ec59e3d0f9170c7c6 to your computer and use it in GitHub Desktop.
Save drawcode/63eb00328561e61ec59e3d0f9170c7c6 to your computer and use it in GitHub Desktop.
XMl Digital Signature with References and Custom Objects
<Signature xmlns="http://www.w3.org/2000/09/xmldsig#">
<SignedInfo>
<CanonicalizationMethod Algorithm="http://www.w3.org/TR/2001/REC-xml-c14n-20010315#WithComments"/>
<SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#dsa-sha1"/>
<Reference URI="#object">
<DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha1"/>
<DigestValue>7/XTsHaBSOnJ/jXD5v0zL6VKYsk=</DigestValue>
</Reference>
</SignedInfo>
<SignatureValue>
RpMRbtMHLa0siSS+BwUpLIEmTfh/0fsld2JYQWZzCzfa5kBTz25+XA==
</SignatureValue>
<KeyInfo>
<KeyValue>
<DSAKeyValue>
<P>
/KaCzo4Syrom78z3EQ5SbbB4sF7ey80etKII864WF64B81uRpH5t9jQTxeEu0Imbz
RMqzVDZkVG9xD7nN1kuFw==
</P>
<Q>
li7dzDacuo67Jg7mtqEm2TRuOMU=
</Q>
<G>
Z4Rxsnqc9E7pGknFFH2xqaryRPBaQ01khpMdLRQnG541Awtx/XPaF5Bpsy4pNWMOH
CBiNU0NogpsQW5QvnlMpA==
</G>
<Y>
wbEUaCgHZXqK4qLvbdYrAc6+Do0XVcsziCJqxzn4cJJRxwc3E1xnEXHscVgr1Cql9
i5fanOKQbFXzmb+bChqig==
</Y>
</DSAKeyValue>
</KeyValue>
</KeyInfo>
<Object Id="object">some text</Object>
</Signature>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment