Win a copy of Java Persistence with Spring Data and Hibernate this week in the Spring forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Tim Cooke
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • Junilu Lacar
  • Rob Spoor
  • Jeanne Boyarsky
Saloon Keepers:
  • Stephan van Hulst
  • Carey Brown
  • Tim Holloway
  • Piet Souris
Bartenders:

SSL in standalone axis2 1.4.1

 
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

How do I enable SSL on the server side on standalone (no using Tomcat) Axis2 1.4.1 ?

When I try to uncomment the https lines in the axis2.xml i get NullPointerExceptions like:
NullPointerException at org.apache.axis2.transport.nhttp.HttpCoreNIOSSLListener

I cannot find a good tutorial about this.
 
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I am not quite sure if you can switched it on in axis2.xml. But something that woked for me is rampart modules.

You will need to include security modules Rampart along with with Axis 2. Look into http://wso2.org/library/3190#Step_3._Engaging_Rampart_and_setting_authentication_information.
You will also uncomment some code in tomcat/other app server's server.xml.

To follow the tutorial which also talk about user name token authentication, which you may leave out just use the SSL part.
You will need to edit the META-INF/services.xml in server to add these policy. Here Your concern should be which defines ssl, you can remove the which is used for user name token.

 
Aleksander Braula
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I've tried to do that but my problem is that I cannot enable the ssl in axis2.xml

I've uncommented the necessary code:


But when I try to run the server I get

 
samarjit samanta
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I just followed the tutorial as I mentioned earlier. I did not change the axis2.xml for enabling SSL. Also make sure that you enable SSL in tomcat server.xml. You probably need to add rampart jars and modules in your classpath. If you are using rampart also add it to the services.xml in both the places and key store definitions . I used axis 1.5 and rampart 1.5 and it worked.
 
Rancher
Posts: 1337
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Wouldn't you rather be using message-level security (using the WS-Security standard as implemented by the Rampart module) than transport-level security (like SSL)?
 
The moustache of a titan! The ad of a flea:
The Low Tech Laboratory Movie Kickstarter is LIVE NOW!
https://www.kickstarter.com/projects/paulwheaton/low-tech
reply
    Bookmark Topic Watch Topic
  • New Topic