Yes, it's on the client side generated using Dennis Sosnoski's library-granular.wsdl. It generates and compiles ok, but the client java code hits this exception in neethi:
[java] Connecting to http://localhost:8080/axis2/services/library-granular [java] Exception in thread "main" java.lang.IllegalArgumentException: {http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200 702}UsernameToken is not a <wsp:Policy> element. [java] at org.apache.neethi.PolicyBuilder.getPolicyOperator(PolicyBuilder.java:177) [java] at org.apache.neethi.PolicyBuilder.getPolicy(PolicyBuilder.java:125) [java] at org.apache.neethi.PolicyEngine.getPolicy(PolicyEngine.java:102) Here's the security policy from the wsdl: <wsp:Policy wsu:Id="UsernameTokenHashPassword" xmlns:wsu= "http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"> <wsp:ExactlyOne> <wsp:All> <sp:SupportingTokens xmlns:sp="http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702"> <wsp:Policy> <sp:UsernameToken sp:IncludeToken= "http://docs.oasis-open.org/ws-sx/ws-securitypolicy/200702/IncludeToken/AlwaysToRecipient"> <wsp:Policy> <sp:HashPassword/> </wsp:Policy> </sp:UsernameToken> </wsp:Policy> </sp:SupportingTokens> </wsp:All> </wsp:ExactlyOne> </wsp:Policy> and the binding operation referencing the policy: <wsdl:operation name="getBook"> <wsp:PolicyReference xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" URI="#UsernameTokenHashPassword"/> <wsdlsoap:operation soapAction="urn:getBook"/> ... etc. ... </wsdl:operation> Jaime Hablutzel Egoavil wrote > > When you receive that error?? when you try to generate a client from a > wsdl > including the policy?? > -- View this message in context: http://axis2.867.n6.nabble.com/Policy-not-supported-is-it-a-bug-tp4340911p4717508.html Sent from the Axis2-user mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscr...@axis.apache.org For additional commands, e-mail: java-user-h...@axis.apache.org