Hi Werner, 
I did not arrive at client point, I am only verifying that when I deploy my
wsdd as above
<deployment xmlns="http://xml.apache.org/axis/wsdd/";
xmlns:java="http://xml.apache.org/axis/wsdd/providers/java";>
 <service name="Addition" provider="java:RPC" style="document"
use="literal">
  <requestFlow>
   <handler type="java:org.apache.ws.axis.security.WSDoAllReceiver">
    <parameter name="passwordCallbackClass" value="PWCallback"/>
    <parameter name="action" value="UsernameToken"/>
   </handler>
  </requestFlow>
  <parameter name="className" value="Addition"/>
  <parameter name="allowedMethods" value="add"/>
  <parameter name="scope" value="application"/>
 </service>
</deployment>

My service did not appear anymore as "view services" at happyaxis.jsp. Thus,
I did not arrive to publish it. Actually, this is my problem, I did not
achieve the client step, I am at the prior step. 

Thank you again,
Daniela

-----Message d'origine-----
De : Dittmann Werner [mailto:[EMAIL PROTECTED] 
Envoy� : lundi 14 mars 2005 08:41
� : '[EMAIL PROTECTED]'; [email protected]
Objet : AW: Problem in deploying with wss4j

Daniela,

is you client enabled to use WSS4J? If your client does not use WSS4J the
server does not accept the request because of missing security tokens and
returns an error code.

To enable your client you must have an Axis deployment file for your client
als well. In turn your client shall have the WSS4J libs (and probably the
xmlsec libs), all other classes (also you PWCallback) in its classpath.

Regards,
Werner

> -----Urspr�ngliche Nachricht-----
> Von: Daniela CLARO [mailto:[EMAIL PROTECTED]
> Gesendet: Freitag, 11. M�rz 2005 16:36
> An: [email protected]
> Betreff: Problem in deploying with wss4j
> 
> 
> Hi all,
>  I am using Tomcat 5.0.25 with Java 1.4.2_06-b03, Axis 1.2, and I put 
> wss4j that I download from 
> http://www.sagagames.com/johan/blog/wss4j.jar and I download 
> xmlsec.jar at "Found XML Security API
> (org.apache.xml.security.Init) at C:\Program Files\Apache Tomcat 
> 5.0\webapps\axis\WEB-INF\lib\xmlsec.jar"
> 
> The problem is that when I deploy that
> 
> <deployment xmlns="http://xml.apache.org/axis/wsdd/";
> xmlns:java="http://xml.apache.org/axis/wsdd/providers/java";>
>  <service name="stock-wss-01" provider="java:RPC" style="document"
> use="literal">
>   <requestFlow>
>    <handler type="java:org.apache.ws.axis.security.WSDoAllReceiver">
>     <parameter name="passwordCallbackClass" value="PWCallback"/>
>     <parameter name="action" value="UsernameToken"/>
>    </handler>
>   </requestFlow>
>   <parameter name="className" 
> value="samples.stock.StockQuoteService"/>
>   <parameter name="allowedMethods" value="getQuote"/>
>   <parameter name="scope" value="application"/>  </service> 
> </deployment>
> 
> And if I did not use the handler, all think works. I create the class 
> PWCallback import java.io.IOException; import 
> javax.security.auth.callback.Callback;
> import javax.security.auth.callback.CallbackHandler;
> import javax.security.auth.callback.UnsupportedCallbackException;
> import org.apache.ws.security.WSPasswordCallback;
> 
> public class PWCallback implements CallbackHandler {
>     public void handle(Callback[] callbacks) throws IOException, 
> UnsupportedCallbackException {
>         for (int i = 0; i < callbacks.length; i++) {
>             if (callbacks[i] instanceof WSPasswordCallback) {
>                 WSPasswordCallback pc = 
> (WSPasswordCallback)callbacks[i];
>                 // set the password given a username
>                 if ("wss4j".equals(pc.getIdentifer())) {
>                     pc.setPassword("security");
>                 }
>             } else {
>                 throw new UnsupportedCallbackException(callbacks[i],
> "Unrecognized Callback");
>             }
>         }
>     }
> }
> 
> I want to know if isn't it some lib that I am missing...I checked all, 
> I did not find, please, if you have some idea, mail me!
> Thank you
> Daniela
> 

Reply via email to