My favorites | Sign in
Project Home Downloads Wiki Issues Source
Search
for
EnableSSLJBossAS  
Explains how to enable SSL on JBoss AS 4.2.x
Featured
Updated Feb 4, 2010 by dan.j.allen

Introduction

In order to use the HTTPS sheme in Seam, you have to first enable JBoss AS to accept HTTP connections over SSL. This page describes the necessary steps using a self-signed certificate.

Details

In this example I'm only using a self-signed certificate, but the procedure would be more or less the same even if you are going to use a certificate from a Certification Authority.

  1. Generate the keystore using the command below. For the most part, you can just make up stuff for the responses. However, remember the password you provide and use the same password for the keystore and the key. When it asks for your first and last name, you should enter the hostname used for JBoss AS (i.e., localhost).
  2. keytool -genkey -keyalg RSA -keystore jbossas.keystore -validity NUMBER_OF_DAYS
  3. Move the generated file the conf directory of the JBoss AS default domain (or the one you are using):
  4. mv jbossas.keystore ${jboss.home}/server/default/conf/
  5. Open the file ${jboss.home}/server/default/deploy/jboss-web.deployer/server.xml in your editor, remove the XML comment around the SSL-connector, and modify the attributes to match the configuration shown here:
  6. <Connector port="8443" protocol="HTTP/1.1" SSLEnabled="true"
               maxThreads="150" scheme="https" secure="true"
               clientAuth="false" sslProtocol="TLS" address="${jboss.bind.address}"
               keystoreFile="${jboss.server.home.dir}/conf/jbossas.keystore"
               keystorePass="PASSWORD_FOR_KEYSTORE"/>
  7. Now you should be able to access your application through https. The URL will begin with https instead of http and you need to include the port number if the port you provided in the configuration is anything other than 443:
  8. https://localhost:8443

Additional Resources

Check out the JBoss Wiki for all the details about using SSL with JBoss AS: http://wiki.jboss.org/wiki/SSLSetup

Comment by hardik.r...@gmail.com, Jul 3, 2009

yeah its enable us to hit URL with https. But it also allows to hit with http.

Comment by shanelee...@gmail.com, Apr 14, 2010
Comment by shanelee...@gmail.com, Apr 14, 2010

jboss 5 web deployer is configured from deploy/jbossweb.sar/server.xml


Sign in to add a comment
Powered by Google Project Hosting