EldoS | Feel safer!

Software components for data protection, secure storage and transfer

Signing SOAP message with timestamp

Also by EldoS: Callback File System
Create virtual file systems and disks, expose and manage remote data as if they were files on the local disk.
#30040
Posted: 07/15/2014 00:50:47
by Popeye  (Basic support level)
Joined: 10/22/2010
Posts: 10

Hi all,
I'm trying SecureSOAP.NET sample to sign soap message. I have a question. How can append timestamp in signature like below.
Thanks for help


Code
<wsse:Security>
      <wsu:TimeStamp wsu:id="TimeStamp-7eea0ee2-38fa-4c44-923d-dd6aea8ca424">
        <wsu:Created>2014-07-14T14:12:36.4695330Z</wsu:Created>
        <wsu:Expires>2014-07-14T14:17:36.4695330Z</wsu:Expires>
      </wsu:TimeStamp>
#30041
Posted: 07/15/2014 02:48:48
by Dmytro Bogatskyy (EldoS Corp.)

Thank you for contacting us.

Quote
How can append timestamp in signature like below.

After TElXMLSOAPClient.GenerateMessage() method and before SendMessage() method you can use a following code to add a timestamp:
Code
int k = FSOAPClient.SOAPMessage.AddSecurityHeader();
TElXMLWSUTimestamp Timestamp = new TElXMLWSUTimestamp();
FSOAPClient.SOAPMessage.get_SecurityHeaders(k).AddToken(Timestamp);
Timestamp.CreatedUTC = DateTime.UtcNow;
Timestamp.ExpiresUTC = ...;


The only thing, that in this case a Header element will be created after the Body element, this issue should be fixed in the upcoming release.

Reply

Statistics

Topic viewed 739 times

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




|

Back to top

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

Got it!