ingress-nginx-helm/rootfs/etc/nginx/lua
Artur Juraszek 3a887f28e8
Properly support a TLS-wrapped OCSP responder (#10164)
Current implementation of OCSP stapling makes use of the DNS caching machinery[^1],
which results in resty.http not seeing the actual host name of the OCSP responder.
On HTTP level, this is already mitigated via overriding the Host header, but
if a given responder operates on a HTTPS endpoint (a setup which, admittedly, isn't
very popular due to its chicken-and-egg caveats involved but is nonetheless legal[^2])
the connection will fail to be established. A relevant (and a bit redacted) excerpt from logs:

  2023/07/02 18:13:23 [info] 112#112: *29039 [lua] dns.lua:32: cache_set(): cache set for 'my.ocsp.responder' with value of [10.1.2.3, 10.4.5.6, 10.7.8.9] and ttl of 30., context: ngx.timer, client: 127.0.0.1, server: 0.0.0.0:442
  2023/07/02 18:13:23 [error] 112#112: *29039 lua ssl certificate does not match host "10.1.2.3", context: ngx.timer, client: 127.0.0.1, server: 0.0.0.0:442
  2023/07/02 18:13:23 [error] 112#112: *29039 [lua] certificate.lua:143: fetch_and_cache_ocsp_response(): could not get OCSP response: certificate host mismatch, context: ngx.timer, client: 127.0.0.1, server: 0.0.0.0:442

[^1]: https://github.com/kubernetes/ingress-nginx/blob/ebb6314/rootfs/etc/nginx/lua/certificate.lua#L81
[^2]: https://datatracker.ietf.org/doc/html/rfc2560#appendix-A.1.1
2024-02-27 05:56:40 -08:00
..
balancer Add annotation for setting sticky cookie domain (#9088) 2022-09-28 07:28:37 -07:00
plugins Darwin arm64 (#8399) 2022-04-06 13:46:26 -07:00
test add new summary metric: ingress_header_seconds (#8726) 2022-06-22 12:59:43 -07:00
util Enable session affinity for canaries (#7371) 2021-07-29 14:23:19 -07:00
balancer.lua Add missing space to error message (#9069) 2022-09-20 04:03:21 -07:00
certificate.lua Properly support a TLS-wrapped OCSP responder (#10164) 2024-02-27 05:56:40 -08:00
configuration.lua Spelling 2020-12-15 16:10:48 -05:00
global_throttle.lua Add Global Rate Limiting support 2021-01-04 17:47:07 -05:00
lua_ingress.lua Allow preservation of trailing slashes on TLS redirects via annotation. (#7144) 2021-05-23 08:51:38 -07:00
monitor.lua add new summary metric: ingress_header_seconds (#8726) 2022-06-22 12:59:43 -07:00
OWNERS Automatically add area labels to help triaging (#7387) 2021-07-22 17:29:16 -07:00
plugins.lua fix to really execute plugins in order (#8018) 2021-12-07 08:01:02 -08:00
tcp_udp_balancer.lua Remove localhost calls from external names 2021-04-30 16:49:35 -03:00
tcp_udp_configuration.lua Scanning port 10247 lead to tcp connection 502 error (#9815) 2023-07-16 13:45:06 -07:00
util.lua fixed some typos 2020-07-21 22:02:23 +02:00