Adding WSS security to apache axis 1.3 stub
i am new to webservices and have a requirement to call a webservice
secured with WSS security into one of my application. My app server is
very old one running on jdk 1.4 version still.
I created all the web service proxy classes using the eclipse web service
proxy from wsdl url.
Call call = (Call) service.createCall();
call.setUsername("XXXX");
call.setPassword("XXXXXXX");
//call.addParameter("password",
org.apache.axis.Constants.XSD_STRING,
javax.xml.rpc.ParameterMode.IN);
call.setTargetEndpointAddress(new java.net.URL(endpoint));
call.setOperationName("getEntityPendingClaims");
call.addParameter("entity-number",
org.apache.axis.encoding.XMLType.XSD_STRING,ParameterMode.IN );
call.addParameter("entity-type",
org.apache.axis.encoding.XMLType.XSD_STRING,ParameterMode.IN );
call.setReturnType(XMLType.XSD_STRING);
msg = (String)call.invoke(new Object[] {entity,type});
but this is giving me a
faultString: An error was discovered processing the <wsse:Security>
header
in SOAP UI if i set the WSS-Password type to Password Text i am getting
the correct out put.
My question is how could i implement the same in apache axis 1.3? How
could i implement wss security to this client call. After few days search
i still could not find a complete example demonstrating this. So if
anybody is having code sample, then it will be very helpful.
No comments:
Post a Comment