Skip to Content
0
Former Member
Oct 06, 2009 at 06:25 PM

Webservuce with security token

117 Views

Hi, I have a scenario where i need to call a webservice with security token in PI. I am trying firstly to call this using soap UI.

As per the provider of service, I have to use the security toekn and call the service in Three Steps:

Request/Response1 u2013 This is the initial request for a security token to establish the WS-Trust connection.

Request/Response2 u2013 This is the actual request for information.

Request/Response3 u2013 This is the closing communication to let the server know there wonu2019t be another request.

I could find WSDL for their step2 But cannot understand how to make a call for step 1 to get the security token.

the sample step 1 req looks like this

Can any bdy please suggest me that is there any standard WSDL exsists for calling security token or any link wher i could understand this and make a sucessful call using SOAP UI.

Thanks

-Kulwant

<s:Envelope xmlns:s="http://www.w3.org/2003/05/soap-envelope" xmlns:a="http://www.w3.org/2005/08/addressing" xmlns:u="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"><s:Header><a:Action s:mustUnderstand="1">http://schemas.xmlsoap.org/ws/2005/02/trust/RST/SCT</a:Action><a:MessageID>urn:uuid:f4d5f253-12f7-4a4e-9c16-9387334bd0d4</a:MessageID><a:ReplyTo><a:Address>http://www.w3.org/2005/08/addressing/anonymous</a:Address></a:ReplyTo><a:To s:mustUnderstand="1">https://demo.serengetilaw.com/sandbox/WebServices/APDataExchange.svc</a:To><o:Security s:mustUnderstand="1" xmlns:o="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd"><u:Timestamp u:Id="_0"><u:Created>2009-09-30T19:26:35.793Z</u:Created><u:Expires>2009-09-30T19:31:35.793Z</u:Expires></u:Timestamp><o:UsernameToken u:Id="uuid-fa62b0d8-cd8a-4bff-90a4-2673bbe6d451-1"><o:Username>USERNAME</o:Username><o:Password o:Type="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText">PASS</o:Password></o:UsernameToken></o:Security></s:Header><s:Body><t:RequestSecurityToken xmlns:t="http://schemas.xmlsoap.org/ws/2005/02/trust"><t:TokenType>http://schemas.xmlsoap.org/ws/2005/02/sc/sct</t:TokenType><t:RequestType>http://schemas.xmlsoap.org/ws/2005/02/trust/Issue</t:RequestType><t:Entropy><t:BinarySecret u:Id="uuid-2e19ff04-fd8e-43b2-aac3-cd2a9fd5712c-1" Type="http://schemas.xmlsoap.org/ws/2005/02/trust/Nonce">aBAfiQXY7aMnIxc3gNRkn/h55KaKa7fonH2hnQCiZZc=</t:BinarySecret></t:Entropy><t:KeySize>256</t:KeySize></t:RequestSecurityToken></s:Body></s:Envelope>

Edited by: Kulwant Bhatia on Oct 6, 2009 8:25 PM