aspose file tools*
The moose likes Web Services and the fly likes Security in Axis 1.4 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » Web Services
Bookmark "Security in Axis 1.4" Watch "Security in Axis 1.4" New topic
Author

Security in Axis 1.4

Ivan Silva
Greenhorn

Joined: Dec 18, 2009
Posts: 10
Hello to all !

I'm trying implement a Simple Security in a Web Service(Axis 1.4). However I can't to isert the Header in Envelop.

Already try follow the exemple in site of WSS4J



or



Follow bellow my request




So, because don't has got the Header I receive the same response from serverI believe in this)






Cheers !!!

Ivan Krizsan
Ranch Hand

Joined: Oct 04, 2006
Posts: 2198
    
    1
Hi!
If that is your entire request, which I doubt, then you are missing a <soap:Header> element, inside which you will place your header elements.
My conclusion is drawn from the fact that the fault says that you have a header, while I see none in the request you submitted.
Headers have a mustUnderstand attribute that indicates whether processing of the header is mandatory or not for the targeted node.
Suggested reading about the structure of SOAP messages: http://www.w3.org/TR/2000/NOTE-SOAP-20000508/#_Toc478383494
...and about the mustUnderstand attribute: http://www.w3.org/TR/2000/NOTE-SOAP-20000508/#_Toc478383500

My suggestions:
Use a packet sniffer, like WireShark, to obtain the real request and inspect it.
Test the service using soapUI to make sure that it can process the kind of requests you want to send to it.
Best wishes!


My free books and tutorials: http://www.slideshare.net/krizsan
Ivan Silva
Greenhorn

Joined: Dec 18, 2009
Posts: 10
Hi!!
Tks for his answer but I believe this is entire request because I got it from TCPMon from Axis. But, tks for his tips!
Ivan Krizsan
Ranch Hand

Joined: Oct 04, 2006
Posts: 2198
    
    1
Well, then, give the service a go with soapUI and see with what kind of request you are able to get a good response!
Ivan Silva
Greenhorn

Joined: Dec 18, 2009
Posts: 10
Hi Krizsan !!

I did download of SoapUI version Open Source and I'm learning how to use the software...... but I was thinking. The WSDL I did generate by Eclipse. Do can be this problem ?




One more time, very very tk YOU!
Ivan Krizsan
Ranch Hand

Joined: Oct 04, 2006
Posts: 2198
    
    1
Hi!
If you want to check the WSDL generated by Eclipse, there are three options that I can think of right now:
  • Use the WS-I Basic Profile confirmance test in soapUI
  • Use NetBeans to develop the web service
  • Use wsimport in JavaSE 6 from an Ant script to generate the WSDL

  • The third option can be used both inside Eclipse and outside of an IDE.
    Having done option two or three, you then compare the WSDL with the one generated in Eclipse.
    Best wishes!
    Ivan Silva
    Greenhorn

    Joined: Dec 18, 2009
    Posts: 10
    Krizan, I chose first option and in report showed that Assertion BP2406 failed. Do you know some plugin to Eclipse to generate the WSDL ? Either I do this with wsiport even. Appear for me that wsimport works fine with JAXB it'll works fine with Axis 1.4 ? Either I have use task for ANT gave with Axis 1.4.

    If I have to use wsimport you have a ample of ANT Task or in case Axis 1.4 an sample of Ant Task.


    Tks!!

    Ivan Krizsan
    Ranch Hand

    Joined: Oct 04, 2006
    Posts: 2198
        
        1
    Hi!
    Sorry, I do not normally use Axis, so I am not familiar with the tooling.
    If you want an Ant task that uses wsimport or wsgen to generate artifacts, there are several examples in the following document:
    http://www.slideshare.net/krizsan/scdjws-5-study-notes-3085287
    Best wishes!
     
    I agree. Here's the link: http://aspose.com/file-tools
     
    subject: Security in Axis 1.4
     
    Similar Threads
    hi there..i hava a problem with the apache axis..
    AXIS and DOM exception
    Not able to invoke webservice
    Error : Axis Engine Cudn't find the target
    Axis Fault: no such operation