View

Enable SSL in apache2 on Debian Etch

Note

quick tutorial

  1. # Enable ssl
  2. a2enmod ssl
  3. # Edit /etc/apache2/ports.conf and add “Listen 443”
  4. # Generate certs: use your domain as Common Name or *.domain.tld for multiple domains
  5. openssl req -x509 -nodes -days 365 -newkey rsa:1024 -out /etc/apache2/server.crt -keyout /etc/apache2/server.key
  6. # In the virtualhost, use the following code:
  7. <VirtualHost 192.168.0.1:443>
  8.         SSLEngine On
  9.         SSLCertificateFile /etc/apache2/server.crt
  10.         SSLCertificateKeyFile /etc/apache2/server.key
  11. </VirtualHost>
  12. # Reload apache2
  13. /etc/init.d/apache2 reload

You may also like