Hello,

Basically, you may use WSS4J with Axis 1.x to implement WS-Security.

Rampart is the WS-Security module in Axis 2. Rampart uses WSS4J.

Hope this helps.

José Ferreiro

On Mon, Jul 14, 2008 at 6:38 PM, Chau, Hoang <[EMAIL PROTECTED]> wrote:

>  Hi all,
>
> I am new to webservice security so could anyone tell me the difference
> between WSS4j and Rampart or point me the link talk about them.
>
> Thanks
>
>  ------------------------------
> *From:* Juan Gabriel Arias [mailto:[EMAIL PROTECTED]
> *Sent:* Monday, July 14, 2008 9:18 AM
> *To:* [email protected]
> *Subject:* QName is null for...
>
> Hi all,
> i'm facing this issue. I try to generate the java files from this wsdl
>
> <wsdl:operation name="RefundTransaction">
>     <soap:operation soapAction="RefundTransaction" />
>     <wsdl:input><soap:body use="literal" /></wsdl:input>
>     <wsdl:output><soap:body use="literal" /></wsdl:output>
> </wsdl:operation>
>
> And the generator throws this exception:
>
> Using AXIS2_HOME:   D:\java\axis2-1.4\
> Using JAVA_HOME:    C:\Program Files\Java\jre1.6.0_05
> Retrieving document at 'OIContentProviderv0.2.wsdl'.
> Exception in thread "main" 
> org.apache.axis2.wsdl.codegen.CodeGenerationException:
> org.apache.axis2.wsdl.codegen.CodeGenerationException:
> java.lang.RuntimeException: Element QName is null for ErrorResponseMessage!
>         at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(
> CodeGenerationEngine.java:271)
>         at org.apache.axis2.wsdl.WSDL2Code.main(WSDL2Code.java:35)
>         at org.apache.axis2.wsdl.WSDL2Java.main(WSDL2Java.java:24)
> Caused by: org.apache.axis2.wsdl.codegen.CodeGenerationException:
> java.lang.RuntimeException: Element QName is null for ErrorResponseMessage!
>         at org.apache.axis2.wsdl.codegen.emitter.
> AxisServiceBasedMultiLanguageEmitter.emitStub(
> AxisServiceBasedMultiLanguageEmitter.java:534)
>         at org.apache.axis2.wsdl.codegen.CodeGenerationEngine.generate(
> CodeGenerationEngine.java:260)
>         ... 2 more
> Caused by: java.lang.RuntimeException: Element QName is null for
> ErrorResponseMessage!
>         at org.apache.axis2.wsdl.codegen.emitter.
> AxisServiceBasedMultiLanguageEmitter.getFaultParamElements(
> AxisServiceBasedMultiLanguageEmitter.java:2829)
>         at org.apache.axis2.wsdl.codegen.emitter.
> AxisServiceBasedMultiLanguageEmitter.getFaultElement(
> AxisServiceBasedMultiLanguageEmitter.java:2748)
>         at org.apache.axis2.wsdl.codegen.emitter.
> AxisServiceBasedMultiLanguageEmitter.generateMethodElement(
> AxisServiceBasedMultiLanguageEmitter.java:2269)
>         at org.apache.axis2.wsdl.codegen.emitter.
> AxisServiceBasedMultiLanguageEmitter.loadOperations(
> AxisServiceBasedMultiLanguageEmitter.java:2151)
>         at org.apache.axis2.wsdl.codegen.emitter.
> AxisServiceBasedMultiLanguageEmitter.createDOMDocumentForCallbackHandler(
> AxisServiceBasedMultiLanguageEmitter.java:1151)
>         at org.apache.axis2.wsdl.codegen.emitter.
> AxisServiceBasedMultiLanguageEmitter.writeCallBackHandlers(
> AxisServiceBasedMultiLanguageEmitter.java:1117)
>         at org.apache.axis2.wsdl.codegen.emitter.
> AxisServiceBasedMultiLanguageEmitter.emitStub(
> AxisServiceBasedMultiLanguageEmitter.java:497)
>         ... 3 more
>
> I found that the problem is the missing "fault" definition.
> I i try this, it works:
>
> <wsdl:operation name="RefundTransaction">
>     <soap:operation soapAction="RefundTransaction" />
>     <wsdl:input><soap:body use="literal" /></wsdl:input>
>     <wsdl:output><soap:body use="literal" /></wsdl:output>
>     <wsdl:fault name="fault"><soap:fault use="literal"
> name="fault"/></wsdl:fault>
> </wsdl:operation>
>
> Why? AFAIK, this is not mandatory... am i wrong?
> And it would be nice to get a better error message.
>
> thanks in advance!
> Juan
>
> ------------------------------
>
> * This message and any attachments are intended only for the use of the
> addressee and may contain information that is privileged and confidential.
> If the reader of the message is not the intended recipient or an authorized
> representative of the intended recipient, you are hereby notified that any
> dissemination of this communication is strictly prohibited. If you have
> received this communication in error, notify the sender immediately by
> return email and delete the message and any attachments from your system.
> *
>



-- 
José Ferreiro
EPFL Communication Systems engineer
ing.sys.com.dipl.EPFL

Reply via email to