Gentoo Archives: gentoo-commits

From: Joonas Niilola <juippis@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: www-servers/lighttpd/files/conf/
Date: Tue, 01 Feb 2022 08:17:21
Message-Id: 1643703426.023462dda2e20598697775f4e731d0b16096be4c.juippis@gentoo
1 commit: 023462dda2e20598697775f4e731d0b16096be4c
2 Author: Mohamad Issawi <68k <AT> segv <DOT> moe>
3 AuthorDate: Wed Jan 5 06:58:38 2022 +0000
4 Commit: Joonas Niilola <juippis <AT> gentoo <DOT> org>
5 CommitDate: Tue Feb 1 08:17:06 2022 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=023462dd
7
8 www-servers/lighttpd: clean up config files
9
10 cleaned up the formatting of the default config files to match the style
11 used by the lighttpd project.
12
13 Package-Manager: Portage-3.0.30, Repoman-3.0.3
14 Signed-off-by: Mohamad Issawi <68k <AT> segv.moe>
15 Closes: https://github.com/gentoo/gentoo/pull/23655
16 Signed-off-by: Joonas Niilola <juippis <AT> gentoo.org>
17
18 www-servers/lighttpd/files/conf/lighttpd.conf | 366 ++++++++++-------------
19 www-servers/lighttpd/files/conf/mime-types.conf | 328 ++++++++++----------
20 www-servers/lighttpd/files/conf/mod_cgi.conf | 28 +-
21 www-servers/lighttpd/files/conf/mod_fastcgi.conf | 17 +-
22 4 files changed, 339 insertions(+), 400 deletions(-)
23
24 diff --git a/www-servers/lighttpd/files/conf/lighttpd.conf b/www-servers/lighttpd/files/conf/lighttpd.conf
25 index 2a13a57c1c8d..13d5e772ac1b 100644
26 --- a/www-servers/lighttpd/files/conf/lighttpd.conf
27 +++ b/www-servers/lighttpd/files/conf/lighttpd.conf
28 @@ -2,67 +2,67 @@
29 # Default lighttpd.conf for Gentoo.
30 ###############################################################################
31
32 -# {{{ variables
33 -var.basedir = "/var/www/localhost"
34 -var.logdir = "/var/log/lighttpd"
35 +# Variables
36 +var.basedir = "/var/www/localhost"
37 +var.logdir = "/var/log/lighttpd"
38 var.statedir = "/var/lib/lighttpd"
39 -# }}}
40
41 -# {{{ modules
42 +
43 +# Modules
44 # At the very least, mod_access and mod_accesslog should be enabled.
45 # All other modules should only be loaded if necessary.
46 # NOTE: the order of modules is important.
47 server.modules = (
48 -# "mod_rewrite",
49 -# "mod_redirect",
50 -# "mod_alias",
51 - "mod_access",
52 -# "mod_cml",
53 -# "mod_trigger_b4_dl",
54 -# "mod_auth",
55 -# "mod_status",
56 -# "mod_setenv",
57 -# "mod_proxy",
58 -# "mod_simple_vhost",
59 -# "mod_evhost",
60 -# "mod_userdir",
61 -# "mod_compress",
62 -# "mod_ssi",
63 -# "mod_usertrack",
64 -# "mod_expire",
65 -# "mod_secdownload",
66 -# "mod_rrdtool",
67 -# "mod_webdav",
68 - "mod_accesslog"
69 +# "mod_rewrite",
70 +# "mod_redirect",
71 +# "mod_alias",
72 + "mod_access",
73 +# "mod_cml",
74 +# "mod_trigger_b4_dl",
75 +# "mod_auth",
76 +# "mod_status",
77 +# "mod_setenv",
78 +# "mod_proxy",
79 +# "mod_simple_vhost",
80 +# "mod_evhost",
81 +# "mod_userdir",
82 +# "mod_compress",
83 +# "mod_ssi",
84 +# "mod_usertrack",
85 +# "mod_expire",
86 +# "mod_secdownload",
87 +# "mod_rrdtool",
88 +# "mod_webdav",
89 + "mod_accesslog"
90 )
91 -# }}}
92
93 -# {{{ includes
94 +
95 +# Includes
96 include "mime-types.conf"
97 -# fcgi and cgi are included below
98 -# }}}
99 +# include "mod_cgi.conf"
100 +# include "mod_fastcgi.conf"
101
102 -# {{{ server settings
103 -server.username = "lighttpd"
104 -server.groupname = "lighttpd"
105
106 +# Server Settings
107 +server.username = "lighttpd"
108 +server.groupname = "lighttpd"
109 server.document-root = var.basedir + "/htdocs"
110 -server.pid-file = "/run/lighttpd.pid"
111 -
112 -server.errorlog = var.logdir + "/error.log"
113 +server.pid-file = "/run/lighttpd.pid"
114 +server.errorlog = var.logdir + "/error.log"
115 # log errors to syslog instead
116 -# server.errorlog-use-syslog = "enable"
117 -
118 -server.indexfiles = ("index.php", "index.html",
119 - "index.htm", "default.htm")
120 -
121 -# server.tag = "lighttpd"
122 -
123 +# server.errorlog-use-syslog = "enable"
124 +server.indexfiles = (
125 + "index.php",
126 + "index.html",
127 + "index.htm",
128 + "default.htm"
129 +)
130 +# server.tag = "lighttpd"
131 server.follow-symlink = "enable"
132
133 # event handler (defaults to "poll")
134 # see performance.txt
135 -#
136 +
137 # for >= linux-2.4
138 # server.event-handler = "linux-rtsig"
139 # for >= linux-2.6
140 @@ -71,13 +71,13 @@ server.follow-symlink = "enable"
141 # server.event-handler = "freebsd-kqueue"
142
143 # chroot to directory (defaults to no chroot)
144 -# server.chroot = "/"
145 +# server.chroot = "/"
146
147 # bind to port (defaults to 80)
148 -# server.port = 81
149 +# server.port = 81
150
151 # bind to name (defaults to all interfaces)
152 -# server.bind = "grisu.home.kneschke.de"
153 +# server.bind = "grisu.home.kneschke.de"
154
155 # error-handler for status 404
156 # server.error-handler-404 = "/error-handler.html"
157 @@ -85,157 +85,130 @@ server.follow-symlink = "enable"
158
159 # Format: <errorfile-prefix><status-code>.html
160 # -> ..../status-404.html for 'File not found'
161 -# server.errorfile-prefix = var.basedir + "/error/status-"
162 +# server.errorfile-prefix = var.basedir + "/error/status-"
163
164 # FAM support for caching stat() calls
165 # requires that lighttpd be built with USE=fam
166 -# server.stat-cache-engine = "fam"
167 +# server.stat-cache-engine = "fam"
168
169 # If lighttpd was build with IPv6 support, and you would like to listen on IPv6,
170 # uncomment the following:
171 # server.use-ipv6 = "enable"
172
173 -# }}}
174 -
175 -# {{{ mod_staticfile
176
177 +# mod_staticfile
178 # which extensions should not be handled via static-file transfer
179 # (extensions that are usually handled by mod_cgi, mod_fastcgi, etc).
180 static-file.exclude-extensions = (".php", ".pl", ".cgi", ".fcgi")
181 -# }}}
182
183 -# {{{ mod_accesslog
184 +
185 +# mod_accesslog
186 accesslog.filename = var.logdir + "/access.log"
187 -# }}}
188
189 -# {{{ mod_dirlisting
190 +
191 +# mod_dirlisting
192 # enable directory listings
193 -# dir-listing.activate = "enable"
194 -#
195 +# dir-listing.activate = "enable"
196 +
197 # don't list hidden files/directories
198 -# dir-listing.hide-dotfiles = "enable"
199 -#
200 +# dir-listing.hide-dotfiles = "enable"
201 +
202 # use a different css for directory listings
203 -# dir-listing.external-css = "/path/to/dir-listing.css"
204 -#
205 -# list of regular expressions. files that match any of the
206 +# dir-listing.external-css= "/path/to/dir-listing.css"
207 +
208 +# list of regular expressions. Files that match any of the
209 # specified regular expressions will be excluded from directory
210 # listings.
211 -# dir-listing.exclude = ("^\.", "~$")
212 -# }}}
213 +# dir-listing.exclude = ("^\.", "~$")
214
215 -# {{{ mod_access
216 -# see access.txt
217
218 +# mod_access
219 url.access-deny = ("~", ".inc")
220 -# }}}
221
222 -# {{{ mod_userdir
223 -# see userdir.txt
224 -#
225 +
226 +# mod_userdir
227 # userdir.path = "public_html"
228 # userdir.exclude-user = ("root")
229 -# }}}
230
231 -# {{{ mod_ssi
232 -# see ssi.txt
233 -#
234 +
235 +# mod_ssi
236 # ssi.extension = (".shtml")
237 -# }}}
238 -
239 -# {{{ mod_ssl
240 -# see ssl.txt
241 -#
242 -# ssl.engine = "enable"
243 -# ssl.pemfile = "server.pem"
244 -# }}}
245 -
246 -# {{{ mod_status
247 -# see status.txt
248 -#
249 +
250 +
251 +# mod_ssl
252 +# ssl.engine = "enable"
253 +# ssl.pemfile = "server.pem"
254 +
255 +
256 +# mod_status
257 # status.status-url = "/server-status"
258 # status.config-url = "/server-config"
259 -# }}}
260 -
261 -# {{{ mod_simple_vhost
262 -# see simple-vhost.txt
263 -#
264 -# If you want name-based virtual hosting add the next three settings and load
265 -# mod_simple_vhost
266 -#
267 +
268 +
269 +# mod_simple_vhost
270 +# If you want name-based virtual hosting add the next three settings
271 +# and load mod_simple_vhost
272 # document-root =
273 # virtual-server-root + virtual-server-default-host + virtual-server-docroot
274 # or
275 # virtual-server-root + http-host + virtual-server-docroot
276 -#
277 -# simple-vhost.server-root = "/home/weigon/wwwroot/servers/"
278 -# simple-vhost.default-host = "grisu.home.kneschke.de"
279 +# simple-vhost.server-root = "/home/user/webroot/servers/"
280 +# simple-vhost.default-host = "www.example.org"
281 # simple-vhost.document-root = "/pages/"
282 -# }}}
283 -
284 -# {{{ mod_compress
285 -# see compress.txt
286 -#
287 -# compress.cache-dir = var.statedir + "/cache/compress"
288 -# compress.filetype = ("text/plain", "text/html")
289 -# }}}
290 -
291 -# {{{ mod_proxy
292 -# see proxy.txt
293 -#
294 -# proxy.server = ( ".php" =>
295 -# ( "localhost" =>
296 -# (
297 -# "host" => "192.168.0.101",
298 -# "port" => 80
299 -# )
300 -# )
301 -# )
302 -# }}}
303 -
304 -# {{{ mod_auth
305 -# see authentication.txt
306 -#
307 -# auth.backend = "plain"
308 +
309 +
310 +# mod_compress
311 +# compress.cache-dir = var.statedir + "/cache/compress"
312 +# compress.filetype = ("text/plain", "text/html")
313 +
314 +
315 +# mod_proxy
316 +# proxy.server = (
317 +# ".php" => (
318 +# "localhost" => (
319 +# "host" => "192.168.0.101",
320 +# "port" => 80
321 +# )
322 +# )
323 +# )
324 +
325 +
326 +# mod_auth
327 +# auth.backend = "plain"
328 # auth.backend.plain.userfile = "lighttpd.user"
329 # auth.backend.plain.groupfile = "lighttpd.group"
330
331 # auth.backend.ldap.hostname = "localhost"
332 -# auth.backend.ldap.base-dn = "dc=my-domain,dc=com"
333 -# auth.backend.ldap.filter = "(uid=$)"
334 -
335 -# auth.require = ( "/server-status" =>
336 -# (
337 -# "method" => "digest",
338 -# "realm" => "download archiv",
339 -# "require" => "user=jan"
340 -# ),
341 -# "/server-info" =>
342 -# (
343 -# "method" => "digest",
344 -# "realm" => "download archiv",
345 -# "require" => "valid-user"
346 -# )
347 -# )
348 -# }}}
349 -
350 -# {{{ mod_rewrite
351 -# see rewrite.txt
352 -#
353 +# auth.backend.ldap.base-dn = "dc=my-domain,dc=com"
354 +# auth.backend.ldap.filter = "(uid=$)"
355 +
356 +#auth.require = (
357 +# "/server-status" => (
358 +# "method" => "digest",
359 +# "realm" => "download archiv",
360 +# "require" => "user=jan"
361 +# ),
362 +# "/server-info" => (
363 +# "method" => "digest",
364 +# "realm" => "download archiv",
365 +# "require" => "valid-user"
366 +# )
367 +#)
368 +
369 +
370 +# mod_rewrite
371 # url.rewrite = (
372 -# "^/$" => "/server-status"
373 +# "^/$" => "/server-status"
374 # )
375 -# }}}
376
377 -# {{{ mod_redirect
378 -# see redirect.txt
379 -#
380 +
381 +# mod_redirect
382 # url.redirect = (
383 -# "^/wishlist/(.+)" => "http://www.123.org/$1"
384 +# "^/wishlist/(.+)" => "http://www.123.org/$1"
385 # )
386 -# }}}
387
388 -# {{{ mod_evhost
389 +
390 +# mod_evhost
391 # define a pattern for the host url finding
392 # %% => % sign
393 # %0 => domain name + tld
394 @@ -243,87 +216,64 @@ url.access-deny = ("~", ".inc")
395 # %2 => domain name without tld
396 # %3 => subdomain 1 name
397 # %4 => subdomain 2 name
398 -#
399 -# evhost.path-pattern = "/home/storage/dev/www/%3/htdocs/"
400 -# }}}
401 +# evhost.path-pattern = "/home/storage/dev/www/%3/htdocs/"
402
403 -# {{{ mod_expire
404 +
405 +# mod_expire
406 # expire.url = (
407 -# "/buggy/" => "access 2 hours",
408 -# "/asdhas/" => "access plus 1 seconds 2 minutes"
409 +# "/buggy/" => "access 2 hours",
410 +# "/asdhas/" => "access plus 1 seconds 2 minutes"
411 # )
412 -# }}}
413
414 -# {{{ mod_rrdtool
415 -# see rrdtool.txt
416 -#
417 -# rrdtool.binary = "/usr/bin/rrdtool"
418 +
419 +# mod_rrdtool
420 +# rrdtool.binary = "/usr/bin/rrdtool"
421 # rrdtool.db-name = var.statedir + "/lighttpd.rrd"
422 -# }}}
423
424 -# {{{ mod_setenv
425 -# see setenv.txt
426 -#
427 -# setenv.add-request-header = ( "TRAV_ENV" => "mysql://user@host/db" )
428 +
429 +# mod_setenv
430 +# setenv.add-request-header = ( "TRAV_ENV" => "mysql://user@host/db" )
431 # setenv.add-response-header = ( "X-Secret-Message" => "42" )
432 -# }}}
433
434 -# {{{ mod_trigger_b4_dl
435 -# see trigger_b4_dl.txt
436 -#
437 +
438 +# mod_trigger_b4_dl
439 # trigger-before-download.gdbm-filename = "/home/weigon/testbase/trigger.db"
440 # trigger-before-download.memcache-hosts = ( "127.0.0.1:11211" )
441 # trigger-before-download.trigger-url = "^/trigger/"
442 # trigger-before-download.download-url = "^/download/"
443 # trigger-before-download.deny-url = "http://127.0.0.1/index.html"
444 # trigger-before-download.trigger-timeout = 10
445 -# }}}
446
447 -# {{{ mod_cml
448 -# see cml.txt
449 -#
450 +
451 +# mod_cml
452 # don't forget to add index.cml to server.indexfiles
453 -# cml.extension = ".cml"
454 -# cml.memcache-hosts = ( "127.0.0.1:11211" )
455 -# }}}
456 +# cml.extension = ".cml"
457 +# cml.memcache-hosts = ( "127.0.0.1:11211" )
458
459 -# {{{ mod_webdav
460 -# see webdav.txt
461 -#
462 +
463 +# mod_webdav
464 # $HTTP["url"] =~ "^/dav($|/)" {
465 -# webdav.activate = "enable"
466 -# webdav.is-readonly = "enable"
467 +# webdav.activate = "enable"
468 +# webdav.is-readonly = "enable"
469 # }
470 -# }}}
471
472 -# {{{ extra rules
473 -#
474 +
475 +# Extra Rules
476 # set Content-Encoding and reset Content-Type for browsers that
477 # support decompressing on-thy-fly (requires mod_setenv)
478 # $HTTP["url"] =~ "\.gz$" {
479 -# setenv.add-response-header = ("Content-Encoding" => "x-gzip")
480 -# mimetype.assign = (".gz" => "text/plain")
481 +# setenv.add-response-header = ("Content-Encoding" => "x-gzip")
482 +# mimetype.assign = (".gz" => "text/plain")
483 # }
484
485 # $HTTP["url"] =~ "\.bz2$" {
486 -# setenv.add-response-header = ("Content-Encoding" => "x-bzip2")
487 -# mimetype.assign = (".bz2" => "text/plain")
488 +# setenv.add-response-header = ("Content-Encoding" => "x-bzip2")
489 +# mimetype.assign = (".bz2" => "text/plain")
490 # }
491 -#
492 -# }}}
493
494 -# {{{ debug
495 -# debug.log-request-header = "enable"
496 -# debug.log-response-header = "enable"
497 -# debug.log-request-handling = "enable"
498 -# debug.log-file-not-found = "enable"
499 -# }}}
500
501 -# {{{ cgi includes
502 -# uncomment for cgi support
503 -# include "mod_cgi.conf"
504 -# uncomment for php/fastcgi support
505 -# include "mod_fastcgi.conf"
506 -# }}}
507 -
508 -# vim: set ft=conf foldmethod=marker et :
509 +# Debug
510 +# debug.log-request-header = "enable"
511 +# debug.log-response-header = "enable"
512 +# debug.log-request-handling = "enable"
513 +# debug.log-file-not-found = "enable"
514
515 diff --git a/www-servers/lighttpd/files/conf/mime-types.conf b/www-servers/lighttpd/files/conf/mime-types.conf
516 index 3d7880811717..40e26c1ae9cd 100644
517 --- a/www-servers/lighttpd/files/conf/mime-types.conf
518 +++ b/www-servers/lighttpd/files/conf/mime-types.conf
519 @@ -3,168 +3,166 @@
520 # include'd from lighttpd.conf.
521 ###############################################################################
522
523 -# {{{ mime types
524 -mimetype.assign = (
525 - ".pdf" => "application/pdf",
526 - ".epub" => "application/epub+zip",
527 - ".spl" => "application/futuresplash",
528 - ".jar" => "application/java-archive",
529 - ".class" => "application/java-vm",
530 - ".jsonld" => "application/ld+json",
531 - ".json" => "application/json",
532 - ".mdb" => "application/msaccess",
533 - ".doc" => "application/msword",
534 - ".ogg" => "application/ogg",
535 - ".pgp" => "application/pgp-encrypted",
536 - ".sig" => "application/pgp-signature",
537 - ".ps" => "application/postscript",
538 - ".eps" => "application/postscript",
539 - ".rar" => "applicaion/rar",
540 - ".rdf" => "application/rdf+xml",
541 - ".rss" => "application/rss+xml",
542 - ".rtf" => "application/rtf",
543 - ".azw" => "application/vnd.amazon.ebook",
544 - ".cbz" => "application/vnd.comicbook+zip",
545 - ".cbr" => "application/vnd.comicbook-rar",
546 - ".exe" => "application/vnd.microsoft.portable-executable",
547 - ".xls" => "application/vnd.ms-excel",
548 - ".ppt" => "application/vnd.ms-powerpoint",
549 - ".docm" => "application/vnd.ms-word.document.macroEnabled.12",
550 - ".odt" => "application/vnd.oasis.opendocument.text",
551 - ".ods" => "application/vnd.oasis.opendocument.spreadsheet",
552 - ".odp" => "application/vnd.oasis.opendocument.presentation",
553 - ".odg" => "application/vnd.oasis.opendocument.graphics",
554 - ".odc" => "application/vnd.oasis.opendocument.chart",
555 - ".odf" => "application/vnd.oasis.opendocument.formula",
556 - ".odi" => "application/vnd.oasis.opendocument.image",
557 - ".pptx" => "application/vnd.openxmlformats-officedocument.presentationml.presentation",
558 - ".xlsx" => "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
559 - ".docx" => "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
560 - ".vsd" => "application/vnd.visio",
561 - ".wasm" => "application/wasm",
562 - ".xhtml" => "application/xhtml+xml",
563 - ".zip" => "application/zip",
564 - ".zstd" => "application/zstd",
565 - ".7z" => "application/x-7z-compressed",
566 - ".dmg" => "application/x-apple-diskimage",
567 - ".torrent" => "application/x-bittorrent",
568 - ".bz2" => "application/x-bzip",
569 - ".tbz" => "application/x-bzip-compressed-tar",
570 - ".tar.bz2" => "application/x-bzip-compressed-tar",
571 - ".pgn" => "application/x-chess-pgn",
572 - ".deb" => "application/x-debian-package",
573 - ".dvi" => "application/x-dvi",
574 - ".mm" => "application/x-freemind",
575 - ".gz" => "application/x-gzip",
576 - ".iso" => "application/x-iso9660-image",
577 - ".jnlp" => "application/x-java-jnlp-file",
578 - ".pac" => "application/x-ns-proxy-autoconfig",
579 - ".rpm" => "application/x-redhat-package-manager",
580 - ".swf" => "application/x-shockwave-flash",
581 - ".tar.gz" => "application/x-tgz",
582 - ".tgz" => "application/x-tgz",
583 - ".tar" => "application/x-tar",
584 - ".xz" => "application/x-xz",
585 - ".aac" => "audio/aac",
586 - ".adts" => "audio/aac",
587 - ".ac3" => "audio/ac3",
588 - ".snd" => "audio/basic",
589 - ".mid" => "audio/midi",
590 - ".midi" => "audio/midi",
591 - ".m4a" => "audio/mp4",
592 - ".mp1" => "audio/mpeg",
593 - ".mp2" => "audio/mpeg",
594 - ".mp3" => "audio/mpeg",
595 - ".oga" => "audio/ogg",
596 - ".opus" => "audio/ogg",
597 - ".spx" => "audio/ogg",
598 - ".sid" => "audio/prs.sid",
599 - ".mlp" => "audio/vnd.dolby.mlp",
600 - ".dts" => "audio/vnd.dts",
601 - ".dtshd" => "audio/vnd.dts.hd",
602 - ".flac" => "audio/x-flac",
603 - ".mka" => "audio/x-matroska",
604 - ".m3u" => "audio/x-mpegurl",
605 - ".mod" => "audio/x-mod",
606 - ".wma" => "audio/x-ms-wma",
607 - ".wax" => "audio/x-ms-wax",
608 - ".wav" => "audio/x-wav",
609 - ".otf" => "font/otf",
610 - ".ttf" => "font/ttf",
611 - ".woff" => "font/woff",
612 - ".woff2" => "font/woff2",
613 - ".bmp" => "image/bmp",
614 - ".gif" => "image/gif",
615 - ".heic" => "image/heic",
616 - ".heics" => "image/heic-sequence",
617 - ".heif" => "image/heif",
618 - ".heifs" => "image/heif-sequence",
619 - ".jpg" => "image/jpeg",
620 - ".jpeg" => "image/jpeg",
621 - ".png" => "image/png",
622 - ".tif" => "image/tiff",
623 - ".tiff" => "image/tiff",
624 - ".svg" => "image/svg+xml",
625 - ".svgz" => "image/svg+xml",
626 - ".webp" => "image/webp",
627 - ".psd" => "image/vnd.adobe.photoshop",
628 - ".apng" => "image/vnd.mozilla.apng",
629 - ".ico" => "image/x-icon",
630 - ".xbm" => "image/x-xbitmap",
631 - ".xpm" => "image/x-xpixmap",
632 - ".xwd" => "image/x-xwindowdump",
633 - ".ics" => "text/calendar",
634 - ".css" => "text/css",
635 - ".csv" => "text/csv",
636 - ".html" => "text/html",
637 - ".htm" => "text/html",
638 - ".js" => "text/javascript",
639 - ".asc" => "text/plain",
640 - ".c" => "text/plain",
641 - ".h" => "text/plain",
642 - ".cc" => "text/plain",
643 - ".cpp" => "text/plain",
644 - ".hh" => "text/plain",
645 - ".hpp" => "text/plain",
646 - ".conf" => "text/plain",
647 - ".log" => "text/plain",
648 - ".text" => "text/plain",
649 - ".txt" => "text/plain",
650 - ".diff" => "text/plain",
651 - ".patch" => "text/plain",
652 - ".ebuild" => "text/plain",
653 - ".eclass" => "text/plain",
654 - ".vcard" => "text/vcard",
655 - ".vcf" => "text/vcard",
656 - ".dtd" => "text/xml",
657 - ".xml" => "text/xml",
658 - ".vcs" => "text/x-vcalendar",
659 - ".x3db" => "model/x3d+binary",
660 - ".x3dbz" => "model/x3d+binary",
661 - ".x3dv" => "model/x3d+vrml",
662 - ".x3dvz" => "model/x3d+vrml",
663 - ".x3d" => "model/x3d+xml",
664 - ".x3dz" => "model/x3d+xml",
665 - ".ts" => "video/mp2t",
666 - ".m4v" => "video/mp4",
667 - ".mp4" => "video/mp4",
668 - ".mpeg" => "video/mpeg",
669 - ".mpg" => "video/mpeg",
670 - ".ogv" => "video/ogg",
671 - ".mov" => "video/quicktime",
672 - ".qt" => "video/quicktime",
673 - ".webm" => "video/webm",
674 - ".m4u" => "video/vnd.mpegurl",
675 - ".bik" => "video/vnd.radgamettools.bink",
676 - ".bk2" => "video/vnd.radgamettools.bink",
677 - ".smk" => "video/vnd.radgamettools.smacker",
678 - ".flv" => "video/x-flv",
679 - ".mkv" => "video/x-matroska",
680 - ".mk3d" => "video/x-matroska-3d",
681 - ".mng" => "video/x-mng",
682 - ".avi" => "video/x-msvideo",
683 - ".asf" => "video/x-ms-asf",
684 - ".asx" => "video/x-ms-asf",
685 - ".wmv" => "video/x-ms-wmv"
686 - )
687 -# }}}
688 +mimetype.assign = (
689 + ".pdf" => "application/pdf",
690 + ".epub" => "application/epub+zip",
691 + ".spl" => "application/futuresplash",
692 + ".jar" => "application/java-archive",
693 + ".class" => "application/java-vm",
694 + ".jsonld" => "application/ld+json",
695 + ".json" => "application/json",
696 + ".mdb" => "application/msaccess",
697 + ".doc" => "application/msword",
698 + ".ogg" => "application/ogg",
699 + ".pgp" => "application/pgp-encrypted",
700 + ".sig" => "application/pgp-signature",
701 + ".ps" => "application/postscript",
702 + ".eps" => "application/postscript",
703 + ".rar" => "applicaion/rar",
704 + ".rdf" => "application/rdf+xml",
705 + ".rss" => "application/rss+xml",
706 + ".rtf" => "application/rtf",
707 + ".azw" => "application/vnd.amazon.ebook",
708 + ".cbz" => "application/vnd.comicbook+zip",
709 + ".cbr" => "application/vnd.comicbook-rar",
710 + ".exe" => "application/vnd.microsoft.portable-executable",
711 + ".xls" => "application/vnd.ms-excel",
712 + ".ppt" => "application/vnd.ms-powerpoint",
713 + ".docm" => "application/vnd.ms-word.document.macroEnabled.12",
714 + ".odt" => "application/vnd.oasis.opendocument.text",
715 + ".ods" => "application/vnd.oasis.opendocument.spreadsheet",
716 + ".odp" => "application/vnd.oasis.opendocument.presentation",
717 + ".odg" => "application/vnd.oasis.opendocument.graphics",
718 + ".odc" => "application/vnd.oasis.opendocument.chart",
719 + ".odf" => "application/vnd.oasis.opendocument.formula",
720 + ".odi" => "application/vnd.oasis.opendocument.image",
721 + ".pptx" => "application/vnd.openxmlformats-officedocument.presentationml.presentation",
722 + ".xlsx" => "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet",
723 + ".docx" => "application/vnd.openxmlformats-officedocument.wordprocessingml.document",
724 + ".vsd" => "application/vnd.visio",
725 + ".wasm" => "application/wasm",
726 + ".xhtml" => "application/xhtml+xml",
727 + ".zip" => "application/zip",
728 + ".zstd" => "application/zstd",
729 + ".7z" => "application/x-7z-compressed",
730 + ".dmg" => "application/x-apple-diskimage",
731 + ".torrent" => "application/x-bittorrent",
732 + ".bz2" => "application/x-bzip",
733 + ".tbz" => "application/x-bzip-compressed-tar",
734 + ".tar.bz2" => "application/x-bzip-compressed-tar",
735 + ".pgn" => "application/x-chess-pgn",
736 + ".deb" => "application/x-debian-package",
737 + ".dvi" => "application/x-dvi",
738 + ".mm" => "application/x-freemind",
739 + ".gz" => "application/x-gzip",
740 + ".iso" => "application/x-iso9660-image",
741 + ".jnlp" => "application/x-java-jnlp-file",
742 + ".pac" => "application/x-ns-proxy-autoconfig",
743 + ".rpm" => "application/x-redhat-package-manager",
744 + ".swf" => "application/x-shockwave-flash",
745 + ".tar.gz" => "application/x-tgz",
746 + ".tgz" => "application/x-tgz",
747 + ".tar" => "application/x-tar",
748 + ".xz" => "application/x-xz",
749 + ".aac" => "audio/aac",
750 + ".adts" => "audio/aac",
751 + ".ac3" => "audio/ac3",
752 + ".snd" => "audio/basic",
753 + ".mid" => "audio/midi",
754 + ".midi" => "audio/midi",
755 + ".m4a" => "audio/mp4",
756 + ".mp1" => "audio/mpeg",
757 + ".mp2" => "audio/mpeg",
758 + ".mp3" => "audio/mpeg",
759 + ".oga" => "audio/ogg",
760 + ".opus" => "audio/ogg",
761 + ".spx" => "audio/ogg",
762 + ".sid" => "audio/prs.sid",
763 + ".mlp" => "audio/vnd.dolby.mlp",
764 + ".dts" => "audio/vnd.dts",
765 + ".dtshd" => "audio/vnd.dts.hd",
766 + ".flac" => "audio/x-flac",
767 + ".mka" => "audio/x-matroska",
768 + ".m3u" => "audio/x-mpegurl",
769 + ".mod" => "audio/x-mod",
770 + ".wma" => "audio/x-ms-wma",
771 + ".wax" => "audio/x-ms-wax",
772 + ".wav" => "audio/x-wav",
773 + ".otf" => "font/otf",
774 + ".ttf" => "font/ttf",
775 + ".woff" => "font/woff",
776 + ".woff2" => "font/woff2",
777 + ".bmp" => "image/bmp",
778 + ".gif" => "image/gif",
779 + ".heic" => "image/heic",
780 + ".heics" => "image/heic-sequence",
781 + ".heif" => "image/heif",
782 + ".heifs" => "image/heif-sequence",
783 + ".jpg" => "image/jpeg",
784 + ".jpeg" => "image/jpeg",
785 + ".png" => "image/png",
786 + ".tif" => "image/tiff",
787 + ".tiff" => "image/tiff",
788 + ".svg" => "image/svg+xml",
789 + ".svgz" => "image/svg+xml",
790 + ".webp" => "image/webp",
791 + ".psd" => "image/vnd.adobe.photoshop",
792 + ".apng" => "image/vnd.mozilla.apng",
793 + ".ico" => "image/x-icon",
794 + ".xbm" => "image/x-xbitmap",
795 + ".xpm" => "image/x-xpixmap",
796 + ".xwd" => "image/x-xwindowdump",
797 + ".ics" => "text/calendar",
798 + ".css" => "text/css",
799 + ".csv" => "text/csv",
800 + ".html" => "text/html",
801 + ".htm" => "text/html",
802 + ".js" => "text/javascript",
803 + ".asc" => "text/plain",
804 + ".c" => "text/plain",
805 + ".h" => "text/plain",
806 + ".cc" => "text/plain",
807 + ".cpp" => "text/plain",
808 + ".hh" => "text/plain",
809 + ".hpp" => "text/plain",
810 + ".conf" => "text/plain",
811 + ".log" => "text/plain",
812 + ".text" => "text/plain",
813 + ".txt" => "text/plain",
814 + ".diff" => "text/plain",
815 + ".patch" => "text/plain",
816 + ".ebuild" => "text/plain",
817 + ".eclass" => "text/plain",
818 + ".vcard" => "text/vcard",
819 + ".vcf" => "text/vcard",
820 + ".dtd" => "text/xml",
821 + ".xml" => "text/xml",
822 + ".vcs" => "text/x-vcalendar",
823 + ".x3db" => "model/x3d+binary",
824 + ".x3dbz" => "model/x3d+binary",
825 + ".x3dv" => "model/x3d+vrml",
826 + ".x3dvz" => "model/x3d+vrml",
827 + ".x3d" => "model/x3d+xml",
828 + ".x3dz" => "model/x3d+xml",
829 + ".ts" => "video/mp2t",
830 + ".m4v" => "video/mp4",
831 + ".mp4" => "video/mp4",
832 + ".mpeg" => "video/mpeg",
833 + ".mpg" => "video/mpeg",
834 + ".ogv" => "video/ogg",
835 + ".mov" => "video/quicktime",
836 + ".qt" => "video/quicktime",
837 + ".webm" => "video/webm",
838 + ".m4u" => "video/vnd.mpegurl",
839 + ".bik" => "video/vnd.radgamettools.bink",
840 + ".bk2" => "video/vnd.radgamettools.bink",
841 + ".smk" => "video/vnd.radgamettools.smacker",
842 + ".flv" => "video/x-flv",
843 + ".mkv" => "video/x-matroska",
844 + ".mk3d" => "video/x-matroska-3d",
845 + ".mng" => "video/x-mng",
846 + ".avi" => "video/x-msvideo",
847 + ".asf" => "video/x-ms-asf",
848 + ".asx" => "video/x-ms-asf",
849 + ".wmv" => "video/x-ms-wmv"
850 +)
851
852 diff --git a/www-servers/lighttpd/files/conf/mod_cgi.conf b/www-servers/lighttpd/files/conf/mod_cgi.conf
853 index 982333a007c6..9897af78eafc 100644
854 --- a/www-servers/lighttpd/files/conf/mod_cgi.conf
855 +++ b/www-servers/lighttpd/files/conf/mod_cgi.conf
856 @@ -3,30 +3,22 @@
857 # include'd by lighttpd.conf.
858 ###############################################################################
859
860 -#
861 -# see cgi.txt for more information on using mod_cgi
862 -#
863 -
864 server.modules += ("mod_cgi")
865
866 -# NOTE: this requires mod_alias
867 +# this requires mod_alias
868 alias.url = (
869 - "/cgi-bin/" => var.basedir + "/cgi-bin/"
870 + "/cgi-bin/" => var.basedir + "/cgi-bin/"
871 )
872
873 -#
874 # Note that you'll also want to enable the
875 # cgi-bin alias via mod_alias (above).
876 -#
877
878 $HTTP["url"] =~ "^/cgi-bin/" {
879 - # disable directory listings
880 - dir-listing.activate = "disable"
881 - # only allow cgi's in this directory
882 - cgi.assign = (
883 - ".pl" => "/usr/bin/perl",
884 - ".cgi" => "/usr/bin/perl"
885 - )
886 -}
887 -
888 -# vim: set ft=conf foldmethod=marker et :
889 + # disable directory listings
890 + dir-listing.activate = "disable"
891 + # only allow cgi's in this directory
892 + cgi.assign = (
893 + ".pl" => "/usr/bin/perl",
894 + ".cgi" => "/usr/bin/perl"
895 + )
896 +}
897 \ No newline at end of file
898
899 diff --git a/www-servers/lighttpd/files/conf/mod_fastcgi.conf b/www-servers/lighttpd/files/conf/mod_fastcgi.conf
900 index 5d5ea51ef252..515e7c52aafd 100644
901 --- a/www-servers/lighttpd/files/conf/mod_fastcgi.conf
902 +++ b/www-servers/lighttpd/files/conf/mod_fastcgi.conf
903 @@ -4,13 +4,12 @@
904 ###############################################################################
905
906 server.modules += ("mod_fastcgi")
907 -fastcgi.server = ( ".php" =>
908 - ( "localhost" =>
909 - (
910 - "socket" => "/run/lighttpd/lighttpd-fastcgi-php-" + PID + ".socket",
911 - "bin-path" => "/usr/bin/php-cgi"
912 - )
913 - )
914 - )
915
916 -# vim: set ft=conf foldmethod=marker et :
917 +fastcgi.server = (
918 + ".php" => (
919 + "localhost" => (
920 + "socket" => "/run/lighttpd/lighttpd-fastcgi-php-" + PID + ".socket",
921 + "bin-path" => "/usr/bin/php-cgi"
922 + )
923 + )
924 +)