Change8

v3.5-dev4

Breaking Changes
📦 haproxyView on GitHub →
5 breaking23 features🐛 47 fixes🔧 34 symbols

Summary

Version 3.5-dev4 introduces significant refactoring of internal data structures for proxies and servers, enhancing performance and maintainability. It also includes numerous bug fixes across various modules, improved error handling, and new features like rate limiting for haload and enhanced header filtering in halog.

⚠️ Breaking Changes

  • The `proxies_list` has been converted to a doubly linked struct list and renamed to `all_proxies`. Code relying on the old structure or name will need to be updated.
  • The `servers_list` has been converted to a doubly linked struct list and renamed to `all_servers`. Code relying on the old structure or name will need to be updated.
  • The `fdinfo` structure has been removed. Code that directly accessed `fdinfo` will need to be refactored.
  • It is now possible to have one `fdtab` per thread-group. This changes how file descriptors are managed and may require adjustments in code that assumes a single global `fdtab`.
  • It is now possible to have one `polled_mask` per thread group. This changes how polling is managed and may require adjustments in code that assumes a single global `polled_mask`.

Migration Steps

  1. Rename `proxies_list` to `all_proxies`.
  2. Rename `servers_list` to `all_servers`.
  3. Refactor code that directly accessed `fdinfo`.
  4. Adjust code that assumes a single global `fdtab` to account for per-thread-group `fdtab`.
  5. Adjust code that assumes a single global `polled_mask` to account for per-thread-group `polled_mask`.

✨ New Features

  • Added rate limiting support to `haload` using the `-R` option.
  • Added support for filtering on header capture values using `-hdr-match` in `halog`.
  • Added a way to rate-limit TLSv1.3 KeyUpdate.
  • Added the `tune.fd.tables` option for managing file descriptor tables.
  • Added support for per-thread-group FD tables, allowing one `fdtab` per thread-group.
  • Allowing one `polled_mask` per thread group.
  • Created the poller pipes before creating the thread.
  • Listeners do not always balance connections across thread groups.
  • Backend does not always allow takeover across thread groups.
  • Listeners properly handle unshared fd tables between tgroups.
  • CLI transfers sockets with unshared file descriptor tables.
  • Only allow epoll when each tgroup has its fd table.
  • Have one pool of free pipes per thread group.
  • Make "show fd" aware of per-thread-group FD tables.
  • Report the current tgid in "debug dev fd".
  • Report the tgid along the FD in "show sess".
  • TCP nameserver tasks are now stuck to the resolvers' thread.
  • Servers do not close other thread groups' connections at deinit.
  • Resolvers do not close another thread group's socket at deinit.
  • Do not use another thread group's listener FD for QUIC.
  • Do not retrieve src/dst on another thread group's FD.
  • Propagate error from load_echkeys() in ech.
  • Reject an ECH store with no usable private key in ech.

🐛 Bug Fixes

  • Protected "show errors" against backend deletion in proxy.
  • Fixed use-after-free upon updating task expiration in `haload`.
  • Set default thread count to 1 in `haload`.
  • Fixed display glitches by flushing stdout in summary in `haload`.
  • Correctly spelled HAVE_VANILLA_OPENSSL in ssl.
  • Handled non-application data record while splicing in ssl.
  • Put CO_ER_SSL_KEYUPDATE at the right place in ssl.
  • Fixed CPU topology detection by omitting forced "nbthread" in `haload`.
  • Fixed the length moved when removing a header value in `http-htx`.
  • Did not parse a non-HTTP check buffer as an HTX message in `http-fetch`.
  • Rejected a negative capture id in capture.{req,res}.hdr in `http-fetch`.
  • Fixed a NULL channel dereference in smp_fetch_body() in `http-fetch`.
  • Fixed an out-of-bounds read in http_get_host_port() on empty host in `http`.
  • Checked the trash allocation in http_scheme_based_normalize() in `http-htx`.
  • Reported the right error position on authority/host mismatch in `h1`.
  • Did not use a block pointer to roll back a partial HTX conversion in `h2`.
  • Did not use a block pointer to roll back a partial HTX conversion in `h3`.
  • Fixed a one-byte over-read in the client-side cookie parser in `http-ana`.
  • Fixed a double free of the regex on a rule parsing error in `http-act`.
  • Fixed a double free of the map reference on a parsing error in `http-act`.
  • Restored the response buffer state in the early-hint action in `http-act`.
  • Worked on a copy of the sample in del-headers-bin in `http-act`.
  • Rejected a negative capture id in the capture actions in `http-act`.
  • Checked the strdup() of the "lf-string" http reply argument in `http-htx`.
  • Performed raw copy for messages of same size in htx_copy_msg() in `htx`.
  • Transferred HTX_FL_EOM flag on success in htx_append_msg() in `htx`.
  • Fixed release of a failed "set-cookie-fmt" redirect rule in `http-rules`.
  • Did not read past the end of the input around the match loop in `slz`.
  • Used the exact switch cost for the last literals of a block in `slz`.
  • Did not append a block to an already finished stream in `slz`.
  • Fixed the adler32 accumulators signedness on 32-bit in `slz`.
  • Avoided undefined shifts when building the word byte by byte in `slz`.
  • Checked the available room before encoding dict values in `peers`.
  • Rejected the deprecated protobuf group wire types in `sample`.
  • Locked the OCSP response around reads in the stapling callback in `ssl/ocsp`.
  • Fixed QUIC on server-template in `server`.
  • Duplicated server alt_proto in srv_settings_cpy() in `server`.
  • Ensured check-reuse-pool is init in srv_settings_init() in `server`.
  • Fixed check reuse-pool in srv_settings_cpy() in `server`.
  • Fixed the duplicate detection in the lookup shortcut in `cebtree:private`.
  • Used the current argument to parse the FD spec in "show fd" in `cli`.
  • Did not reject the "/<fd>" form of "show fd" in `cli`.
  • Fixed rate limit bypass during stream errors in `haload`.
  • Fixed the build on platforms without MSG_CMSG_CLOEXEC in `listener`.
  • Propagated error from load_echkeys() in `ech`.
  • Rejected an ECH store with no usable private key in `ech`.
  • Preserved shared.tg pointer on 'clear counters all' in `counters`.

Affected Symbols