Advertisement
ennio21

Untitled

Feb 29th, 2016
130
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 8.36 KB | None | 0 0
  1. # este código é do arquivo C:\wamp64\bin\apache\apache2.4.17\conf\extra\httpd-ssl.conf
  2. # vem depois da linha 119
  3.  
  4. ##
  5. ## SSL Virtual Host Context
  6. ##
  7.  
  8.  
  9. <VirtualHost _default_:443>
  10.  
  11. # General setup for the virtual host
  12. DocumentRoot "c:/Apache24/htdocs"
  13. ServerName www.example.com:443
  14. ServerAdmin [email protected]
  15. ErrorLog "c:/Apache24/logs/error.log"
  16. TransferLog "c:/Apache24/logs/access.log"
  17.  
  18. # SSL Engine Switch:
  19. # Enable/Disable SSL for this virtual host.
  20. SSLEngine on
  21.  
  22. # Server Certificate:
  23. # Point SSLCertificateFile at a PEM encoded certificate. If
  24. # the certificate is encrypted, then you will be prompted for a
  25. # pass phrase. Note that a kill -HUP will prompt again. Keep
  26. # in mind that if you have both an RSA and a DSA certificate you
  27. # can configure both in parallel (to also allow the use of DSA
  28. # ciphers, etc.)
  29. # Some ECC cipher suites (http://www.ietf.org/rfc/rfc4492.txt)
  30. # require an ECC certificate which can also be configured in
  31. # parallel.
  32. SSLCertificateFile "c:/Apache24/conf/server.crt"
  33. #SSLCertificateFile "c:/Apache24/conf/server-dsa.crt"
  34. #SSLCertificateFile "c:/Apache24/conf/server-ecc.crt"
  35.  
  36. # Server Private Key:
  37. # If the key is not combined with the certificate, use this
  38. # directive to point at the key file. Keep in mind that if
  39. # you've both a RSA and a DSA private key you can configure
  40. # both in parallel (to also allow the use of DSA ciphers, etc.)
  41. # ECC keys, when in use, can also be configured in parallel
  42. SSLCertificateKeyFile "c:/Apache24/conf/server.key"
  43. #SSLCertificateKeyFile "c:/Apache24/conf/server-dsa.key"
  44. #SSLCertificateKeyFile "c:/Apache24/conf/server-ecc.key"
  45.  
  46. # Server Certificate Chain:
  47. # Point SSLCertificateChainFile at a file containing the
  48. # concatenation of PEM encoded CA certificates which form the
  49. # certificate chain for the server certificate. Alternatively
  50. # the referenced file can be the same as SSLCertificateFile
  51. # when the CA certificates are directly appended to the server
  52. # certificate for convenience.
  53. #SSLCertificateChainFile "c:/Apache24/conf/server-ca.crt"
  54.  
  55. # Certificate Authority (CA):
  56. # Set the CA certificate verification path where to find CA
  57. # certificates for client authentication or alternatively one
  58. # huge file containing all of them (file must be PEM encoded)
  59. # Note: Inside SSLCACertificatePath you need hash symlinks
  60. # to point to the certificate files. Use the provided
  61. # Makefile to update the hash symlinks after changes.
  62. #SSLCACertificatePath "c:/Apache24/conf/ssl.crt"
  63. #SSLCACertificateFile "c:/Apache24/conf/ssl.crt/ca-bundle.crt"
  64.  
  65. # Certificate Revocation Lists (CRL):
  66. # Set the CA revocation path where to find CA CRLs for client
  67. # authentication or alternatively one huge file containing all
  68. # of them (file must be PEM encoded).
  69. # The CRL checking mode needs to be configured explicitly
  70. # through SSLCARevocationCheck (defaults to "none" otherwise).
  71. # Note: Inside SSLCARevocationPath you need hash symlinks
  72. # to point to the certificate files. Use the provided
  73. # Makefile to update the hash symlinks after changes.
  74. #SSLCARevocationPath "c:/Apache24/conf/ssl.crl"
  75. #SSLCARevocationFile "c:/Apache24/conf/ssl.crl/ca-bundle.crl"
  76. #SSLCARevocationCheck chain
  77.  
  78. # Client Authentication (Type):
  79. # Client certificate verification type and depth. Types are
  80. # none, optional, require and optional_no_ca. Depth is a
  81. # number which specifies how deeply to verify the certificate
  82. # issuer chain before deciding the certificate is not valid.
  83. #SSLVerifyClient require
  84. #SSLVerifyDepth 10
  85.  
  86. # TLS-SRP mutual authentication:
  87. # Enable TLS-SRP and set the path to the OpenSSL SRP verifier
  88. # file (containing login information for SRP user accounts).
  89. # Requires OpenSSL 1.0.1 or newer. See the mod_ssl FAQ for
  90. # detailed instructions on creating this file. Example:
  91. # "openssl srp -srpvfile c:/Apache24/conf/passwd.srpv -add username"
  92. #SSLSRPVerifierFile "c:/Apache24/conf/passwd.srpv"
  93.  
  94. # Access Control:
  95. # With SSLRequire you can do per-directory access control based
  96. # on arbitrary complex boolean expressions containing server
  97. # variable checks and other lookup directives. The syntax is a
  98. # mixture between C and Perl. See the mod_ssl documentation
  99. # for more details.
  100. #<Location />
  101. #SSLRequire ( %{SSL_CIPHER} !~ m/^(EXP|NULL)/ \
  102. # and %{SSL_CLIENT_S_DN_O} eq "Snake Oil, Ltd." \
  103. # and %{SSL_CLIENT_S_DN_OU} in {"Staff", "CA", "Dev"} \
  104. # and %{TIME_WDAY} >= 1 and %{TIME_WDAY} <= 5 \
  105. # and %{TIME_HOUR} >= 8 and %{TIME_HOUR} <= 20 ) \
  106. # or %{REMOTE_ADDR} =~ m/^192\.76\.162\.[0-9]+$/
  107. #</Location>
  108.  
  109. # SSL Engine Options:
  110. # Set various options for the SSL engine.
  111. # o FakeBasicAuth:
  112. # Translate the client X.509 into a Basic Authorisation. This means that
  113. # the standard Auth/DBMAuth methods can be used for access control. The
  114. # user name is the `one line' version of the client's X.509 certificate.
  115. # Note that no password is obtained from the user. Every entry in the user
  116. # file needs this password: `xxj31ZMTZzkVA'.
  117. # o ExportCertData:
  118. # This exports two additional environment variables: SSL_CLIENT_CERT and
  119. # SSL_SERVER_CERT. These contain the PEM-encoded certificates of the
  120. # server (always existing) and the client (only existing when client
  121. # authentication is used). This can be used to import the certificates
  122. # into CGI scripts.
  123. # o StdEnvVars:
  124. # This exports the standard SSL/TLS related `SSL_*' environment variables.
  125. # Per default this exportation is switched off for performance reasons,
  126. # because the extraction step is an expensive operation and is usually
  127. # useless for serving static content. So one usually enables the
  128. # exportation for CGI and SSI requests only.
  129. # o StrictRequire:
  130. # This denies access when "SSLRequireSSL" or "SSLRequire" applied even
  131. # under a "Satisfy any" situation, i.e. when it applies access is denied
  132. # and no other module can change it.
  133. # o OptRenegotiate:
  134. # This enables optimized SSL connection renegotiation handling when SSL
  135. # directives are used in per-directory context.
  136. #SSLOptions +FakeBasicAuth +ExportCertData +StrictRequire
  137. <FilesMatch "\.(cgi|shtml|phtml|php)$">
  138. SSLOptions +StdEnvVars
  139. </FilesMatch>
  140. <Directory "c:/Apache24/cgi-bin">
  141. SSLOptions +StdEnvVars
  142. </Directory>
  143.  
  144. # SSL Protocol Adjustments:
  145. # The safe and default but still SSL/TLS standard compliant shutdown
  146. # approach is that mod_ssl sends the close notify alert but doesn't wait for
  147. # the close notify alert from client. When you need a different shutdown
  148. # approach you can use one of the following variables:
  149. # o ssl-unclean-shutdown:
  150. # This forces an unclean shutdown when the connection is closed, i.e. no
  151. # SSL close notify alert is sent or allowed to be received. This violates
  152. # the SSL/TLS standard but is needed for some brain-dead browsers. Use
  153. # this when you receive I/O errors because of the standard approach where
  154. # mod_ssl sends the close notify alert.
  155. # o ssl-accurate-shutdown:
  156. # This forces an accurate shutdown when the connection is closed, i.e. a
  157. # SSL close notify alert is send and mod_ssl waits for the close notify
  158. # alert of the client. This is 100% SSL/TLS standard compliant, but in
  159. # practice often causes hanging connections with brain-dead browsers. Use
  160. # this only for browsers where you know that their SSL implementation
  161. # works correctly.
  162. # Notice: Most problems of broken clients are also related to the HTTP
  163. # keep-alive facility, so you usually additionally want to disable
  164. # keep-alive for those clients, too. Use variable "nokeepalive" for this.
  165. # Similarly, one has to force some clients to use HTTP/1.0 to workaround
  166. # their broken HTTP/1.1 implementation. Use variables "downgrade-1.0" and
  167. # "force-response-1.0" for this.
  168. BrowserMatch "MSIE [2-5]" \
  169. nokeepalive ssl-unclean-shutdown \
  170. downgrade-1.0 force-response-1.0
  171.  
  172. # Per-Server Logging:
  173. # The home of a custom SSL log file. Use this when you want a
  174. # compact non-error SSL logfile on a virtual host basis.
  175. CustomLog "c:/Apache24/logs/ssl_request.log" \
  176. "%t %h %{SSL_PROTOCOL}x %{SSL_CIPHER}x \"%r\" %b"
  177.  
  178. </VirtualHost>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement