summaryrefslogtreecommitdiff
path: root/src/plugin.h
Commit message (Collapse)AuthorAgeFilesLines
* [multiple] clang -Wstrict-prototypes for C2xGlenn Strauss2023-01-191-1/+1
| | | | | | | | | | | adjustments to compile warnings-free with recent clang changes that warn about potential behavior change for non-prototypes, including generic function pointers e.g. int(*)() x-ref: https://discourse.llvm.org/t/rfc-enabling-wstrict-prototypes-by-default-in-c/60521 https://www.open-std.org/jtc1/sc22/wg14/www/docs/n2432.pdf https://www.open-std.org/jtc1/sc22/wg14/www/docs/n2841.htm
* [core] remove func decls duplicated in plugin.hGlenn Strauss2022-05-061-36/+0
|
* [core] isolate plugins_*() funcs to main serverGlenn Strauss2022-02-191-16/+0
| | | | | (future: might rename plugin.c -> plugins.c since the functions contained within are all plugins_*())
* [core] merge uri_raw and uri_clean hooksGlenn Strauss2021-05-121-1/+0
| | | | | | hooks are run consecutively in http_response_prepare() merge uri_raw before uri_clean to preserve existing ordering
* [multiple] rename connection_reset hook to requestGlenn Strauss2020-08-021-2/+2
| | | | rename connection_reset to handle_request_reset
* [multiple] split con, request (very large change)Glenn Strauss2020-07-081-23/+28
| | | | | | | | | | | | | | | | NB: r->tmp_buf == srv->tmp_buf (pointer is copied for quicker access) NB: request read and write chunkqueues currently point to connection chunkqueues; per-request and per-connection chunkqueues are not distinct from one another con->read_queue == r->read_queue con->write_queue == r->write_queue NB: in the future, a separate connection config may be needed for connection-level module hooks. Similarly, might need to have per-request chunkqueues separate from per-connection chunkqueues. Should probably also have a request_reset() which is distinct from connection_reset().
* [core] store subrequest_handler instead of modeGlenn Strauss2020-07-081-2/+1
| | | | store pointer to module in handler_module instead of con->mode id
* [core] store (plugin *) in p->dataGlenn Strauss2020-07-081-3/+4
| | | | (self-referential)
* [multiple] plugin_stats arrayGlenn Strauss2020-07-081-0/+17
| | | | | | | use global rather than passing around (server *) just for that li_itostrn() and li_utostrn() return string length (rather than requiring subsequent strlen() to find length)
* [multiple] connection hooks no longer get (srv *)Glenn Strauss2020-07-081-31/+31
| | | | (explicit (server *) not passed; available in con->srv)
* [core] isolate use of data_config, configfile.hGlenn Strauss2020-07-081-1/+1
|
* [core] run all trigger and sighup handlersGlenn Strauss2020-07-081-2/+2
| | | | | | (do not bail if a handler returns something other than HANDLER_GO_ON) (preserve fn signature for simplicity and compat with plugin_fn_data)
* [multiple] plugin.c handles common FREE_FUNC codeGlenn Strauss2020-07-081-5/+5
| | | | (simpler for modules; less boilerplate to cut-n-paste)
* [core] config_plugin_values_init() new interfaceGlenn Strauss2020-05-231-1/+3
| | | | | | | new data structures and interface for processing config directives (towards more efficient approach to config merging) continue work to isolate data_config
* [core] struct plugin_data_baseGlenn Strauss2020-05-231-0/+4
|
* [core] const char *name in struct pluginGlenn Strauss2020-05-231-25/+16
| | | | | | | | put void *data (always used) as first member of struct plugin add int nconfig member to PLUGIN_DATA calloc() inits p->data to NULL
* [core] new worker_init hook to follow parent forkGlenn Strauss2019-04-201-0/+4
|
* [core] mark startup/shutdown funcs coldGlenn Strauss2019-02-041-4/+15
|
* [core] some header cleanupGlenn Strauss2018-04-081-5/+3
| | | | | | | | | provide standard types in first.h instead of base.h provide lighttpd types in base_decls.h instead of settings.h reduce headers exposed by headers for core data structures do not expose <pcre.h> or <stdlib.h> in headers move stat_cache_entry to stat_cache.h reduce use of "server.h" and "base.h" in headers
* [core] merge redirect/rewrite pattern substitutionGlenn Strauss2018-01-101-1/+0
| | | | merge redirect/rewrite pattern substitution function (share code)
* [core] SIGCHLD handle_waitpid hook for modulesGlenn Strauss2017-09-101-1/+3
| | | | | | | | | centralize most waitpid() handling in core server, with hooks for modules to be informed of pid and status when a process exits. This enables faster discovery (and restart) of exited processes, and also allows for lighttpd to manage backend processes in the parent (master) process when server.max-worker > 0.
* [core] allow earlier plugin init for SSL/TLSGlenn Strauss2017-05-211-0/+1
| | | | | | | | If lighttpd is started privileged, then SSL/TLS modules need to be initialized prior to chroot (optional) and prior to dropping privileges in order to be able to read sensitive files such as private certificates (thx m4t)
* [core] new plugin hooks to help isolate SSLGlenn Strauss2017-01-141-1/+7
| | | | | | | handle_request_env (called on demand by handlers to populate env) handle_connection_accept handle_connection_shut_wr (was handle_connection_close) handle_connection_close (now occurs at socket close())
* remove redundant calls to end-of-request hooksGlenn Strauss2017-01-141-1/+1
| | | | | | | The (misnamed) connection_reset hook is always called after a request, whether request completes or is aborted, and whether keep-alive or not, so no needed to repeat the same function in the handle_connection_close hook.
* backport mod_deflate to lighttpd 1.4 (fixes #1824, fixes #2753)Glenn Strauss2016-09-221-0/+2
| | | | | | | | | | | | | | | | | | | | lots of fixes and improvements limitations: see comments at top of mod_deflate.c missing functionality: encode streaming response (module currently requires response be collected before being sent) potential functionality: addition of compressed file cache would allow mod_deflate to fully supplant mod_compress in lighttpd 1.4.x x-ref: "Adding mod_deflate to 1.4.xx" https://redmine.lighttpd.net/issues/1824 "mod_deflate backport compile error if ENABLE_MMAP not defined" https://redmine.lighttpd.net/issues/2753 github: closes #67
* remove handle_joblist hookGlenn Strauss2016-04-181-3/+0
| | | | | | | remove handle_joblist hook and remove the hooks defined in mod_fastcgi and mod_scgi. The calls made to fdevent management are redundant. If the calls were actually needed, then mod_proxy would have needed a handle_joblist handler, too.
* consistent inclusion of config.h at top of files (fixes #2073)Glenn Strauss2016-03-191-0/+1
| | | | | | From: Glenn Strauss <gstrauss@gluelogic.com> git-svn-id: svn://svn.lighttpd.net/lighttpd/branches/lighttpd-1.4.x@3113 152afb58-edef-0310-8abb-c4023f1b3aa9
* [core] improve conditional enabling (thx Gwenlliana, #2598)Stefan Bühler2016-02-211-2/+0
| | | | | | | | | | | | | | instead of looping over all config blocks for each conditional var that gets enabled, enable them all and run over them once. Right now it seems we actually set all variables at once in normal config handling (SNI only sets a subset); future modifications might introduce new variables which are activated at a later stage (physical path related for example). From: Stefan Bühler <stbuehler@web.de> git-svn-id: svn://svn.lighttpd.net/lighttpd/branches/lighttpd-1.4.x@3083 152afb58-edef-0310-8abb-c4023f1b3aa9
* [config] check config option scope; warn if server option is given in ↵Stefan Bühler2015-11-071-2/+2
| | | | | | | | conditional From: Stefan Bühler <stbuehler@web.de> git-svn-id: svn://svn.lighttpd.net/lighttpd/branches/lighttpd-1.4.x@3049 152afb58-edef-0310-8abb-c4023f1b3aa9
* Fix non-ANSI function declarations.Cyril Brulebois2012-08-311-1/+1
| | | | | | | | | | | | The proper way to declare a function taking no parameters isn't: foo bar(); But this instead: foo bar(void); Signed-off-by: Cyril Brulebois <kibi@debian.org> git-svn-id: svn://svn.lighttpd.net/lighttpd/branches/lighttpd-1.4.x@2843 152afb58-edef-0310-8abb-c4023f1b3aa9
* - white space cleanup part 2 this time 1.4 ;)Marcus Rückert2006-10-041-11/+11
| | | | | | i hope it helps with merging stuff back to 1.5 git-svn-id: svn://svn.lighttpd.net/lighttpd/branches/lighttpd-1.4.x@1371 152afb58-edef-0310-8abb-c4023f1b3aa9
* ..physical_path is gone and has ben replaced by subrequest_startJan Kneschke2005-08-151-2/+0
| | | | git-svn-id: svn://svn.lighttpd.net/lighttpd/branches/lighttpd-merge-1.4.x@532 152afb58-edef-0310-8abb-c4023f1b3aa9
* added include_shell option to configfiles (merged the rest of the trunk ↵Jan Kneschke2005-08-091-0/+1
| | | | | | changesets) git-svn-id: svn://svn.lighttpd.net/lighttpd/branches/lighttpd-merge-1.4.x@530 152afb58-edef-0310-8abb-c4023f1b3aa9
* allow _ in env. and var. and optimized matching of conditionsJan Kneschke2005-08-081-1/+1
| | | | git-svn-id: svn://svn.lighttpd.net/lighttpd/branches/lighttpd-merge-1.4.x@529 152afb58-edef-0310-8abb-c4023f1b3aa9
* let mod_alias handle directories and files (merged [284], [294])Jan Kneschke2005-08-081-0/+2
| | | | git-svn-id: svn://svn.lighttpd.net/lighttpd/branches/lighttpd-merge-1.4.x@504 152afb58-edef-0310-8abb-c4023f1b3aa9
* moved everything below trunk/ and added branches/ and tags/Jan Kneschke2005-02-201-0/+91
git-svn-id: svn://svn.lighttpd.net/lighttpd/trunk@30 152afb58-edef-0310-8abb-c4023f1b3aa9