History log of /lighttpd1.4/src/configparser.y (Results 1 – 25 of 92)
Revision (<<< Hide revision tags) (Show revision tags >>>) Date Author Comments
Revision tags: lighttpd-1.4.69
# 782fa347 09-Jan-2023 Glenn Strauss <[email protected]>

[core] build configparser.y w/ -Werror workarounds


Revision tags: lighttpd-1.4.68
# 8626edfa 08-Dec-2022 Glenn Strauss <[email protected]>

[core] use data_config_list for config

use data_config_list for config, replacing generated vector_config_weak


# 3c92c959 21-Nov-2022 Glenn Strauss <[email protected]>

[core] fix crash for invalid lighttpd.conf (fixes #3175)

(thx dhjeong2)

x-ref:
"configuration parse bug"
https://redmine.lighttpd.net/issues/3175


Revision tags: lighttpd-1.4.67, lighttpd-1.4.66, lighttpd-1.4.65
# 36e64317 04-May-2022 Glenn Strauss <[email protected]>

[core] fix configparser_simplify_regex() comment


# 14bfa016 27-Apr-2022 Glenn Strauss <[email protected]>

[core] sketch support for abstract sockets

(experimental; untested)

Note: abstract sockets do not require filesystem access and can not be
protected using filesystem permissions; abstract sockets a

[core] sketch support for abstract sockets

(experimental; untested)

Note: abstract sockets do not require filesystem access and can not be
protected using filesystem permissions; abstract sockets are accessible
by any process in the same network namespace on the same machine.

Abstract sockets can be passed to lighttpd via systemd socket activation
mechanism, via xinetd, or any other process which creates an abstract
socket and passes it to lighttpd. Abstract sockets can also be
configured in lighttpd.conf using a backslash-escaped double-quoted
string, where CTL and chars with high bit set are backslash-escaped into
"\\xFF", with "\\x" followed by two-byte hex encoding (e.g. "FF") for
each escaped char, e.g. "\\x00abstract-socket"

show more ...


# dcb5f231 05-Apr-2022 Glenn Strauss <[email protected]>

[core] convert simple config cond regex to pre/sfx

convert simple config condition regex to prefix/suffix match


# b3e80a13 05-Apr-2022 Glenn Strauss <[email protected]>

[core] tighten config parsing loop


# 39c31278 05-Apr-2022 Glenn Strauss <[email protected]>

[core] prefix (=^), suffix (=$) config conditions (fixes #3153)

x-ref:
"lighttpd.conf conditionals using prefix and suffix matching"
https://redmine.lighttpd.net/issues/3153


Revision tags: lighttpd-1.4.64
# 51e141c8 07-Jan-2022 Glenn Strauss <[email protected]>

[multiple] remove buffer_init_buffer()

remove (minor) convenience func; easy to replace

Like buffer_init_string(), buffer_init_buffer() was used in only a few
places at startup or in cold funcs, so

[multiple] remove buffer_init_buffer()

remove (minor) convenience func; easy to replace

Like buffer_init_string(), buffer_init_buffer() was used in only a few
places at startup or in cold funcs, so better off removed from buffer.c

show more ...


# bade1c03 07-Jan-2022 Glenn Strauss <[email protected]>

[multiple] remove buffer_init_string()

remove (minor) convenience func; easy to replace


Revision tags: lighttpd-1.4.63, lighttpd-1.4.62, lighttpd-1.4.61, lighttpd-1.4.60
# 4b9da9f1 20-Jun-2021 Glenn Strauss <[email protected]>

[core] parse $HTTP["remote-ip"] CIDR mask at start

parse $HTTP["remote-ip"] CIDR mask into structured data at startup

note: adds buffer_move() to configparser.y to reduce memory copying
for all con

[core] parse $HTTP["remote-ip"] CIDR mask at start

parse $HTTP["remote-ip"] CIDR mask into structured data at startup

note: adds buffer_move() to configparser.y to reduce memory copying
for all config values, and is required for remote-ip to preserve the
structured data added after the config value string. (Alternatively,
could have normalized the remote-ip value after copying into dc->string)

show more ...


# af3df29a 09-Jun-2021 Glenn Strauss <[email protected]>

[multiple] reduce redundant NULL buffer checks

This commit is a large set of code changes and results in removal of
hundreds, perhaps thousands, of CPU instructions, a portion of which
are on hot co

[multiple] reduce redundant NULL buffer checks

This commit is a large set of code changes and results in removal of
hundreds, perhaps thousands, of CPU instructions, a portion of which
are on hot code paths.

Most (buffer *) used by lighttpd are not NULL, especially since buffers
were inlined into numerous larger structs such as request_st and chunk.

In the small number of instances where that is not the case, a NULL
check is often performed earlier in a function where that buffer is
later used with a buffer_* func. In the handful of cases that remained,
a NULL check was added, e.g. with r->http_host and r->conf.server_tag.

- check for empty strings at config time and set value to NULL if blank
string will be ignored at runtime; at runtime, simple pointer check
for NULL can be used to check for a value that has been set and is not
blank ("")
- use buffer_is_blank() instead of buffer_string_is_empty(),
and use buffer_is_unset() instead of buffer_is_empty(),
where buffer is known not to be NULL so that NULL check can be skipped
- use buffer_clen() instead of buffer_string_length() when buffer is
known not to be NULL (to avoid NULL check at runtime)
- use buffer_truncate() instead of buffer_string_set_length() to
truncate string, and use buffer_extend() to extend

Examples where buffer known not to be NULL:
- cpv->v.b from config_plugin_values_init is not NULL if T_CONFIG_BOOL
(though we might set it to NULL if buffer_is_blank(cpv->v.b))
- address of buffer is arg (&foo)
(compiler optimizer detects this in most, but not all, cases)
- buffer is checked for NULL earlier in func
- buffer is accessed in same scope without a NULL check (e.g. b->ptr)

internal behavior change:
callers must not pass a NULL buffer to some funcs.
- buffer_init_buffer() requires non-null args
- buffer_copy_buffer() requires non-null args
- buffer_append_string_buffer() requires non-null args
- buffer_string_space() requires non-null arg

show more ...


# 4f8f83ea 20-May-2021 Glenn Strauss <[email protected]>

[core] move data_{array,integer,string} to array.c

move native data_* types into array.c
(the types are already declared in array.h)

The array data structure remains extendable, as is done with dat

[core] move data_{array,integer,string} to array.c

move native data_* types into array.c
(the types are already declared in array.h)

The array data structure remains extendable, as is done with data_config
(configfile) and data_auth (mod_auth), though array data structure
primary uses are at startup (config time) and header parsing. The
insertion logic into sorted list can be expensive for large lists,
so header parsing might choose a different data structure in the future.

show more ...


# 7ff6adc4 01-May-2021 Glenn Strauss <[email protected]>

[core] tolerate dup array config values if match

tolerate duplicated array config values if identical key and value
(still issue warning trace)


# dc01487e 25-Mar-2021 Glenn Strauss <[email protected]>

[multiple] use buffer_append_* aggregates

reduces the number of round-trips into some frequently-called routines


# 8845e1e6 14-Mar-2021 Glenn Strauss <[email protected]>

[core] defer pcre_compile until after config parse


Revision tags: lighttpd-1.4.59
# cf3e3012 28-Jan-2021 Glenn Strauss <[email protected]>

[core] tighten struct data_config and related code

tighten struct data_config and config_cond_info
create config key at startup and reuse for debug/trace
separate routine for configparser_parse_cond

[core] tighten struct data_config and related code

tighten struct data_config and config_cond_info
create config key at startup and reuse for debug/trace
separate routine for configparser_parse_condition()
separate routine for configparser_parse_else_condition()

show more ...


Revision tags: lighttpd-1.4.58, lighttpd-1.4.57, lighttpd-1.4.56, lighttpd-1.4.56-rc7, lighttpd-1.4.56-rc6, lighttpd-1.4.56-rc5, lighttpd-1.4.56-rc4, lighttpd-1.4.56-rc3, lighttpd-1.4.56-rc2, lighttpd-1.4.56-rc1
# 48384c7e 24-Oct-2020 Glenn Strauss <[email protected]>

[core] fix (startup) mem leaks in configparser.y

(thx stbuehler)


# 2e0676fd 11-Sep-2020 Glenn Strauss <[email protected]>

[core] extend (data_string *) to store header id

(optional addition to (data_string *), used by http_header.[ch])

extend (data_string *) instead of creating another data_* TYPE_*
(new data type w

[core] extend (data_string *) to store header id

(optional addition to (data_string *), used by http_header.[ch])

extend (data_string *) instead of creating another data_* TYPE_*
(new data type would probably have (data_string *) as base class)
(might revisit choice in the future)

HTTP_HEADER_UNSPECIFIED has been removed. It was used in select
locations as an optimization to avoid looking up enum header_header_e
before checking the array, but the ordering in the array now relies
on having the id. Having the id allows for a quick check if a common
header is present or not in the htags bitmask, before checking the
array, and allows for integer comparison in the log(n) search of the
array, instead of strncasecmp().

With HTTP_HEADER_UNSPECIFIED removed, add optimization to set bit
in htags for HTTP_HEADER_OTHER when an "other" header is added,
but do not clear the bit, as there might be addtl "other" headers

show more ...


# 44686633 23-Mar-2020 Glenn Strauss <[email protected]>

[multiple] use *(unsigned char *) with ctypes


Revision tags: lighttpd-1.4.55
# 7c7f8c46 13-Jan-2020 Glenn Strauss <[email protected]>

[multiple] split con, request (very large change)

NB: r->tmp_buf == srv->tmp_buf (pointer is copied for quicker access)

NB: request read and write chunkqueues currently point to connection
chun

[multiple] split con, request (very large change)

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().

show more ...


# 24680a91 22-Nov-2019 Glenn Strauss <[email protected]>

[core] array_init() arg for initial size


# 5aadcba4 14-Oct-2019 Glenn Strauss <[email protected]>

[core] buffer string in data_config

(instead of (buffer *))


# a5127803 13-Oct-2019 Glenn Strauss <[email protected]>

[core] const char *op in data_config

(instead of (buffer *))


# c2238256 13-Oct-2019 Glenn Strauss <[email protected]>

[core] inline array as part of data_array value

(instead of value being (array *))


1234