Advertisement
Guest User

main apache config

a guest
Jun 18th, 2014
302
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 5.33 KB | None | 0 0
  1. ServerRoot "/etc/httpd"
  2.  
  3. Listen 5000
  4.  
  5. LoadModule authz_host_module modules/mod_authz_host.so
  6. LoadModule include_module modules/mod_include.so
  7. LoadModule filter_module modules/mod_filter.so
  8. LoadModule deflate_module modules/mod_deflate.so
  9. LoadModule log_config_module modules/mod_log_config.so
  10. #LoadModule logio_module modules/mod_logio.so
  11. LoadModule env_module modules/mod_env.so
  12. LoadModule mime_magic_module modules/mod_mime_magic.so
  13. LoadModule headers_module modules/mod_headers.so
  14. LoadModule setenvif_module modules/mod_setenvif.so
  15. LoadModule mime_module modules/mod_mime.so
  16. LoadModule status_module modules/mod_status.so
  17. LoadModule autoindex_module modules/mod_autoindex.so
  18. LoadModule asis_module modules/mod_asis.so
  19. LoadModule cgid_module modules/mod_cgid.so
  20. LoadModule negotiation_module modules/mod_negotiation.so
  21. LoadModule dir_module modules/mod_dir.so
  22. LoadModule actions_module modules/mod_actions.so
  23. LoadModule userdir_module modules/mod_userdir.so
  24. LoadModule alias_module modules/mod_alias.so
  25. LoadModule rewrite_module modules/mod_rewrite.so
  26.  
  27. User root
  28. Group root
  29.  
  30. ServerAdmin admin
  31. ServerName *:5000
  32.  
  33. DocumentRoot "/usr/syno/synoman"
  34. Alias /ssdp /tmp/ssdp
  35.  
  36. <Directory />
  37. Options ExecCGI FollowSymLinks
  38. AllowOverride All
  39. </Directory>
  40.  
  41. <Directory "/usr/syno/synoman">
  42. Options ExecCGI FollowSymLinks MultiViews
  43. AllowOverride All
  44. Order allow,deny
  45. Allow from all
  46. </Directory>
  47.  
  48. <IfModule dir_module>
  49. DirectoryIndex index.html index.htm index.cgi
  50. </IfModule>
  51.  
  52. <FilesMatch "^\.ht">
  53. Order allow,deny
  54. Deny from all
  55. Satisfy All
  56. </FilesMatch>
  57.  
  58. ErrorLog /var/log/httpd/sys-error_log
  59. #ErrorLog /dev/null
  60. TraceEnable off
  61.  
  62. LogLevel error
  63.  
  64. <IfModule log_config_module>
  65. LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined
  66. LogFormat "%h %l %u %t \"%r\" %>s %b" common
  67.  
  68. <IfModule logio_module>
  69. LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio
  70. </IfModule>
  71.  
  72. CustomLog /dev/null combined
  73. #CustomLog /var/log/httpd/sys-access_log combined
  74. </IfModule>
  75.  
  76. <IfModule alias_module>
  77. Alias /wfmlogindialog.js /usr/syno/synoman/webfm/webUI/directlogin.js
  78. </IfModule>
  79.  
  80. ScriptSock /run/httpd/sys-cgisock
  81. ScriptLog /var/log/httpd/sys-cgi_log
  82.  
  83. DefaultType text/plain
  84.  
  85. <IfModule mime_module>
  86. TypesConfig conf/mime.types
  87. AddEncoding x-compress Z
  88. AddEncoding x-gzip gz tgz
  89. AddType application/x-compress .Z
  90. AddType application/x-gzip .gz .tgz
  91. AddType image/x-icon .ico
  92. AddHandler cgi-script .cgi
  93. </IfModule>
  94.  
  95. MIMEMagicFile conf/magic
  96.  
  97. ErrorDocument 500 /error.cgi?status=500
  98. ErrorDocument 404 /error.cgi?status=404
  99. ErrorDocument 403 /error.cgi?status=403
  100.  
  101. EnableMMAP off
  102.  
  103. Include conf/extra/httpd-mpm.conf-sys
  104. Include conf/extra/httpd-autoindex.conf-sys
  105. Include conf/extra/httpd-languages.conf-sys
  106. Include conf/extra/httpd-default.conf-sys
  107.  
  108. <IfDefine SSL>
  109. <IfDefine !SPDY>
  110. LoadModule ssl_module modules/mod_ssl.so
  111. Include conf/extra/httpd-ssl.conf-sys
  112. </IfDefine>
  113. <IfDefine SPDY>
  114. LoadModule ssl_module modules/mod_ssl_npn.so
  115. Include conf/extra/httpd-ssl.conf-sys
  116. Include conf/extra/mod_spdy.conf
  117. </IfDefine>
  118. </IfDefine>
  119.  
  120. <IfModule deflate_module>
  121. DeflateCompressionLevel 2
  122. AddOutputFilterByType DEFLATE text/html text/plain text/xml
  123. AddOutputFilter DEFLATE js css
  124. BrowserMatch ^Mozilla/4 gzip-only-text/html
  125. BrowserMatch ^Mozilla/4\.[0678] no-gzip
  126. BrowserMatch \bMSIE\s7 !no-gzip !gzip-only-text/html
  127. </IfModule>
  128.  
  129. <Files *.js>
  130. Header unset Etag
  131. </Files>
  132.  
  133. <Files *.css>
  134. Header unset Etag
  135. </Files>
  136.  
  137. # For CVE-2003-1418
  138. FileETag MTime Size
  139.  
  140. <IfDefine REDIRECT_USER>
  141. Listen 80
  142. <VirtualHost *:80>
  143. RewriteEngine on
  144. RewriteRule ^/(.*)$ /usr/syno/synoman/redirect.cgi?5000
  145. </VirtualHost>
  146. </IfDefine>
  147.  
  148. <IfDefine !DEFAULT_SETTING>
  149. Include sites-enabled/*.legacy.conf
  150. Include sites-enabled/*.alt_port.conf
  151. Include sites-enabled/*.alias.conf
  152.  
  153. <IfDefine SSL>
  154. Include sites-enabled/*.alt_port_ssl.conf
  155. </IfDefine>
  156. </IfDefine>
  157.  
  158. <IfModule rewrite_module>
  159. Include conf/extra/*demo-site.conf
  160.  
  161. RewriteEngine on
  162. RewriteRule ^/viewer/(.*)/(.*)/(.*)/(.*) /usr/syno/synoman/webfm/webUI/file_download.cgi?dlink=$1&_sid=$2&SynoToken=$3&ip=false&api=SYNO.FileStation.Download&version=1&method=download&mode=open&stdhtml=true [QSA,L]
  163. RewriteRule ^/fbsharing/(.*) /usr/syno/synoman/webfm/webUI/file_download.cgi?key=$1&api=SYNO.FileStation.Download&version=1&method=download&mode=download&stdhtml=true [QSA,L]
  164. RewriteRule ^/fbdownload/(.*) /usr/syno/synoman/webfm/webUI/file_download.cgi?api=SYNO.FileStation.Download&version=1&method=download&mode=download&stdhtml=true [QSA,L]
  165.  
  166. # wfmdownload rule is for old version compatibility
  167. RewriteRule ^/wfmdownload/(.*) /usr/syno/synoman/webfm/webUI/file_download.cgi?api=SYNO.FileStation.Download&version=1&method=download&mode=download&stdhtml=true [QSA,L]
  168. RewriteRule ^/dar/(.*) /usr/syno/synoman/webman/modules/SystemInfoApp/DataAnalysis.cgi?path=$1 [QSA,L]
  169. </IfModule>
  170.  
  171. <IfDefine FrameOptions>
  172. Include conf/extra/httpd-frameOptions.conf-sys
  173. </IfDefine>
  174.  
  175. include conf/extra/mod_xsendfile.conf-sys
  176. Include conf/extra/httpd-reqtimeout.conf
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement