Missing in SOAP Header when Calling Secured WS

When calling Secured Web Service from BPEL there is an error received in logs and in Bpel Console :

<ERROR> <default.collaxa.cube.ws>
<WSIFInvocationHandler::invoke> Fault happened: exception during SOAP invoke: Missing
<wsse:Security> in SOAP Header; nested exception is:
javax.xml.rpc.soap.SOAPFaultException: Missing <wsse:Security> in SOAP Header

The partner link properties in bpel.xml are all set correctly to use WSSE headers :

<partnerLinkBinding name="crm">
<property name="wsdlLocation">crm.wsdl</property>
<property name="wsseUsername">user_name</property>
<property name="wssePassword">the_password</property>
<property name="wsseHeaders">credentials</property>
</partnerLinkBinding>

Error only occurs on 10.1.3.4 and on 10.1.3.3.1 MLR#14 or higher. Exact same BPEL process works fine on 10.1.3.3.0 and on 10.1.3.3.1 until MLR#13.

When passing the WS Security header through partnerlink the SOAP request can generate OASIS 2002 or OASIS 2004 compliant header. For this there was an aditional parameter introduced : wsseOASIS2004Compliant

Setting it to "false" (the default value in 10.1.3.4) generates OASIS 2002 compliant header :

<property name="wsseOASIS2004Compliant">false</property>

and setting it to "true" generates OASIS 2004 compliant header :

<property name="wsseOASIS2004Compliant">true</property>

SOLUTION --> You need to change the PartnerLink properties in bpel.xml and add wsseOASIS2004Compliant property and set it to true.

<partnerLinkBinding name="crm">
<property name="wsdlLocation">crm.wsdl</property>
<property name="wsseUsername">user_name</property>
<property name="wssePassword">the_password</property>
<property name="wsseHeaders">credentials</property>
<property name="wsseOASIS2004Compliant">true</property>
</partnerLinkBinding>



Posted in Labels: , | 1 comments