Https

From Attie's Wiki
Jump to: navigation, search

Contents

How-to setup SSL with Apache

Generate a certificate

  1. Generate a private key
  2. Generate a CSR (Certificate Sining Request)
  3. Backup passphrase protected key
  4. Remove passphrase from key
  5. Generate a self signed certificate
$ openssl genrsa -des3 -out server.key 1024
$ openssl req -new -key server.key -out server.csr
$ cp server.key server.key.org
$ openssl rsa -in server.key.org -out server.key
$ openssl x509 -req -days 365 -in server.csr -signkey server.key -out server.crt

Configure Apache

In the VirtualHost or similar, put:

SSLEngine on
SSLCertificateFile .../server.crt
SSLCertificateKeyFile .../server.key
SetEnvIf User-Agent ".*MSIE.*" nokeepalive ssl-unclean-shutdown
CustomLog logs/ssl_request_log "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"

For Windows

http://www.jayway.com/2014/09/03/creating-self-signed-certificates-with-makecert-exe-for-development/

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox