Advertisement
Guest User

Untitled

a guest
Aug 10th, 2017
562
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 6.14 KB | None | 0 0
  1. <IfModule mod_ssl.c>
  2. <VirtualHost _default_:443>
  3. ServerAdmin address@email.com
  4. #ServerName MYSITE.com
  5. #ServerAlias www.MYSITE.com
  6. DocumentRoot /var/www/html
  7.  
  8. #<Directory /var/www/html/> # add FULL directory path
  9. # Options FollowSymLinks
  10. # AllowOverride All # change NONE to ALL
  11. #</Directory>
  12.  
  13. ErrorLog ${APACHE_LOG_DIR}/error.log
  14. CustomLog ${APACHE_LOG_DIR}/access.log combined
  15.  
  16. # SSL Engine Switch:
  17. # Enable/Disable SSL for this virtual host.
  18. SSLEngine on
  19.  
  20. # A self-signed (snakeoil) certificate can be created by installing
  21. # the ssl-cert package. See
  22. # /usr/share/doc/apache2/README.Debian.gz for more info.
  23. # If both key and certificate are stored in the same file, only the
  24. # SSLCertificateFile directive is needed.
  25. SSLCertificateFile /etc/letsencrypt/live/MYSITE.com/fullchain.pem
  26. SSLCertificateKeyFile /etc/letsencrypt/live/MYSITE.com/privkey.pem
  27.  
  28. # Server Certificate Chain:
  29. # Point SSLCertificateChainFile at a file containing the
  30. # concatenation of PEM encoded CA certificates which form the
  31. # certificate chain for the server certificate. Alternatively
  32. # the referenced file can be the same as SSLCertificateFile
  33. # when the CA certificates are directly appended to the server
  34. # certificate for convinience.
  35. #SSLCertificateChainFile /etc/apache2/ssl.crt/server-ca.crt
  36.  
  37. # Certificate Authority (CA):
  38. # Set the CA certificate verification path where to find CA
  39. # certificates for client authentication or alternatively one
  40. # huge file containing all of them (file must be PEM encoded)
  41. # Note: Inside SSLCACertificatePath you need hash symlinks
  42. # to point to the certificate files. Use the provided
  43. # Makefile to update the hash symlinks after changes.
  44. #SSLCACertificatePath /etc/ssl/certs/
  45. #SSLCACertificateFile /etc/apache2/ssl.crt/ca-bundle.crt
  46.  
  47. # Certificate Revocation Lists (CRL):
  48. # Set the CA revocation path where to find CA CRLs for client
  49. # authentication or alternatively one huge file containing all
  50. # of them (file must be PEM encoded)
  51. # Note: Inside SSLCARevocationPath you need hash symlinks
  52. # to point to the certificate files. Use the provided
  53. # Makefile to update the hash symlinks after changes.
  54. #SSLCARevocationPath /etc/apache2/ssl.crl/
  55. #SSLCARevocationFile /etc/apache2/ssl.crl/ca-bundle.crl
  56.  
  57. # Client Authentication (Type):
  58. # Client certificate verification type and depth. Types are
  59. # none, optional, require and optional_no_ca. Depth is a
  60. # number which specifies how deeply to verify the certificate
  61. # issuer chain before deciding the certificate is not valid.
  62. #SSLVerifyClient require
  63. #SSLVerifyDepth 10
  64.  
  65. # SSL Engine Options:
  66. # Set various options for the SSL engine.
  67. # o FakeBasicAuth:
  68. # Translate the client X.509 into a Basic Authorisation. This means that
  69. # the standard Auth/DBMAuth methods can be used for access control. The
  70. # user name is the `one line' version of the client's X.509 certificate.
  71. # Note that no password is obtained from the user. Every entry in the user
  72. # file needs this password: `xxj31ZMTZzkVA'.
  73. # o ExportCertData:
  74. # This exports two additional environment variables: SSL_CLIENT_CERT and
  75. # SSL_SERVER_CERT. These contain the PEM-encoded certificates of the
  76. # server (always existing) and the client (only existing when client
  77. # authentication is used). This can be used to import the certificates
  78. # into CGI scripts.
  79. # o StdEnvVars:
  80. # This exports the standard SSL/TLS related `SSL_*' environment variables.
  81. # Per default this exportation is switched off for performance reasons,
  82. # because the extraction step is an expensive operation and is usually
  83. # useless for serving static content. So one usually enables the
  84. # exportation for CGI and SSI requests only.
  85. # o OptRenegotiate:
  86. # This enables optimized SSL connection renegotiation handling when SSL
  87. # directives are used in per-directory context.
  88. #SSLOptions +FakeBasicAuth +ExportCertData +StrictRequire
  89. <FilesMatch "\.(cgi|shtml|phtml|php)$">
  90. SSLOptions +StdEnvVars
  91. </FilesMatch>
  92. <Directory /usr/lib/cgi-bin>
  93. SSLOptions +StdEnvVars
  94. </Directory>
  95.  
  96. # SSL Protocol Adjustments:
  97. # The safe and default but still SSL/TLS standard compliant shutdown
  98. # approach is that mod_ssl sends the close notify alert but doesn't wait for
  99. # the close notify alert from client. When you need a different shutdown
  100. # approach you can use one of the following variables:
  101. # o ssl-unclean-shutdown:
  102. # This forces an unclean shutdown when the connection is closed, i.e. no
  103. # SSL close notify alert is send or allowed to received. This violates
  104. # the SSL/TLS standard but is needed for some brain-dead browsers. Use
  105. # this when you receive I/O errors because of the standard approach where
  106. # mod_ssl sends the close notify alert.
  107. # o ssl-accurate-shutdown:
  108. # This forces an accurate shutdown when the connection is closed, i.e. a
  109. # SSL close notify alert is send and mod_ssl waits for the close notify
  110. # alert of the client. This is 100% SSL/TLS standard compliant, but in
  111. # practice often causes hanging connections with brain-dead browsers. Use
  112. # this only for browsers where you know that their SSL implementation
  113. # works correctly.
  114. # Notice: Most problems of broken clients are also related to the HTTP
  115. # keep-alive facility, so you usually additionally want to disable
  116. # keep-alive for those clients, too. Use variable "nokeepalive" for this.
  117. # Similarly, one has to force some clients to use HTTP/1.0 to workaround
  118. # their broken HTTP/1.1 implementation. Use variables "downgrade-1.0" and
  119. # "force-response-1.0" for this.
  120. # BrowserMatch "MSIE [2-6]" \
  121. # nokeepalive ssl-unclean-shutdown \
  122. # downgrade-1.0 force-response-1.0
  123.  
  124. </VirtualHost>
  125. </IfModule>
  126.  
  127. # vim: syntax=apache ts=4 sw=4 sts=4 sr noet
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement