Sunday, June 3, 2012

Invoking a web service from the composite with HTTP Basic authentication – Oracle SOA Suite

Invoking a web service from the composite with HTTP Basic authentication  – Oracle SOA Suite 11g

Sometimes we may need to invoke the HTTP Basic authentication enabled web service from the  Oracle SOA Suite composite.
This blog will explain the steps to invoke the web service with the HTTP basic authentication enabled.

Configure the credential store:

The credential should be configured in the credential store to invoke the web service with the HTTP Basic authentication enabled.

If the credential store is not configured already then follow the below steps to do the same.
  • Login to EM
  • Right Click on WebLogic Domain - Select Security and Click on Credentials


The same will work in Oracle SOA Suite 12c but the screens will be little different.

oracle_soa_12c_credential_map


  • Click on Create Map


  • Enter the map name as 'oracle.wsm.security' and click OK



  • Select the new Map and click on Create Key



  • Enter the key name as 'basic.credentials'
  • Enter the user name and password; I am using the admin user 'weblogic' (we can use the different user)

  • Click OK


Configure the Authentication policy to the Composite Service:

  • Open the composite.xml   
  • Right click on the External reference service for which the HTTP Basic authentication is required for the invocation.

  •  Add the security Policy oracle/wss_http_token_client_policy for authentication in the security section.




Deploy the composite to the server. The same policy configuration can also be done through EM console after the deployment of the composite.

Testing From SOAP UI

No need to provide any username/password while invoking the service, the username/password configured in the credential store will be used to call the reference service.The success response will be received from the web service if the credential configured in the credential store is correct.





No comments:

Post a Comment