I followed the following steps to enable the SSL for my web application in JBoss AS 4.2,
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). keytool -genkey -keyalg RSA -keystore jbossas.keystore -validity NUMBER_OF_DAYS 2. Move the generated file the conf directory of the JBoss AS default domain (or the one you are using): mv jbossas.keystore ${jboss.home}/server/default/conf/ 3. 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: <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"/> 4. 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: https://localhost:8443