aboutsummaryrefslogtreecommitdiff
path: root/src/core
Commit message (Collapse)AuthorAge
* Core: improved NGX_ALIGNMENT detection on some x86_64 platforms.Aleksei Bavshin2025-04-18
| | | | | | | | | | | | | | | Previously, the default pool alignment used sizeof(unsigned long), with the expectation that this would match to a platform word size. Certain 64-bit platforms prove this assumption wrong by keeping the 32-bit long type, which is fully compliant with the C standard. This introduces a possibility of suboptimal misaligned access to the data allocated with ngx_palloc() on the affected platforms, which is addressed here by changing the default NGX_ALIGNMENT to a pointer size. As we override the detection in auto/os/conf for all the machine types except x86, and Unix-like 64-bit systems prefer the 64-bit long, the impact of the change should be limited to Win64 x64.
* Version bump.Roman Arutyunyan2025-04-16
|
* Version bump.Sergey Kandaurov2025-02-18
|
* Upstream: fixed --with-compat build without SSL, broken by 454ad0e.Pavel Pautov2025-01-23
|
* Version bump.Roman Arutyunyan2024-11-27
|
* Realip: allowed square brackets with portless IPv6 address.Roman Arutyunyan2024-11-26
| | | | | | | | | When client address is received, IPv6 address could be specified without square brackets and without port, as well as both with the brackets and port. The change allows IPv6 in square brackets and no port, which was previously considered an error. This format conforms to RFC 3986. The change also affects proxy_bind and friends.
* Core: inheritance of non-reusable shared memory zones.Ruslan Ermilov2024-11-07
| | | | When re-creating a non-reusable zone, make the pointer to the old zone available during the new zone initialization.
* Version bump.Sergey Kandaurov2024-10-08
|
* Version bump.Sergey Kandaurov2024-08-20
|
* Version bump.Sergey Kandaurov2024-08-09
|
* Optimized chain link usage (ticket #2614).Roman Arutyunyan2024-05-23
| | | | | | | | | | Previously chain links could sometimes be dropped instead of being reused, which could result in increased memory consumption during long requests. A similar chain link issue in ngx_http_gzip_filter_module was fixed in da46bfc484ef (1.11.10). Based on a patch by Sangmin Lee.
* Version bump.Sergey Kandaurov2024-05-03
|
* Fixed undefined behaviour with IPv4-mapped IPv6 addresses.Sergey Kandaurov2024-03-18
| | | | | | | | | | | | | | | | Previously, it could result when left-shifting signed integer due to implicit integer promotion, such that the most significant bit appeared on the sign bit. In practice, though, this results in the same left value as with an explicit cast, at least on known compilers, such as GCC and Clang. The reason is that in_addr_t, which is equivalent to uint32_t and same as "unsigned int" in ILP32 and LP64 data type models, has the same type width as the intermediate after integer promotion, so there's no side effects such as sign-extension. This explains why adding an explicit cast does not change object files in practice. Found with UndefinedBehaviorSanitizer (shift). Based on a patch by Piotr Sikora.
* Version bump.Roman Arutyunyan2024-03-21
|
* Version bump.Sergey Kandaurov2023-10-27
|
* Core: changed ngx_queue_sort() to use merge sort.Maxim Dounin2023-10-18
| | | | | | | | | | | This improves nginx startup times significantly when using very large number of locations due to computational complexity of the sorting algorithm being used: insertion sort is O(n*n) on average, while merge sort is O(n*log(n)). In particular, in a test configuration with 20k locations total startup time is reduced from 8 seconds to 0.9 seconds. Prodded by Yusuke Nojima, https://mailman.nginx.org/pipermail/nginx-devel/2023-September/NUL3Y2FPPFSHMPTFTL65KXSXNTX3NQMK.html
* Core: fixed memory leak on configuration reload with PCRE2.Maxim Dounin2023-10-17
| | | | | | | | | | | | | | | | In ngx_regex_cleanup() allocator wasn't configured when calling pcre2_compile_context_free() and pcre2_match_data_free(), resulting in no ngx_free() call and leaked memory. Fix is ensure that allocator is configured for global allocations, so that ngx_free() is actually called to free memory. Additionally, ngx_regex_compile_context was cleared in ngx_regex_module_init(). It should be either not cleared, so it will be freed by ngx_regex_cleanup(), or properly freed. Fix is to not clear it, so ngx_regex_cleanup() will be able to free it. Reported by ZhenZhong Wu, https://mailman.nginx.org/pipermail/nginx-devel/2023-September/3Z5FIKUDRN2WBSL3JWTZJ7SXDA6YIWPB.html
* Modules compatibility: added QUIC to signature (ticket #2539).Roman Arutyunyan2023-09-13
| | | | | Enabling QUIC changes ngx_connection_t layout, which is why it should be added to the signature.
* Version bump.Sergey Kandaurov2023-08-25
|
* QUIC: path MTU discovery.Roman Arutyunyan2023-08-14
| | | | | MTU selection starts by doubling the initial MTU until the first failure. Then binary search is used to find the path MTU.
* Core: fixed environment variables on exit.Maxim Dounin2023-07-19
| | | | | | | | Similarly to 6822:c045b4926b2c, environment variables introduced with the "env" directive (and "NGINX_BPF_MAPS" added by QUIC) are now allocated via ngx_alloc(), and explicitly freed by a cleanup handler if no longer used. In collaboration with Sergey Kandaurov.
* Version bump.Roman Arutyunyan2023-06-20
|
* Version bump.Roman Arutyunyan2023-05-29
|
* Merged with the quic branch.Roman Arutyunyan2023-05-19
|\
| * Common tree insert function for QUIC and UDP connections.Roman Arutyunyan2023-05-14
| | | | | | | | | | | | | | | | | | | | | | Previously, ngx_udp_rbtree_insert_value() was used for plain UDP and ngx_quic_rbtree_insert_value() was used for QUIC. Because of this it was impossible to initialize connection tree in ngx_create_listening() since this function is not aware what kind of listening it creates. Now ngx_udp_rbtree_insert_value() is used for both QUIC and UDP. To make is possible, a generic key field is added to ngx_udp_connection_t. It keeps client address for UDP and connection ID for QUIC.
| * QUIC: disabled datagram fragmentation.Roman Arutyunyan2023-05-06
| | | | | | | | | | | | As per RFC 9000, Section 14: UDP datagrams MUST NOT be fragmented at the IP layer.
| * Merged with the default branch.Sergey Kandaurov2023-03-29
| |\
| * \ Merged with the default branch.Sergey Kandaurov2023-01-02
| |\ \
| * \ \ Merged with the default branch.Sergey Kandaurov2022-12-15
| |\ \ \
| * \ \ \ Merged with the default branch.Sergey Kandaurov2022-10-20
| |\ \ \ \
| * \ \ \ \ Merged with the default branch.Sergey Kandaurov2022-07-26
| |\ \ \ \ \
| * \ \ \ \ \ Merged with the default branch.Sergey Kandaurov2022-06-22
| |\ \ \ \ \ \
| * | | | | | | QUIC: separate UDP framework for QUIC.Roman Arutyunyan2022-04-20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously, QUIC used the existing UDP framework, which was created for UDP in Stream. However the way QUIC connections are created and looked up is different from the way UDP connections in Stream are created and looked up. Now these two implementations are decoupled.
| * | | | | | | Merged with the default branch.Sergey Kandaurov2022-02-14
| |\ \ \ \ \ \ \
| * \ \ \ \ \ \ \ Merged with the default branch.Sergey Kandaurov2022-01-25
| |\ \ \ \ \ \ \ \
| * \ \ \ \ \ \ \ \ Merged with the default branch.Sergey Kandaurov2021-12-29
| |\ \ \ \ \ \ \ \ \
| * \ \ \ \ \ \ \ \ \ Merged with the default branch.Ruslan Ermilov2021-12-24
| |\ \ \ \ \ \ \ \ \ \
| * \ \ \ \ \ \ \ \ \ \ Merged with the default branch.Sergey Kandaurov2021-11-03
| |\ \ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | | | Removed NGX_OPENSSL_QUIC macro, NGX_QUIC is enough.Ruslan Ermilov2021-09-14
| | | | | | | | | | | | |
| * | | | | | | | | | | | Merged with the default branch.Sergey Kandaurov2021-09-08
| |\ \ \ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | | | | QUIC: store QUIC connection fd in stream fake connection.Roman Arutyunyan2021-09-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously it had -1 as fd. This fixes proxying, which relies on downstream connection having a real fd. Also, this reduces diff to the default branch for ngx_close_connection().
| * | | | | | | | | | | | | Merged with the default branch.Sergey Kandaurov2021-09-01
| |\ \ \ \ \ \ \ \ \ \ \ \ \
| * \ \ \ \ \ \ \ \ \ \ \ \ \ Merged with the default branch.Sergey Kandaurov2021-07-15
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \
| * \ \ \ \ \ \ \ \ \ \ \ \ \ \ Merged with the default branch.Sergey Kandaurov2021-05-28
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \
| * \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Merged with the default branch.Sergey Kandaurov2021-04-16
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \
| * \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Merged with the default branch.Sergey Kandaurov2021-03-30
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | | | | | | | | | Core: fixed build with BPF on non-64bit platforms (ticket #2152).Vladimir Homutov2021-03-23
| | | | | | | | | | | | | | | | | | |
| * | | | | | | | | | | | | | | | | | Merged with the default branch.Sergey Kandaurov2021-03-10
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \
| * \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ Merged with the default branch.Sergey Kandaurov2021-02-17
| |\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \
| * | | | | | | | | | | | | | | | | | | | QUIC: ngx_quic_bpf module.Vladimir Homutov2020-12-25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The quic kernel bpf helper inspects packet payload for DCID, extracts key and routes the packet into socket matching the key. Due to reuseport feature, each worker owns a personal socket, which is identified by the same key, used to create DCID. BPF objects are locked in RAM and are subject to RLIMIT_MEMLOCK. The "ulimit -l" command may be used to setup proper limits, if maps cannot be created with EPERM or updated with ETOOLONG.