Advertisement
Guest User

Untitled

a guest
May 10th, 2016
51
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 4.27 KB | None | 0 0
  1. # mailcow site configuration
  2. # ! Do not remove this header !
  3.  
  4. SSLStaplingCache "shmcb:logs/stapling-cache(150000)"
  5.  
  6. <VirtualHost *:80>
  7. ServerSignature off
  8. TraceEnable off
  9. AddDefaultCharset utf-8
  10. ServerName "mail.domain.tld"
  11. DocumentRoot /var/www/mail
  12. RewriteEngine On
  13. RewriteCond %{HTTPS} !=on
  14. RewriteRule ^/?(.*) https://%{HTTP_HOST}/$1 [L,R,NE]
  15. </VirtualHost>
  16. <IfModule mod_ssl.c>
  17. <VirtualHost *:443>
  18. ServerSignature off
  19. TraceEnable off
  20. AddDefaultCharset utf-8
  21. ServerName "mail.domain.tld"
  22. DocumentRoot /var/www/mail
  23. ErrorLog ${APACHE_LOG_DIR}/error.log
  24. CustomLog ${APACHE_LOG_DIR}/access.log combined
  25. SSLEngine on
  26. SSLCertificateFile /etc/letsencrypt/live/mail.domain.tld/fullchain.pem
  27. SSLCertificateKeyFile /etc/letsencrypt/live/mail.domain.tld/privkey.pem
  28. ErrorDocument 503 /admin.php
  29. php_value upload_max_filesize 25M
  30. php_value post_max_size 26M
  31. ErrorDocument 500 /admin.php
  32. <FilesMatch "\.(cgi|shtml|phtml|php)$">
  33. SSLOptions +StdEnvVars
  34. </FilesMatch>
  35. BrowserMatch "MSIE [2-6]" \
  36. nokeepalive ssl-unclean-shutdown \
  37. downgrade-1.0 force-response-1.0
  38. BrowserMatch "MSIE [17-9]" ssl-unclean-shutdown
  39. SSLProtocol All -SSLv2 -SSLv3
  40. SSLHonorCipherOrder On
  41. Header always set Strict-Transport-Security "max-age=63072000; includeSubdomains; preload"
  42. Header always set X-Frame-Options DENY
  43. Header always set X-Content-Type-Options nosniff
  44. SSLCompression off
  45. SSLUseStapling on
  46. </VirtualHost>
  47. <VirtualHost *:443>
  48. ServerSignature off
  49. TraceEnable off
  50. AddDefaultCharset utf-8
  51. ServerName "dav.domain.tld"
  52. DocumentRoot /var/www/dav
  53. ErrorLog ${APACHE_LOG_DIR}/error.log
  54. CustomLog ${APACHE_LOG_DIR}/access.log combined
  55. RewriteEngine on
  56. RewriteRule ^/(.*)$ /server.php [L]
  57. php_flag output_buffering off
  58. php_flag always_populate_raw_post_data off
  59. php_flag magic_quotes_gpc off
  60. php_flag mbstring.func_overload off
  61. php_value date.timezone Europe/Berlin
  62. DirectoryIndex server.php
  63. SSLEngine on
  64. SSLCertificateFile /etc/ssl/mail/mail.crt
  65. SSLCertificateKeyFile /etc/ssl/mail/mail.key
  66. <FilesMatch "\.(cgi|shtml|phtml|php)$">
  67. SSLOptions +StdEnvVars
  68. </FilesMatch>
  69. BrowserMatch "MSIE [2-6]" \
  70. nokeepalive ssl-unclean-shutdown \
  71. downgrade-1.0 force-response-1.0
  72. BrowserMatch "MSIE [17-9]" ssl-unclean-shutdown
  73. SSLProtocol All -SSLv2 -SSLv3
  74. SSLHonorCipherOrder On
  75. Header always set Strict-Transport-Security "max-age=63072000; includeSubdomains; preload"
  76. Header always set X-Frame-Options DENY
  77. Header always set X-Content-Type-Options nosniff
  78. SSLCompression off
  79. SSLUseStapling on
  80. </VirtualHost>
  81. <VirtualHost *:443>
  82. ServerSignature off
  83. TraceEnable off
  84. AddDefaultCharset utf-8
  85. ServerName "autodiscover.domain.tld"
  86. DocumentRoot /var/www/zpush
  87. <Directory /var/www/zpush>
  88. Options -Indexes +FollowSymLinks
  89. php_value register_globals off
  90. php_value magic_quotes_gpc off
  91. php_value magic_quotes_runtime off
  92. php_value short_open_tag on
  93. php_value allow_call_time_pass_reference on
  94. php_value date.timezone Europe/Berlin
  95. php_value max_execution_time 650
  96. </Directory>
  97. ErrorLog ${APACHE_LOG_DIR}/error.log
  98. CustomLog ${APACHE_LOG_DIR}/access.log combined
  99. AliasMatch "(?i)^/Autodiscover/Autodiscover.xml" "/var/www/zpush/autodiscover/autodiscover.php"
  100. AliasMatch "(?i)^/Microsoft-Server-ActiveSync" "/var/www/zpush/index.php"
  101. Alias /autodiscover/autodiscover.xml "/var/www/zpush/autodiscover/autodiscover.php"
  102. DirectoryIndex index.php
  103. SSLEngine on
  104. SSLCertificateFile /etc/ssl/mail/mail.crt
  105. SSLCertificateKeyFile /etc/ssl/mail/mail.key
  106. <FilesMatch "\.(cgi|shtml|phtml|php)$">
  107. SSLOptions +StdEnvVars
  108. </FilesMatch>
  109. BrowserMatch "MSIE [2-6]" \
  110. nokeepalive ssl-unclean-shutdown \
  111. downgrade-1.0 force-response-1.0
  112. BrowserMatch "MSIE [17-9]" ssl-unclean-shutdown
  113. SSLProtocol All -SSLv2 -SSLv3
  114. SSLHonorCipherOrder On
  115. Header always set Strict-Transport-Security "max-age=63072000; includeSubdomains; preload"
  116. Header always set X-Frame-Options DENY
  117. Header always set X-Content-Type-Options nosniff
  118. SSLCompression off
  119. SSLUseStapling on
  120. </VirtualHost>
  121. </IfModule>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement