Generating Self-Signed SSL Certs

If you want to have SSL enabled on your webserver, you may want to generate self signed certificates.

  1. cd ~
  2. mkdir ssl
  3. openssl genrsa -des3 -out server.key 4096
  4. openssl req -new -key server.key -out server.csr
  5. openssl x509 -req -days 365 -in server.csr -signkey server.key -out server.crt
  6. openssl rsa -in server.key -out server.key.insecure
  7. mv server.key server.key.secure
  8. mv server.key.insecure server.key

Step 3: Generating the key, use any pass phrase.
Step 4: Creating the certificate signing request
Step 5: Signing the certificate signing request
Step 6: Making a key that has no pass phrase

Note: Ensure that all keys are not readable to others. chmod 700 the ssl directory and chmod 600 all the keys.


To install the key on a litespeed web server

  1. create a new listener, call it for example, ‘secure’
  2. go to the ssl tab and specify the following values:
    1. Private Key File: $SERVER_ROOT/ssl/server.key
    2. Certificate File: $SERVER_ROOT/ssl/server.crt
    3. Chained Certificate: no
    4. CA Certificate Path: $SERVER_ROOT/ssl
    5. CA Certificate File: Not Set
  3. Copy the entire ssl directory generated above to the litespeed server root
  4. Chmod the entire ssl directory to 700, and chmod the keys to 600
  5. Chown/Chgroup the entire ssl directory to the lsadm user

Leave a Reply

Your email address will not be published.