<div dir="ltr">Hi David,<div><br></div><div>May be this might help (sorry its not a Delphi code its in C#)</div><div><br></div><div><a href="https://msdn.microsoft.com/en-us/library/ms229744(v=vs.110).aspx">https://msdn.microsoft.com/en-us/library/ms229744(v=vs.110).aspx</a><br></div><div><br></div><div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Jul 29, 2016 at 8:53 AM, David Moorhouse <span dir="ltr"><<a href="mailto:David.Moorhouse@pegasus.org.nz" target="_blank">David.Moorhouse@pegasus.org.nz</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div lang="EN-NZ" link="blue" vlink="purple">
<div>
<p class="MsoNormal">Hi<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">We have the need to sign a snippet of XML with an X509 digital certificate. The algorithm is to canonicalise the XML, compute a SHA256 hash on this, and sign the hash with the certificate’s private key.<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">I can’t see any easy way of doing this within the VCL.<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">Any hints, or better still working code, are appreciated.<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal">David<u></u><u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<p class="MsoNormal"><u></u> <u></u></p>
<table border="0" cellspacing="0" cellpadding="0" style="border-collapse:collapse">
<tbody>
<tr>
<td width="357" valign="top" style="width:267.65pt;padding:0cm 5.4pt 0cm 5.4pt">
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#47678f">David Moorhouse (BCom)</span></b><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#47678f">
| <b>Principal Software Engineer - HealthOne</b><br>
Pegasus Health (Charitable) Ltd </span><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#47678f"><u></u><u></u></span></p>
<p class="MsoNormal"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#47678f">P: 03 353 0871 | W: </span><span style="color:#1f497d"><a href="http://www.pegasus.org.nz/" target="_blank"><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#47678f">www.pegasus.org.nz</span></a></span><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#47678f"> <br>
E: </span><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#1f497d"><a href="mailto:david.moorhouse@pegasus.org.nz" target="_blank"><span style="color:blue">david.moorhouse@pegasus.org.nz</span></a></span><u><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#47678f"><br>
</span></u><span style="font-size:10.0pt;font-family:"Arial","sans-serif";color:#47678f">PO Box 741, Christchurch 8140<br>
160 Bealey Ave, Christchurch 8014</span><b><span style="color:#47678f"><u></u><u></u></span></b></p>
</td>
<td width="259" valign="top" style="width:194.45pt;padding:0cm 5.4pt 0cm 5.4pt">
<p class="MsoNormal"><span style="color:#1f497d"><img border="0" width="240" height="76" src="cid:image001.jpg@01D1E976.041C20A0" alt="cid:image003.jpg@01CEE516.6F544D00"></span><b><span style="color:#47678f"><u></u><u></u></span></b></p>
</td>
</tr>
</tbody>
</table>
<p class="MsoNormal"><span><u></u> <u></u></span></p>
<p class="MsoNormal"><u></u> <u></u></p>
</div>
<p><font color="#47678f" size="2" face="Arial">*****************************************************</font></p>
<p><font color="#47678f" size="2" face="Arial">This email or attachment(s) may contain
confidential or legally privileged information intended for the sole use of the
addressee(s). Any use, redistribution, disclosure, or reproduction of this
message, except as intended, is prohibited. If you received this email in error,
please notify the sender and erase all copies of the message, including any
attachments.</font></p>
<p><font color="#47678f" size="2" face="Arial">Any views or opinions expressed in this
email (unless otherwise stated) may not represent those of Pegasus Health
Ltd.</font></p>
<p><font color="#47678f" size="2" face="Arial">**********************************************************</font></p>
</div>
<br>_______________________________________________<br>
NZ Borland Developers Group - Delphi mailing list<br>
Post: <a href="mailto:delphi@listserver.123.net.nz">delphi@listserver.123.net.nz</a><br>
Admin: <a href="http://delphi.org.nz/mailman/listinfo/delphi" rel="noreferrer" target="_blank">http://delphi.org.nz/mailman/listinfo/delphi</a><br>
Unsubscribe: send an email to <a href="mailto:delphi-request@listserver.123.net.nz">delphi-request@listserver.123.net.nz</a> with Subject: unsubscribe<br></blockquote></div><br><br clear="all"><div><br></div>-- <br><div class="gmail_signature" data-smartmail="gmail_signature"> vikas</div>
</div>