Commit Graph

2848 Commits (9459c0546842930265c8bc19b07609286e7e67cb)
 

Author SHA1 Message Date
Glenn Strauss 6b77372ae7 [core] move /dev/stdin graceful restart handling
move /dev/stdin graceful restart handling special-case up out of
network_server_init()
4 years ago
Glenn Strauss b2ee667a3d [core] move winsock init to network_init() 4 years ago
Stefan Bühler 9b7a32ea70 [doc/conf] resolve some mime type conflicts from debian buster, regenerate mime.conf 4 years ago
Glenn Strauss a70cf6e5dc [core] cache rev DNS for localhost for dir redir 4 years ago
Glenn Strauss 629b16f188 [core] send Connection: close if reqbody not read (fixes #2924)
send Connection: close if it is known that request body has not finished
being read and will not finish being read

x-ref:
  "Suboptimal keep-alive handling when request body is not read"
  https://redmine.lighttpd.net/issues/2924
4 years ago
Glenn Strauss 96061c1e5e [mod_auth] permit additional auth backends to load
(For testing purposes, allow for all current auth module backends
 to be loaded and registered at the same time)
4 years ago
Glenn Strauss ed6b894127 [core] define MD5_DIGEST_LENGTH 16 4 years ago
Glenn Strauss e47ea5e2b0 [core] memeq compare rounded to 64, not next 1M 4 years ago
Glenn Strauss b541b67459 [core] use con->server_name for dir redir
use con->server_name for dir redir if con->server_name is not empty
and Host header not provided in request.
4 years ago
Glenn Strauss 81dfa7a8d2 [core] http_response_buffer_append_authority()
(shared code)
4 years ago
Glenn Strauss bceeac654e [core] use connected sock port in dir redirect 4 years ago
Glenn Strauss c2bd063ac4 [core] do not free() reused buffer 4 years ago
Glenn Strauss 8ed98ad089 [core] perf: reuse buffer to redirect to directory 4 years ago
Glenn Strauss 7d4ecd01e8 [core] perf: incremental hash of pathname w/o copy 4 years ago
Glenn Strauss a1077d18cb [tests] more test config cleanup 4 years ago
Glenn Strauss fe3dc17968 [mod_fastcgi] fix NULL ptr deref from bugfix #2922 (fixes #2923)
(thx rgenoud)

x-ref:
  "SIGSEGV on file upload"
  https://redmine.lighttpd.net/issues/2923
4 years ago
Glenn Strauss a1b527e473 [multiple] reduce initial buffer sz if large POST (fixes #2922)
reduce initial buffer size if large POST to backend stored in temp files

regression in lighttpd 1.4.52

(thx rgenoud)

x-ref:
  "[regression] lighttpd gets killed after uploading a big file"
  https://redmine.lighttpd.net/issues/2922
4 years ago
Glenn Strauss 4e6ef76406 [tests] update skip count in mod-fastcgi.t 4 years ago
Glenn Strauss 07517ff30a [tests] some test config cleanup
including limiting use of php in tests to mod-fastcgi.t
4 years ago
Glenn Strauss f03e5e239d [tests] t/test_keyvalue
create t/test_keyvalue to replace sparse tests in
  tests/mod-redirect.t and tests/mod-rewrite.t
remove tests/mod-redirect.t and tests/mod-rewrite.t
4 years ago
Glenn Strauss dd11144bc8 [core] use kill_signal for gw_proc_kill()
After 4 seconds, send kill() every second while waiting for child to exit.

Send host->kill_signal for next 4 seconds, then send SIGTERM (usually same
as host->kill_signal) for following 8 seconds, and finally send SIGKILL
each second after that, until the child process dies.

github: closes #94
4 years ago
Glenn Strauss c2a9692e78 [tests] include first.h and NDEBUG early 4 years ago
Glenn Strauss 5a32d0f72a [mod_access] t/test_mod_access
create t/test_mod_access to test mod_access basic logic
remove tests/mod-access.t
4 years ago
Glenn Strauss ddf95741b5 [mod_access] restructure for unit tests 4 years ago
Glenn Strauss 8aad091613 [mod_evhost] t/test_mod_evhost
create t/test_mod_evhost to test mod_evhost basic logic
remove tests/mod-evhost.t
4 years ago
Glenn Strauss 5299bded32 [mod_evhost] restructure for unit tests 4 years ago
Glenn Strauss 093569a6f6 [mod_evhost] split uri handler func for testing 4 years ago
Glenn Strauss b2a6239851 [mod_simple_vhost] t/test_mod_simple_vhost
create t/test_mod_simple_vhost to test mod_simple_vhost basic logic
remove tests/mod-simplevhost.t, which was not testing mod_simple_vhost
4 years ago
Glenn Strauss 685f4ed62c [mod_cml,mod_flv_streaming] fix NULL ptr deref
fix possible NULL pointer dereference when query string not present
and no previous query strings processed by that specific connection
instance

regression in lighttpd 1.4.51 (mod_flv_streaming)
regression in lighttpd 1.4.52 (mod_cml)

workaround for mod_flv_streaming:
  url.rewrite-once = ( "\.flv$" => "${url.path}?" )
(similar workaround for mod_cml)

(thx fab)

x-ref:
  "segfault with mod_flv_streaming"
  https://redmine.lighttpd.net/boards/2/topics/8404
4 years ago
Glenn Strauss 53c231a764 - next is 1.4.53 4 years ago
Glenn Strauss 06ebbc3ed4 [core] invert logic for mod_indexfile load warning 4 years ago
Glenn Strauss e92919788f [mod_webdav] silence warnings if built w/o locks
silence compiler warnings if built w/o locks
4 years ago
Glenn Strauss e0d1528860 [doc] NEWS 4 years ago
Glenn Strauss a7bceb6b06 [core] quiet indexfile warning if mod not loaded 4 years ago
Glenn Strauss 77c01f9817 [core] buffer_append_path_len()
concatenate paths, placing single '/' between strings

reverts broken commit:b9402283

(thx avij)
4 years ago
Glenn Strauss 608026e5aa [core] fix typo 4 years ago
Glenn Strauss fed4573fad [mod_proxy] silence coverity false positive 4 years ago
Glenn Strauss 80638252dc [multiple] validate UTF-8 in url-decoded paths
validate UTF-8 in url-decoded paths obtained elsewhere than from request

(burl_normalize(), if enabled with server.http-parseopts, checks url for
 overlong encodings of ASCII chars in the HTTP request-line)
4 years ago
Glenn Strauss e8e59396d3 [core] reject decoded url-path without leading '/'
buffer_simplify_path() no longer prepends '/' if '/' is missing.
Callers must check for leading '/' depending on use, such as in
concatenation with others paths, or direct use accessing filesystem

Note: lighttpd 1.4.50 provides the server.http-parseopts directive.
Recommended settings unless specific use requires looser settings:
  server.http-parseopts = (
    "header-strict"            => "enable",
    "host-strict"              => "enable",
    "host-normalize"           => "enable",
    "url-normalize"            => "enable",
    "url-normalize-unreserved" => "enable",
    "url-normalize-required"   => "enable",
    "url-ctrls-reject"         => "enable",
    "url-path-2f-decode"       => "enable",
    "url-path-dotseg-remove"   => "enable",
    "url-query-20-plus"        => "enable"
  )

x-ref:
  https://digi.ninja/blog/lighttpd_rewrite_bypass.php

As noted in the link above, mod_access should be preferred instead
of mod_rewrite for access controls to URLs.
4 years ago
Glenn Strauss 8a8579802a [mod_webdav] separate func for each request method
split up mod_webdav_subrequest_handler_huge() into subroutines
4 years ago
Glenn Strauss cef6ee675d [core] limit con->uri.authority < 1024 octets
(expect < 256 octets for DNS name)

Since limit is imposed, can use buffer_clear() instead of buffer_reset()
for con->uri.authority and con->server_name.  (Also, con->uri.scheme is
limited to "http" and "https", so use buffer_clear() for it, too)
4 years ago
Glenn Strauss 0bac13f6b4 [core] cygwin sample to run lighttpd under NSSM
configure NSSM to set environment variables when starting lighttpd
  NSSM_SERVICE_NAME=lighttpd
  NSSM_SERVICE_DIR=/lighttpd/install/dir (optional)
4 years ago
Glenn Strauss ad53c30d4b [core] cygwin helper func for getcwd 4 years ago
Glenn Strauss cf93e91c56 [core] perf: inline buffer_copy_buffer() 4 years ago
Glenn Strauss d7cfc8a381 [mod_wstunnel] use buffer_string_length()
use buffer_string_length() abstraction instead of b->used
4 years ago
Glenn Strauss 75bd40aa5d [core] perf: buffer optimizations
buffer_string_prepare_copy() no longer writes '\0' into b->ptr
buffer_realloc() always allocates extra +1 for '\0'
4 years ago
Glenn Strauss cced512116 [mod_cml] parse query string without modifying it 4 years ago
Glenn Strauss 449274903c [core] perf: simplify buffer_move()
require src and dest to be non-NULL

change no longer releases large swapped buffers with buffer_reset()
4 years ago
Glenn Strauss ef1fdcd910 [mod_webdav] one fewer buffer copy for COPY,MOVE
one fewer buffer copy of Destination for COPY,MOVE
4 years ago
Glenn Strauss 956a3fb9db [mod_webdav] fix LOCK on incorrect URI path 4 years ago