Skip to Content

In scenarios involving webservice calls, there are cases wherein the webservice to be called expects a UsernameToken, Timestamp to be included as per WS-Security standards.

The SOAP adapter does not support this feature as per default installation, the Axis Framework needs to be enabled which then enables the SOAP adapter to implement this requirement.

Note: 1039369 contains the FAQs for Axis Framework.

For enabling the Axis Framework we need to deploy the archive aii_af_axisprovider.sda containing the necessary jar files.The optional jar files can be included in the archive based upon the need.

Note: 1028961 describes how to prepare the archive.

In order to use the WS-Security features the optional XML Security API and Apache WSS4J libraries need to be included in the archive.

The requisite jars can be downloaded from: http://apache.org  (http://apache.org/)

The deployment status can be checked using the URL: http://host:port/XIAxisAdapter/MessageServlet  (http://host:port/XIAxisAdapter/MessageServlet)

Deployment Status for required jar files:

!https://weblogs.sdn.sap.com/weblogs/images/251956975/Diag_1a.JPG|height=415|alt=required jars|width=695|src=https://weblogs.sdn.sap.com/weblogs/images/251956975/Diag_1a.JPG|border=0

Deployment Status for optional jar files:

optional jars

After successful deployment, the following handler(module) needs to be configured in the receiver SOAP adapter:

java:com.sap.aii.adapter.axis.ra.handlers.security.WSDoAllSender

The message protocol in the channel needs to be: Axis</p><p>The handler needs to be in sequence after the handler with module key: XIREQ</p><p> </p><p>Following parameters need to be used for the module key of the WSDoAllSender handler:</p><p>action             = UsernameToken Timestamp<br />handler.type    = java:com.sap.aii.adapter.axis.ra.handlers.security.WSDoAllSender<br />passwordType  = PasswordDigest<br />user               = <username to be used><br />pwd.password  = <password to be used></p><p>!https://weblogs.sdn.sap.com/weblogs/images/251956975/Diag_2a.JPG|height=295|alt=module 1|width=685|src=https://weblogs.sdn.sap.com/weblogs/images/251956975/Diag_2a.JPG|border=0!</p><p>!https://weblogs.sdn.sap.com/weblogs/images/251956975/Diag_2bb.JPG|height=236|alt=module 2|width=676|src=https://weblogs.sdn.sap.com/weblogs/images/251956975/Diag_2bb.JPG|border=0!</p><p>The generated message is not displayed in the communication channel log.</p><p>In my case it was a asynchronous webservice,it expected a UsernameToken and Timestamp, in case of incorrect configuration of the <br />handler I was able to get the error message back as part of the webservice acknowledgement.</p><p> </p><p><u>In case of wrong sequence for action parameter,ie: “Timestamp UsernameToken” instead of “UsernameToken Timestamp” :</u></p><p>!https://weblogs.sdn.sap.com/weblogs/images/251956975/Diag_3.JPG|height=255|alt=wrong sequence|width=668|src=https://weblogs.sdn.sap.com/weblogs/images/251956975/Diag_3.JPG|border=0!</p><p> </p><p><u>In case of wrong usernametoken:</u></p><p>!https://weblogs.sdn.sap.com/weblogs/images/251956975/Diag_4.JPG|height=269|alt=wrong username|width=623|src=https://weblogs.sdn.sap.com/weblogs/images/251956975/Diag_4.JPG|border=0!</p><p> </p><p><u>In case of wrong password:</u></p><p>!https://weblogs.sdn.sap.com/weblogs/images/251956975/Diag_5.JPG|height=248|alt=wrong password|width=596|src=https://weblogs.sdn.sap.com/weblogs/images/251956975/Diag_5.JPG|border=0!</body>

To report this post you need to login first.

2 Comments

You must be Logged on to comment or reply to a post.

Leave a Reply