Regards, Sanjay Singh
SCJP-1.6, OCEWCD 6
Client code:
Handler code:
Prompter
C:\pbx_u01\apps\JavaWrkspcs\WebService\target\classes>java -cp .;..\WebService-1.0-SNAPSHOT\WEB-INF\lib\log4j-1.2.14.jar;..\WebService-1.0-SNAPSHOT\WEB-INF\lib\xws-security-3.0.jar;..\WebService-1.0-SNAPSHOT\WEB-INF\lib\jaxws-tools-2.2.8.jar com.java.jaxws.security.wss.SecureTimeServerClient
09:55:58,572 DEBUG main wss.SecureTimeServerClient:32 - adding ClientHandler
09:55:58,606 DEBUG main wss.ClientHandler:34 - costructor
09:55:58,632 DEBUG main wss.ClientHandler:43 - reading the config file
09:55:59,204 DEBUG main wss.ClientHandler:68 - handleMessage
09:55:59,205 DEBUG main wss.ClientHandler:71 - outbound: true
Sep 5, 2013 9:55:59 AM com.sun.xml.wss.impl.filter.DumpFilter process
INFO: ==== Sending Message Start ====
<?xml version="1.0" encoding="UTF-8"?>
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/">
<S:Body>
<ns2:getTimeAsString xmlns:ns2="http://ts.ch02/"/>
</S:Body>
</S:Envelope>
==== Sending Message End ====
09:55:59,994 DEBUG main wss.ClientHandler:102 - Outgoing message:
<S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/"><S:Body><ns2:getTimeAsString xmlns:ns2="http://ts.ch02/"/></S:Body></S:Envelope>Exception in thread "main" javax.xml.ws.soap.SOAPFaultException: com.sun.xml.wss.XWSSecurityException: com.sun.xml.wss.XWSSecurityException: Message does not conform to configured policy [ AuthenticationTokenPolicy(S) ]: No Security Header found
at com.sun.xml.internal.ws.fault.SOAP11Fault.getProtocolException(Unknown Source)
at com.sun.xml.internal.ws.fault.SOAPFaultBuilder.createException(Unknown Source)
at com.sun.xml.internal.ws.client.sei.SyncMethodHandler.invoke(Unknown Source)
at com.sun.xml.internal.ws.client.sei.SyncMethodHandler.invoke(Unknown Source)
at com.sun.xml.internal.ws.client.sei.SEIStub.invoke(Unknown Source)
at $Proxy28.getTimeAsString(Unknown Source)
at com.java.jaxws.security.wss.SecureTimeServerClient.main(SecureTimeServerClient.java:36)
Caused by: java.lang.RuntimeException: com.sun.xml.wss.XWSSecurityException: com.sun.xml.wss.XWSSecurityException: Message does not conform to configured policy [ AuthenticationTokenPolicy(S) ]: No Security Header found
at com.java.jaxws.security.wss.EchoSecurityHandler.handleMessage(EchoSecurityHandler.java:100)
at com.java.jaxws.security.wss.EchoSecurityHandler.handleMessage(EchoSecurityHandler.java:1)
at com.sun.xml.ws.handler.HandlerProcessor.callHandleMessage(HandlerProcessor.java:292)
Regards, Sanjay Singh
SCJP-1.6, OCEWCD 6
Regards, Sanjay Singh
SCJP-1.6, OCEWCD 6
Regards, Sanjay Singh
SCJP-1.6, OCEWCD 6
Consider Paul's rocket mass heater. |