# Changelog

URL: https://scalws.com/docs/changelog/
Source: `CHANGELOG.md` in the ScalWS repository

All notable changes are recorded here. Format: [Keep a Changelog](https://keepachangelog.com/).

## [1.1.1] - 2026-11-23

### Changed
- The access log gains a last field `tls_client` on every line of the `text` format, with or
  without mutual TLS (`-` when the connection has no client certificate); a parser that reads
  the format by position sees one more field.
- `scalwsctl upstreams`: the `ACTIVE` column (requests in flight) is renamed `INFLIGHT`.
  The new `HEALTHY` and `ACTIVE` columns show whether the member takes traffic and its
  active health (`up`, `down`, `unknown`, `off`). In pools with `active_health`,
  `FAILURES` shows consecutive failed probes and the new `PFAIL` column the consecutive
  passive failures; other pools keep passive failures in `FAILURES` and show `-` in
  `PFAIL`. Scripts reading the table by column name must follow the new columns; `--json`
  only gains fields (`healthy`, `active`, `active_fails`).

### Added
- ScalPanel mode: site.json `runtime` (`kind` php, node, python, ruby, container or static,
  `version`, `upstream`, `entry`, `detected`). node, python, ruby and container serve the
  files under `document_root` and proxy the rest to `upstream` (a socket inside the site
  folder or a loopback address), WebSocket upgrades included; static serves files only;
  `php` becomes optional for the other kinds; `scalwsd --version` lists `runtime` in
  `site-json-fields`. PHP source is never sent by the other kinds (403, or 404 without
  `deny_dotfiles`). Proxy: `files_first` serves existing files before proxying; static and
  `files_first`: `deny_suffixes`.
- Static: current MIME types for `.wasm`, `.mjs`, `.avif`, `.webp`, `.webmanifest`, `.woff2`,
  `.woff`, `.map`, `.ics`, `.vcf`, `.apk`, `.heic`, `.jxl`, `.md`, `.yaml`, `.yml` and `.toml`
  (an `.htaccess` `AddType` still wins), unknown extensions as `application/octet-stream`
  with `nosniff`; `scalwsd --mime-types` prints the table as JSON and `--version` gains
  `mime-table: 1`.
- Respond: `body_file` serves a page from a file (a regular file, at most 1 MiB, not a link)
  read when the configuration is loaded and again on every reload, never per request; a
  missing or oversized file fails the start or reload naming the field; `scalwsd --version`
  lists `respond_file`.
- Upstream pools: `hash: {by: cookie, key_file}` keys the affinity cookie with the bytes of a
  shared file (same rules as the `sticky` key file), so nodes and restarts agree on the
  cookie of a member; `scalwsd --version` lists `affinity_key`.
- ScalPanel mode: upstream pools take `active_health`, which probes every member with `GET path` (optional `host`,
  fixed `headers`, `interval`, `timeout`, `fails`, `passes`, accepted `status` range).
  A member down by its probes takes no requests, and a pool with no healthy member
  answers 503 (no fallback to an ejected member as in pools without `active_health`).
  Members start up, kept members keep their state across reloads, and probes never carry
  client data. Probes have connections of their own, never reused by requests, and start
  only once the generation that built the pool is applied. The admin API adds `healthy`,
  `active`, `active_fails` and `since_unix_ms` per member, and the gauge
  `scalws_upstream_active_health{pool, member}` exists for pools with `active_health`
  only (dropped when a member leaves or `active_health` is removed).
- ScalPanel mode: in pools with `active_health`, a member whose probes bring it back up (down to up
  after `passes` successes) leaves a running passive ejection at once; it stays on
  probation, so one failed request ejects it again. A probe success on a member the probes
  never saw down does not end an ejection (an outage shorter than `fails` probes runs its
  cooldown as before). Pools without `active_health` are unchanged (ADR-0049).
- ScalPanel mode: `backends` entries take an `id` (`[a-z0-9-]{1,32}`, unique in the route;
  default: the pool name; not on `status` entries), and a pool runtime takes
  `balance: weighted` (default) or `balance: failover` (the first healthy backend in list
  order, for a local pool with a peer pool behind it). With `balance` set, or a pool with
  `active_health`, backends whose members are all unhealthy are skipped; when none is
  healthy and a pool has `active_health` the route answers 503, otherwise the ADR-0049
  fallback still sends the request. Routes without these keys choose as in 1.1.0. A pool
  listed twice in one route's `backends` is a warning (an error once `id` or `balance` is
  used).
- ScalPanel mode: pool members take `backup: true` (also in `PUT /v1/upstreams/{name}`).
  A backup member takes requests only while every non-backup member of its pool is
  unhealthy; when none is healthy, pools with `active_health` answer 503 and others keep
  the ADR-0049 fallback. At least one member must not be a backup; `unix:` members cannot
  be backups. The admin API shows `backup: true` on such members. `scalwsd --version`
  lists the edge features `backup_members` and `pools`.
- ScalPanel mode: a pool runtime takes `retry: {on, max, only_idempotent}` (`on`:
  `connect_error`, `timeout`, `status_5xx`; `max` 0 to 5, default 1; `only_idempotent`
  default false). It replaces the pools' `retries` for that route: an attempt is retried on
  an untried member of the same pool, then on the next backend. A connect error is retried
  for any method (GET, HEAD and OPTIONS only with `only_idempotent`); a written request
  (timeout, broken connection, 502 to 504) only for GET, HEAD, OPTIONS, PUT and DELETE
  (GET, HEAD and OPTIONS with `only_idempotent`). A written POST or PATCH is never sent
  again. Routes without `retry` keep ADR-0049's pool retries.
- ScalPanel mode: on a route with `retry.only_idempotent: true`, the resend of a request
  that was written on a kept-alive connection the member had closed (ADR-0043) applies to
  GET, HEAD and OPTIONS only; a written PUT or DELETE gets the error answer. A request
  written on such a connection counts as written for `retry` when the reconnect fails,
  never as `connect_error`. Routes without `retry` resend as before.
- ScalPanel mode: a pool runtime takes `write_backend: <index into backends>`. Writes (any
  method except GET, HEAD, OPTIONS and TRACE) and WebSocket upgrades go only to that
  backend, ignoring `balance` and weights. When its pool has `active_health` and no
  healthy member, a write gets 503 and never reaches another backend; a pool without
  `active_health` keeps its passive fallback. A write is retried only on another member of
  that pool, only after a connect error (with `retry`: only when `on` has `connect_error`
  and `only_idempotent` is not set), and a written PUT or DELETE is not resent after a
  stale kept-alive connection. It must name a pool backend.
- ScalPanel mode: a pool runtime takes `sticky: {cookie, ttl, key_file}`. The answer sets
  a cookie naming the backend `id` and member, signed with HMAC-SHA256 under the key file
  every edge shares (32 to 1024 bytes, owned by root or the service user, no group or other access (`0600`);
  `scalwsctl check` reads it). A valid cookie for a healthy backend keeps it; a forged,
  unknown or unhealthy one gets the normal choice and a new cookie. Writes ignore it with
  `write_backend`, `balance: failover` ignores it with a warning. `scalwsd --version`
  lists `sticky`.
- ScalPanel mode: a pool runtime takes `read_only: true`. Every write (any method except
  GET, HEAD, OPTIONS and TRACE) and WebSocket upgrade gets `read_only_response`
  (`{status, body, retry_after}`, default 503 with an empty body; status 400 to 599, body
  at most 4 KiB, `retry_after` 1 to 86400 s) with `Cache-Control: no-store`, before its
  body is read and without reaching any upstream; reads are served. Once the reload that
  sets it has returned (`scalwsctl reload`, `POST /v1/reload` or `scalws-controller
  reload`; not `SIGHUP`), every new request sees it, also on HTTP/1 keep-alive and HTTP/2
  connections opened before, and every WebSocket tunnel the route's runtime opened before
  (through any earlier generation) is closed. Only a success answer means the fence is in
  place. `scalwsd --version` lists `read_only`.
- scalws-controller: `reload` (`POST /reload`) answers `200` once the new generation
  serves alone (old instances drained and gone, at most 180 s). It answers `409` when the
  generation is rolled back or replaced (it used to answer `200` at once), and `504` when
  the generation has not taken over within 180 s (the roll goes on). It used to answer as
  soon as the generation was created. scalws-console's Apply waits up to 200 s for it: it
  restores the previous file only on `409` or a refused configuration, and on `504` or its
  own timeout it reports the reload as still in progress and keeps the new file.
- ScalPanel mode: runtime `type: upstream_status` answers `GET`/`HEAD` with the health of
  every member of every pool the application's proxy runtimes use, as a JSON array of
  `{app, pool, member, healthy, since, fails, active, ejected}` (`cache-control:
  no-store`, no request data; other methods 405). For the agent's loopback probe
  listener: a route reachable from a non-loopback listener (by its `listeners`, else the
  application's) is a warning. `scalwsd --version` lists `upstream_health`.
- ScalPanel mode: route `listeners: [peer]` applies a route only to requests that arrived
  on the named listeners; such a route is tried before routes of the same path without
  it. The `X-ScalPanel-Via` route for forwarded requests is scoped to the node link, so a
  public client sending the header reaches the main route. Unknown or repeated names are
  errors, a listener the application is not on is a warning. `scalwsd --version` lists
  `replica`.
- ScalPanel mode: listeners take `tls.client_ca_file` (a PEM file of CA certificates) and
  `client_names` (exact DNS names, at most 64, no wildcards): every client must present a
  certificate from that CA, and with `client_names` one of its DNS names must equal a listed
  name. A connection without a valid certificate fails in the TLS handshake before any HTTP
  byte is read. Such listeners send no TLS 1.3 tickets and keep no session cache. Adding or
  removing `client_ca_file` needs a restart; a changed CA file or `client_names` applies on
  reload to new handshakes. `client_names` empty is a warning (any certificate of the CA
  passes). Not with `http3`. The access log gains a last field `tls_client` (the matched
  name, the first DNS name, or `-`); a parser that reads the `text` format by position sees
  one more field. `scalwsd --version` lists `peer_tls`.
- ScalPanel mode: pools take `tls.client_cert_file` and `client_key_file` (a PEM chain and
  its unencrypted key, together, only with `scheme: https`), presented to every member and
  to the probes, for a peer edge that requires a client certificate. The pair is checked
  when the pool is built (a key that does not match, or an encrypted key, is an error that
  names `client_key_file` without quoting the key); a reload rebuilds the pool when either
  file changed, and a world-readable key is warned about.
- ScalPanel mode: `scalwsd --version` lists the edge features of this release:
  `access_log affinity_key backup_members forwarded_for gzip max_upgraded networks peer_tls
  pools prefix_proxy read_only referer remove_cookies replica respond_file route_order
  sticky upstream_health`. The new ones: `replica` (`active_health`, `backends[].id`,
  `balance`, `retry`, `write_backend`, route `listeners`), `sticky`, `upstream_health`,
  `peer_tls` and `read_only`, plus `affinity_key`, `backup_members`, `pools` and
  `respond_file`. ScalPanel turns replicas on only when the line lists what it needs.
- ScalPanel mode: scalws-console accepts the new keys: its form lists them in order (pool
  `id`, `active_health`, `retry`, `sticky`, `write_backend`, `read_only`, `client_ca_file`,
  `client_names`, `client_cert_file`, `client_key_file` and the rest) and its draft checks
  confine the new file paths (`client_ca_file`, `client_cert_file`, `client_key_file`,
  `hash.key_file`, `sticky.key_file`, `body_file`) to the configuration directory like
  certificate files.
- Docs: the [replicas guide](https://scalws.com/docs/guide/replicas/) (two-node pattern, sticky key file,
  `write_backend`, fencing and the reload boundary, loop prevention, the node link),
  ADR-0055, an amendment to ADR-0049 and threat model rows. The fencing text corrects the
  design draft: `read_only` applies per request on every stack, so an already open
  connection is fenced at its next request without GOAWAY.

### Security
- Console: an Apply whose generation another writer's reload replaced (a controller `409`
  that is not a rollback, or a health check that finds a newer generation) no longer
  writes the previous file back over that writer's file or reloads it; it restores only
  while the file still holds its own draft. Before, a console Apply racing a fencing
  reload could undo `read_only` (audit replica R2).
- TLS: a reload that revokes a node of a mutual-TLS listener (a new `client_ca_file`, or
  `client_names` without it) also refuses every further request on that node's open
  connections with `403` (`client_cert_revoked`): HTTP/1 closes the connection, HTTP/2
  answers `403` per stream until the idle timeout ends it. Upgraded tunnels already open
  are not ended. Before, a connection opened before the revocation kept the peer link
  (audit replica R3).

## [1.1.0] - 2026-11-19

### Licence
- Changed from Apache-2.0 to AGPL-3.0-only starting with 1.1. The `LICENSE` file is the
  GNU AGPL v3 text and is installed with the deb, rpm and apk packages (deb also gets a
  DEP-5 `copyright`). Bundled third-party code under `third_party/` keeps its own licences.
  Dependency licences: [docs/licences/dependencies.md](https://scalws.com/docs/reference/dependency-licences/).

### Security
- Dependencies: rustls 0.23.46 (RUSTSEC-2026-0346, RUSTSEC-2026-0347, RUSTSEC-2026-0348,
  RUSTSEC-2026-0349), rustls-webpki 0.103.17 (RUSTSEC-2026-0382), webpki-root-certs
  1.0.12 (RUSTSEC-2026-0383), tokio 1.54.1 (RUSTSEC-2026-0386) and rustix 1.1.6
  (RUSTSEC-2026-0486). kube 4.0 and k8s-openapi 0.28 (scalws-ingress) drop the
  unmaintained chrono (RUSTSEC-2026-0543) and serde_yaml with unsafe-libyaml
  (RUSTSEC-2024-0449); kubeconfig YAML is now read by serde-saphyr and Kubernetes times
  are `jiff` timestamps. The k8s-openapi API baseline moves from Kubernetes 1.31 to 1.32
  (`v1_31` is no longer offered). `cargo deny check` passes with no ignore entries.

### Security: audit run 9
- .htaccess: `%{REMOTE_ADDR}` of an IPv4 client of a dual-stack `[::]` listener is its
  IPv4 address, as PHP, the logs, `X-Forwarded-For` and `Require ip` see it. It was
  `[redacted address].b.c.d`, so a `RewriteCond %{REMOTE_ADDR}` deny rule written for the IPv4 form
  did not match. The client address is now canonical for every rule and limit (N1).
- Cache: the stale-while-revalidate refresh of an `Options +Indexes` listing applies the
  request's listing filter (`IndexIgnore`, `<Files>`/`<FilesMatch>` denials,
  `deny_paths`). It listed every entry and stored that page for every visitor, so later
  visitors saw the names, sizes and dates of hidden files (N2).

### Security: audit edge
- Console: a draft's `server.networks.<name>.file` and `server.geoip.database` must be
  below the configuration directory, unless the server's configuration names the same
  file (the database also at `/var/lib/scalws/geoip/country.mmdb`). The draft check read
  them as root, and its errors told a developer account whether a file existed and which
  line was not an address (N1).
- Routes: a request whose path holds an encoded slash (`%2F`) and whose decoded path would
  select another route answers 400, in both route orders and for every route table. nginx
  selects the location on the decoded path; here `/sp-ab12%2Fa.jpg` missed ScalPanel's
  preview image route and its `referer`, and `/app%2Fadmin/x` reached an open `/app/`
  route instead of `/app/admin/` and its allow list. A path above the root once decoded
  (`/..%2fx`) now answers 400 instead of 404 (N2).
- Cache: the stale-while-revalidate refresh of a proxy route applies the route's
  `request_headers` (`remove_cookies` included), `rewrite.host` and `rewrite_location`
  like the request. It sent the visitor's withheld cookies and the unrewritten Host to the
  upstream and stored that answer for everyone (N3).
- .htaccess: a local `ErrorDocument` is fetched with the `request_headers` of its route
  (`remove_cookies` included), as a request for it is; the site got the visitor's
  withheld cookies through it (N4).
- .htaccess: a local `ErrorDocument` on a route with `referer` keeps the plain error for a
  Referer the route refuses; a foreign page could embed the protected document through
  any URL that ended in that status (N5).

### Security: audit run 7
- Sandbox: an instance writes only `cgroup.procs` of `<base>/server`, the cgroup every
  instance shares; its `cgroup.kill` and `cgroup.freeze` (which killed or froze every
  instance, past the Landlock signal scope) are refused (N6).
- Panel mode: an automatic name (`www.`, `ipv4.`, `webmail.`, `cpanel.` plus a domain)
  stays with the account that owns the domain; another account's server name or alias
  equal to it is left out, with a warning naming that account and the name (N7).

### Security: audit scalpanel
- Cache: `bypass_cookies` and `bypass_query` (every response cache: ScalPanel mode, panel
  modes and YAML) also match names as PHP reads them (`.`, a space and an unclosed `[` read as `_`, query names decoded, an
  array index dropped; cookie names also decoded, as PHP before 8.1.11 and 8.0.24 did). A
  cookie `comment.author_x` or `wordpress.logged.in_x` reached PHP under its bypass name
  while the page was stored and served to every visitor (N1).
- Cache: URLs remembered as not storable (hit-for-pass) take a sixteenth of the cache
  memory, weighed by length, instead of up to 100 000 keys of up to 8 KiB outside it (N2).
- .htaccess: `IndexIgnore` (with `IndexIgnoreReset`) hides names from an
  `Options +Indexes` listing (ScalPanel mode and any application with `.htaccess`); it was
  ignored with a warning, so names the owner hid were listed (N4).
- Compression: the variant cache shared by all applications keys a file also by its
  document root and its change time (ctime, which nobody can set), so an inode number
  freed and reused with the same size and modification time no longer serves the first
  file's compressed bytes (N7).
- Static: a directory listing of a PHP application (ScalPanel mode and any other) leaves
  out the names the static half never serves as files: PHP source a request refuses
  (`.inc`, `.phtml`, `.php3` to `.php8`, `.phar`, `.phps`) and the PHP extensions' scripts,
  so `.php` files are no longer listed (N8).
- PHP: an `ErrorDocument` whose target falls back to the front controller passes the
  controller's `.htaccess` checks (access rules, logins, `php_flag engine off`) as a
  request for it would, and the PHP handler answers 404 instead of running a fallback
  `.htaccess` did not approve for its own controller (ScalPanel mode and any application
  with `.htaccess` and a `front_controller`). A missing error page let any visitor run a
  controller the owner had turned off, denied or put behind a login. In YAML, a route whose
  PHP runtime has its own `front_controller`, in an application with `.htaccess`, is now
  checked against that controller's `.htaccess` rules; before, only the default runtime's
  controller was checked, and the route's ran unchecked (N5).
- .htaccess: `<Files>` globs are charged to the request's scan budget, and to a listing's,
  by their worst case (name length times pattern length), as `<FilesMatch>` regular
  expressions are (every mode with `.htaccess`). Long globs made every request and every
  listed name run them uncharged (N3).
- .htaccess: a directory level looked up again (every level on every request with
  `htaccess_recheck: 0s`, as in ScalPanel mode; any level once its window passed) is
  charged to the request's scan budget per path component, as ADR-0031 said. A walk of
  d levels costs (d + 1)² x 256 bytes of the 8 MiB budget: a request that walks a path of
  127 levels or more twice (one internal rewrite) or of about 104 levels three times
  answers 500 instead of making thousands of uncharged lookups (N6).

### Added
- ScalPanel mode: `scalwsd` serves one ScalPanel website from its `site.json` (contract
  version 1) when it runs as `scalpanel-webserver` (the path as its argument, else
  `SCALPANEL_SITE_CONFIG`, else `/etc/scalpanel-site/site.json`), with `--site-json <path>`,
  or with `SCALPANEL_SITE_CONFIG` set and no explicit `-c`. Every field maps onto ordinary
  configuration keys; unknown fields are ignored, the file is read with a 1 MiB cap, and
  every error is one line starting `site.json:` with exit status 1. In this mode there is no
  admin socket, metrics listener, cgroups, optimizer, AI or ACME, and the runtime directory
  is `<temp_dir>/scalws`. The old `vpanel` names are not read. See
  [ScalPanel mode](https://scalws.com/docs/guide/scalpanel/).
- ScalPanel mode: `required_header` becomes `server.required_header {name, value,
  status}`: a request without exactly one header with exactly that value (compared in
  constant time) gets 421 before routing, `.htaccess`, files, the cache or PHP, counted as
  `required_header`. An HTTP/1.0 request without `Host` is routed by the address it
  reached in such configurations.
- ScalPanel mode: HTTPS through the edge. `server.client_address.forwarded_proto` (on in
  ScalPanel mode) takes the scheme from one `X-Forwarded-Proto` value of a peer in
  `trusted_proxies` for PHP (`HTTPS`, `REQUEST_SCHEME`, `SERVER_PORT`), `.htaccess`
  `%{HTTPS}`, absolute redirects and `https_redirect`; other peers' header is removed.
- ScalPanel mode: `security.dotfiles: forbidden` answers dot paths (but `/.well-known/`)
  403 before any file is looked at (`deny_dotfiles`), and `security.symlinks`
  (`follow` default, `owner_only` as Apache's `SymLinksIfOwnerMatch`, `none`) checks links
  for static files, scripts, index files, `.br`/`.gz` siblings and `.htaccess` files; a
  path without links costs the same single `openat2`.
- ScalPanel mode: `.htaccess` changes apply to the next request (`htaccess_recheck`, 0 to
  60 s, default 2 s, `0s` in ScalPanel mode); `Options +Indexes` lists a folder without an
  index file (escaped, without dotfiles, refused links or denied names, at most 10 000
  entries and 2 MiB) and `-Indexes` answers 403; `indexes: not_found|forbidden` for folders
  without either (`forbidden` in ScalPanel mode); `AddType` with a non-PHP type sets the
  `Content-Type` of static files, `RemoveType` removes it. Every block ScalPanel 0.1.38
  writes (directory privacy, error pages, redirects, directory listing, MIME types) is
  tested with the generator's text in both marker spellings
  ([ADR-0031](https://scalws.com/docs/adr/0031-htaccess/#scalpanel-managed-blocks-11)).
- ScalPanel mode: log files. `server.logging.access_file` (Apache combined format, `%h` the
  resolved client, `%u` the `.htaccess` Basic user, escaped as Apache does) and
  `server.logging.error_file` (warnings and errors, one line each), from `logs` in
  `site.json`. Writer threads with bounded queues (dropped lines in
  `scalws_log_lines_dropped_total`), one `write(2)` per line, reopened after rotation (moved,
  deleted or truncated file) and on `SIGUSR1`, retried every second while the file cannot
  be opened, never through a symbolic link (also not a linked prefix such as `/var/run`:
  use the real path). See [Log files](https://scalws.com/docs/guide/logging-metrics/#log-files).
- ScalPanel mode: `server.limits.request_timeout` bounds a whole request from the first
  byte of its head (`limits.timeout_seconds`, at most 24 h): 504 without a response, 408
  while the body still arrives, a dynamic response being sent is cut; static file bodies
  and cache hits are not cut. Warnings when `php.max_execution_seconds` is 0 or longer, and
  for a managed pool without `terminate_timeout`.
- ScalPanel mode: `runtime.extensions` (PHP) lists the script extensions (`php.extensions`;
  only the last extension counts, `x.html.jpg` is an image, a name with a line break or NUL
  never runs); PHP source that does not run answers 403. Without it a YAML application
  keeps the 1.0 list.
- ScalPanel mode: `front_controller` from `site.json`: a path that is neither a script, a
  file nor a folder with an index runs the controller with the original URI and query and
  no `PATH_INFO`, after `.htaccess` had its say; dotfiles, refused links, denied paths and
  `-Indexes` folders never reach it; a missing controller is 404.
- ScalPanel mode: `compression` in `site.json` (`static` by default, `all`, `types`,
  `off`) and 8 MiB for compressed variants; see the `Compression:` entry.
- ScalPanel mode: page cache from `cache` in `site.json` (`ttl_seconds`, `stale_seconds`,
  `memory_mb`, `bypass_cookies`, `bypass_paths`, `bypass_query`): PHP responses only
  (`cache.static_files: false`, a new application key, default `true`), memory only, every
  access check before the lookup; `.htaccess` edits of caching headers or `ExpiresActive
  On` bypass it for that folder; `""` in `bypass_cookies` bypasses any request with a
  cookie. See [caching](https://scalws.com/docs/guide/caching/#scalpanel-mode).
- ScalPanel mode: `server.loopback_healthz` (on in ScalPanel mode) answers `GET`/`HEAD
  /healthz` from a loopback TCP peer with 200 `ok` or 503 `draining` (`text/plain;
  charset=utf-8`, `Cache-Control: no-store`) before the required header, never for an
  address a proxy reports or on a PROXY-protocol listener, not logged.
- ScalPanel mode: `scalwsd --version` prints `site-json: 1` and
  `site-json-fields: front_controller,compression,cache` after the version.
- ScalPanel mode: `scalwsctl panel detect` prints `scalpanel` on a ScalPanel host (before
  any other panel) and `scalpanel-site` inside a website container; `panel enable`, `sync`
  and `disable` refuse there and change nothing, `panel status` reports the websites per
  web server, and the package's first install does not start ScalWS on such a host. See
  [ScalPanel hosts](https://scalws.com/docs/guide/control-panels/#scalpanel-hosts).
- ScalPanel mode: `packaging/scalpanel/` holds the site image recipe (`Dockerfile.example`:
  the static musl `scalwsd` as `/usr/local/bin/scalpanel-webserver` on ScalPanel's PHP site
  image, its entrypoint and sessions label kept, a `/healthz` health check) and the
  PHP-FPM settings; `tests/scalpanel/contract.sh` checks ScalPanel's contract against such
  an image, on amd64 and on arm64 (under qemu-user).
- ScalPanel mode: the `scalws-scalpanel` package for amd64 and arm64.
  `scripts/release-build-scalpanel.sh` builds the static musl `scalwsd` for both
  (`scalwsd-<version>-scalpanel.<n>-{x86_64,aarch64}-linux-musl`, with a `.sha256` each;
  amd64 profile-guided from the Alpine release build, arm64 in the same Alpine image built
  for arm64), checks that each is static and built for its machine
  (`scripts/check-static.sh --machine`) and prints `site-json: 1`, and packages one `.deb`
  per architecture (`packaging/scalpanel/nfpm.yaml`): the binary at
  `/usr/lib/scalws-scalpanel/scalwsd`, `/usr/bin/scalpanel-webserver` linking to it, the
  recipe and PHP-FPM settings as examples, no dependencies and no file of the `scalws`
  package, so both install side by side (`tests/packaging/scalpanel-deb.sh`). On arm64 the
  sandbox floor is not available (seccomp filters are x86_64 only): one warning, and the
  website is served.
- ScalPanel mode: the sandbox floor is `auto` when neither `SCALWS_SANDBOX_FLOOR` nor
  `--sandbox-floor` is given: the sandbox applies as `on` (Landlock writes only below
  `temp_dir`, the system temporary directory and the log folders, no program runs, the
  seccomp allowlist) where the kernel and the container allow it; otherwise one warning
  names what is missing and the website is served without it, never a failed start. An
  explicit floor, `off` included (also set but empty), wins and an `off` is logged once.
  PHP-FPM is started by the image, not by ScalWS, and is not under it. See
  [ScalPanel mode](https://scalws.com/docs/guide/scalpanel/#sandbox).
- Compression: gzip and brotli responses per application, `compression: {mode, types}`
  (`off` by default, `static`, `all`, `types`) and `server.compression.cache_bytes` (default
  32 MiB). `static` compresses only static files of text types, never a dynamic response,
  whatever its type (BREACH-safe); compressed static variants are kept in memory with strong
  ETags (`-gz6`, `-br5`), `.br`/`.gz` siblings are served, `Vary: Accept-Encoding` on every
  response of a compressed type, no compression for `Range` requests, bodies under 1 KiB or
  already-compressed types. Pure Rust encoders (`flate2` with `zlib-rs`, `brotli`). With
  `off` nothing changes (within 2 % of the build before); `static` measured 3.7x to 38x
  nginx's gzip at 1 CPU. A change of `compression` restarts the application's PHP runtime.
  See [ADR-0053](https://scalws.com/docs/adr/0053-response-compression/).
- Disk I/O limits: `resources.io` (`read_bps`, `write_bps`, `read_iops`, `write_iops`) next
  to `io_bandwidth` (shorthand for both byte rates; not together with `read_bps` or
  `write_bps`). The limit is written as cgroup v2 `io.max` on the topmost whole device of
  every path the tenant writes: application and runtime roots, runtime and temp
  directories, PHP upload and session directories, writable container mounts and the
  tenant user's home. Partitions map to their disk; dm and md devices are limited
  themselves, never their legs. Devices no longer used are reset to `max`. Paths without a
  block device (btrfs, overlay, ZFS, NFS) are reported by `scalwsd --check`, `scalwsctl
  limit` and the admin API (`io`, `io_enforced`, `io_unthrottled`, `io_devices`; the 1.0
  keys stay); tmpfs is not a gap. A gap a tenant can cause never fails `cgroups.mode:
  required`, which fails when the io controller is missing or a line is refused. Path
  resolution runs off the request path, bounded to 5 s per tenant. A rate of `0` is
  refused, rates below 1 MiB/s or 10 IOPS warn, and the run-time `io_bandwidth` override
  has a floor of 1 MiB/s. See [resources](https://scalws.com/docs/guide/applications/#disk-io-limits) and
  [ADR-0010](https://scalws.com/docs/adr/0010-cgroups-and-tenant-limits/).
- Real client address: `server.client_address` (`header`, `presets`, `presets_dir`,
  `file`). Peers of `trusted_proxies` report the client in `header` (`x-forwarded-for`,
  `forwarded`, `cf-connecting-ip`, `x-real-ip` or `true-client-ip`); `presets: [cloudflare]`
  trusts Cloudflare's networks, which report it in `CF-Connecting-IP`, so a site behind
  Cloudflare and a local load balancer needs no per-site setting. A peer in neither group
  is the client, whatever it sends, and single-value headers it sent are removed (also
  their underscore spellings). Unparseable entries make the client unknown (`::`); the
  `X-Forwarded-For` sent upstream starts at the resolved client. The shipped Cloudflare list
  dates from the release; `scalwsctl client-address update` (root, over TLS, strictly
  validated, `--force`, `--no-reload`) refreshes it into `presets_dir`, which must be
  root-owned. Peers in presets and imported networks are exempt from per-source
  connection and handshake limits. Panel mode imports `mod_remoteip` (cPanel,
  DirectAdmin) and nginx `real_ip` (DirectAdmin) settings into
  `/etc/scalws/panel/client-address.yaml` (Cloudflare's networks always become the
  preset; the panel's proxies join yours only under the same header); the Console's Server
  section edits `client_address`. The packages create `/var/lib/scalws/presets`. See
  [security](https://scalws.com/docs/guide/security/#trusted-proxies-and-proxy-protocol) and
  [ADR-0022](https://scalws.com/docs/adr/0022-trusted-proxies/).
- PHP pools: `php.fpm.pool` (`slowlog_timeout`, `terminate_timeout`, `backlog`,
  `idle_timeout`, whole seconds; `idle_timeout` runs the pool with `pm = ondemand`; slow
  traces go to the pool's own log), OPcache isolation between managed pools
  (`opcache.validate_permission` and `opcache.validate_root` on), `php.queue` (`max`,
  `wait`: a busy pool answers 503 with `Retry-After: 5`; metrics `scalws_php_queue_depth`
  and `scalws_php_queue_rejected_total`) and `php.values` (base PHP values of an external
  pool, sent as `PHP_VALUE` on every request, so that an application sharing the pool
  cannot leave its settings in a worker).
- `.htaccess`: HTTP Basic authentication (`AuthType Basic`, `AuthName`, `AuthUserFile`,
  `Require valid-user|user`, `Satisfy any|all`; bcrypt, `$apr1$`, `$6$`, `$5$`, `{SHA}`),
  `php_value`/`php_flag` for the allowlisted PHP keys, and `AddHandler`/`SetHandler`/
  `AddType`/`ForceType` lines that select PHP (cPanel MultiPHP included) or turn it off
  (`SetHandler none` in `uploads`: a PHP script there answers 403). New keys:
  `server.security.htaccess_auth_failures` (default 10 failed logins a minute per client
  and realm, then 429), `htpasswd_dirs` (where `AuthUserFile` may lie besides `root`),
  `php.versions` and `php.own_version`. Access rules now follow Apache 2.4: `Require` and
  `Order`/`Allow`/`Deny` are separate layers combined by `Satisfy`. Panel mode writes the
  cPanel `.htpasswds` and MultiPHP pools and the DirectAdmin password directories;
  `scalwsctl panel check` reports a `.htaccess` PHP version without a pool. See
  [the how-to](https://scalws.com/docs/howto/htaccess/).
- Panel mode: the rendered sites carry the pools' base PHP values and bound the requests
  to a pool by its `pm.max_children` (`php.queue.max`: a busy pool answers 503, not 504);
  `scalwsctl panel check` reports PHP pools of several accounts that share one OPcache (and
  PHP versions it could not read); on cPanel the sync watches every used PHP version's pool
  directory and `php.ini`.
- `server.tenant_users` (`warn` by default, `required`, `off`): tenants whose managed
  applications would run as the same Unix user (no `user`, or the same one) are reported
  at start, on reload, by `--check`, `scalwsctl check` and the console; `required` refuses
  such a configuration.

### Changed
- Routes: a path with an encoded slash (`%2F`) whose decoded form selects another route
  answers 400, in every configuration (audit edge N2). With prefix routes `/api` and
  `/api/v2`, 1.0 served `/api%2Fv2/x` from `/api`; 1.1 answers 400. The same holds for an
  exact route (`/api/health` and `/api%2Fhealth`). A path above the root once decoded
  (`/..%2fx`) answers 400 instead of 404. A path whose two forms select the same route is
  served as before.
- Logs: the JSON access event's `remote` writes an IPv4 client of a dual-stack `[::]`
  listener as IPv4 (`remote=203.0.113.5`, was `remote=::ffff:203.0.113.5`), as the
  `combined` and `scalpanel` lines do. Filters keyed on the `[redacted address]` form need the plain
  address.
- Proxy: `X-Forwarded-For` and `X-Real-IP` send an IPv4 client of a dual-stack `[::]`
  listener as IPv4, as logs and address checks see it (was `[redacted address].b.c.d`).
- Access log files: two `access_log` entries that name one file with different `format`s
  are a validation error naming both (the lines would interleave). The `combined` `%u` of
  an `access_log` file is the user of a `Basic` `Authorization` header when no `.htaccess`
  login set one (a route `basic_auth` user, as nginx `$remote_user`), not `-`.
- `server.compression.types` without `enabled: true` is a validation warning (it compresses
  nothing).
- Proxy: `forwarded_for` with an unknown value names the key in the error inside a route's
  `runtime` (serde named only the variant).
- Proxy: proxied responses carry `Server: scalws`; the upstream's `Server` (for example
  `Apache/2.4.62 (Debian)`) is dropped, as nginx hides it. A `101` upgrade answer keeps the
  upstream's `Server`. Responses of every other handler are unchanged.
- Redirects: with the Gateway fields (`scheme`, `host`, `port`, `path`, `prefix`),
  `keep_path: false` drops the request's query (it was ignored, so the query was kept), as
  nginx `return 302 https://$host:2096/;`. The ingress controller's `app-root` redirect
  sets `keep_path: true` and keeps the query as before.
- `server.security.per_ip.burst: 0` is accepted: a bucket of one request (nginx
  `limit_req` without `burst`; nginx `burst=N` is `burst: N+1`). It was a validation
  error. `requests_per_second: 0` is still refused.
- Route precedence is unchanged by default. The nginx order (exact, regex, prefix) is the
  new opt-in `route_order: nginx` (see "Added: edge features for ScalPanel" below);
  ADR-0050 is amended.
- ScalPanel mode: PHP request bodies over 64 KiB are spooled to an unlinked file in
  `site.json`'s `temp_dir`, no longer in `$TMPDIR` (else `/tmp`); with the sandbox in force
  `temp_dir` is writable. A `temp_dir` that is `/` or a top-level folder other than `/tmp`,
  or that is, holds or lies inside the document root, the `.htpasswds` folder or a log
  folder, is refused at start and on reload; a missing one is created (0700) at start and
  one that cannot take a file is one warning at start.
- `server.http1_server` and `server.upstream_client` take `own | hyper` and default to
  `own`: ScalWS's own HTTP/1 server and upstream client replace hyper's for HTTP/1
  connections and for proxied and managed applications. `experimental` is still accepted
  as an alias of `own`. To keep hyper, set `http1_server: hyper` and
  `upstream_client: hyper` (or `client: hyper` on a route); `upstream_client` is read at
  start-up, `http1_server` applies to connections accepted after a reload. HTTP/2, HTTP/3
  and TLS connections that negotiate another protocol are unaffected. Measured against
  nginx 1.31 (6 CPUs, 3 x 2 instances): respond 0.93 (hyper 0.86), proxy 0.98 (0.83),
  static-small 1.03 (0.98); see `docs/benchmarks/2026-11-12-xeon-1.0.0.md`. Audit:
  `docs/hardening/2026-11-13-own-http1-default-audit.md` (no confirmed vulnerability;
  chunk extensions are capped at 16 KiB per body, as hyper).

### Added: edge features for ScalPanel
ScalWS can run ScalPanel's edge from the configuration ScalPanel's generator writes, with
the generator's key names ([ScalPanel edge](https://scalws.com/docs/guide/scalpanel-edge/),
[ADR-0054](https://scalws.com/docs/adr/0054-edge-features-for-scalpanel/)). Every key is optional; a
configuration without them behaves and costs as before.
- Routes: `route_order: nginx` on an application tries exact, then regex (in order), then
  prefix routes, as nginx does; the default `scalws` order stays. Prefix paths may end with
  one `/` (`/sp-ab12/` matches `/sp-ab12/` and below, not `/sp-ab12`). `rewrite.path` may
  start with a capture (`$1`); a result without a leading `/` answers 400.
- Network sets: `server.networks.<NAME>` from a CIDR list `file` (at most 32 MiB, 1 000 000
  entries in all, read without following a final link) or from `countries` looked up in
  `server.geoip.database` (MaxMind DB format, read into memory); routes refuse or admit
  them with `deny_networks` and `allow_networks` (403, `reason="networks"`). Gauge
  `scalws_geoip_build_timestamp_seconds`. See [Network sets](https://scalws.com/docs/guide/network-sets/).
- `scalwsctl geoip update`: installs DB-IP's IP to Country Lite database (checked, written
  atomically as root, reloaded). "IP geolocation by DB-IP (https://db-ip.com), licensed CC
  BY 4.0". The packages ship `scalws-geoip-update.service` and a monthly
  `scalws-geoip-update.timer` (the 3rd at 04:00, up to one day of random delay), disabled.
- Hotlink protection: route `referer: {allow_empty, allow_own, hosts, status}` with nginx
  `valid_referers` parity; refusals carry `Cache-Control: no-store`, counted as
  `reason="referer"`. See [Hotlink protection](https://scalws.com/docs/guide/hotlink-protection/).
- `request_headers.remove_cookies`: named cookies are dropped from every `Cookie` line
  before the runtime, upgrade requests included.
- Proxy `forwarded_for: client`: one `X-Forwarded-For` value (the resolved client) and
  `X-Real-IP`; the default `chain` is the 1.0 behaviour.
- Proxy `rewrite_location` and `cookie: {path_prefix, domain: request_host}` for previews
  under a path prefix (nginx `proxy_redirect` and `proxy_cookie_path`).
- `server.security.per_ip.max_upgraded`: upgraded (WebSocket) tunnels per client address;
  beyond it `429` with `Retry-After: 1`, `reason="upgraded"`. Under scalws-controller each
  instance enforces its share.
- `access_log: {file, format}` on applications and routes, format `combined` or
  `scalpanel` (ScalPanel's nginx `log_format`, byte for byte); one writer thread, one
  bounded queue, `scalws_access_log_dropped_total`. Hard-linked log files are refused.
- `scalwsctl reopen-logs` and admin `POST /v1/logs/reopen`: reopen every log file, as
  `SIGUSR1`, on every instance under scalws-controller.
- `server.compression.enabled`, `types` and `min_length`: a server-wide default
  compression (the types plus `text/html`) for applications without their own;
  `min_length` (default 1024) replaces the fixed 1024 bytes.
- `scalwsd --version` prints a fourth line, `edge-features:`, with the finished features in
  alphabetical order: `access_log forwarded_for gzip max_upgraded networks prefix_proxy
  referer remove_cookies route_order`.
- The console knows the new keys: network sets and the country database are on the
  Security page; the others show with their help text where their parent is.

### Removed
- Plesk support: Plesk is no longer supported. Panel mode serves cPanel and DirectAdmin;
  `panel detect` prints `none` on a Plesk server and `panel enable plesk` is refused. The
  Plesk reader, its webmail PHP-FPM unit `scalws-panel-webmail.service` and its SELinux
  domain (`scalws_webmail_t`) are gone. A first install on a Plesk server changes nothing
  (no takeover, no start, no firewall rule) and says so in one line; a leftover Plesk
  panel state from 1.0 does not stop a first install (one line says it is ignored).
- An upgrade of a server where panel mode serves Plesk's sites is refused by the package's
  pre-install step: run `sudo scalwsctl panel disable` with the installed version first
  (it gives the ports back to Plesk's nginx), then upgrade. 1.0 keeps working for Plesk
  users who stay on it.

### Upgrade notes
- Plesk: 1.1 does not install over 1.0 while Plesk panel mode is on
  (`/var/lib/scalws-panel/state.json` names Plesk). Run `sudo scalwsctl panel disable` with
  1.0 first, then upgrade; or stay on 1.0, which keeps working with Plesk.

### Fixed
- Packages (systemd): `scalwsd.service` and `scalws-controller.service` make `/var/log/scalws`
  writable (`ReadWritePaths=-/var/log/scalws`). An `access_log` file or `logging.access_file`
  in a folder there, as the log guide suggests (`/var/log/scalws/sites/`), stayed unwritten
  ("Read-only file system", retried every second) under `ProtectSystem=strict`.
- `.htaccess`: `AuthGroupFile` no longer denies the directory. Apache reads the group file
  only for `Require group`, which still denies; with `Require valid-user` or `Require user`
  the login applies. DirectAdmin's password-protected directories (`AuthGroupFile
  /dev/null`) answered 403 even with the right password. 1.0 has the same bug.
- cPanel: a MultiPHP switch to a PHP version no site used served 502 for about 30 seconds.
  The sync's path unit watched only the pool directories of the versions in use, so the
  new pool did not start a sync until the retry; it now watches the pool directory of
  every installed `ea-php*` too, and `/opt/cpanel` for a version installed later
  ([control panels](https://scalws.com/docs/guide/control-panels/)).
- Packaging: the first-install cgroup v1 notice on a CloudLinux host no longer advises the
  unified hierarchy (LVE depends on CloudLinux's layout); it says to keep it
  ([CloudLinux](https://scalws.com/docs/guide/control-panels/#cloudlinux)).
- DirectAdmin with OpenLiteSpeed: `panel enable` failed and its rollback left the web
  server disabled at boot. The unit is `openlitespeed.service`; `lshttpd` and `lsws` are
  its aliases, and disabling an alias disabled the unit and removed the aliases, so the
  next steps and the rollback found no unit. Each web server name is now resolved to its
  unit (`systemctl show -p Id`) and recorded, disabled, stopped, given its drop-in and
  restored under that name, once; its enablement is recorded truthfully (an alias link
  exists only while its unit is enabled, so `alias` counts as enabled). The `services.status` lines `openlitespeed=` and `litespeed=`
  (LiteSpeed Enterprise) are turned off and back like `httpd=`. 1.0 has the same bug.
- DirectAdmin: a PHP slot without its own `phpN_mode` runs as `php1_mode`, as DirectAdmin
  1.7x writes only `php1_mode`. `panel enable` refused such a server ("PHP slot 2 ... runs
  as (unset)") and the sync gave that slot's domains no PHP.
- Fuzzing: the cargo-fuzz targets fuzz the vendored `fastcgi-client` and `ktls` that
  ScalWS ships (they fuzzed the upstream crates) at the dependency versions of the
  workspace lock (`fuzz/Cargo.lock`), run every night in CI (built once, two minutes per
  target), and cover HTTP/3 frame headers and FastCGI responses too.
- A reload that keeps followed document roots no longer walks every protected directory
  for every such root: the protected directories' identities are taken once per reload,
  and each kept root is checked through its own open (not a map shared by path, whose stale
  entries could restart runtimes on every reload).
- OpenRC: a drain with the controller running no longer waits its whole timeout when no
  instance is left (the top cgroup's `populated` counted the controller's own group).

## [1.0.0] - 2026-11-12

### Security (2026-11-10): audit run 6
- HTTP/2: a response that makes no send progress within `write_timeout` gives up its body,
  and with it the tenant's concurrency permit, any upstream and its in-flight mark; hyper
  resets that stream if it polls the body again, and the connection's other streams go on,
  as do its requests whose responses have not started (an upload, a long poll). A
  connection ends when all its responses are stalled and no request is in service, or when,
  closing after `idle_timeout` or on shutdown, it has only dropped responses left (their
  streams would keep it open for ever), or once it has drained for `write_timeout` with no
  request in service (a finished response's last bytes, which h2 still held for a client
  granting no credit, kept a draining connection open for ever). A client that granted no
  flow-control credit (and answered the PINGs) made hyper wait for credit without writing
  to the socket, so the socket's write timeout never fired and the response held its body,
  the tenant's concurrency permit (`max_concurrent_requests`: 503 for everyone else) and any
  upstream for as long as the client kept the connection. HTTP/2 response bodies are now
  handed to hyper in steps of 16 KiB, each of which must go out within the timeout; a slow
  but steady reader gets the whole response.
- HTTP/1 and HTTP/2: a connection whose request lasted longer than `idle_timeout` (a slow
  download, a long poll) no longer keeps its task busy for the rest of the request: the
  connection loop slept until the idle deadline, which was already past, so it ran again
  at once, using a whole core per such connection; it also kept restarting the timer of
  the HTTP/2 send-progress check, which then never ran with the default timeouts.
- HTTP/3: the peer's QPACK encoder and decoder streams are read and discarded (h3 never
  read them, so QUIC kept up to 1.25 MB of whatever a peer sent on each for the life of the
  connection, about 2.5 MB per idle connection); a second stream of either kind ends the
  connection. The receive windows are bounded as HTTP/2's: 1 MiB per stream (at least the
  largest HEADERS frame allowed plus 16 KiB), that plus 1 MiB per connection (quinn's
  default had no connection bound: 128 request streams of 1.25 MB), and no datagram buffer.
- HTTP/3: handshakes from unvalidated addresses are bounded in rate too: beyond a quarter
  of `max_connections` started per `tls_handshake_timeout` over all HTTP/3 listeners of the
  instance, a new one gets a Retry. The quarter bounded only handshakes in progress, which
  a sender that never receives (as with a forged address) and closes each handshake at once
  never reached, so it got a TLS flight for every Initial.
- QUIC demux: a registration is accepted only for the server id the controller issued to
  the registering process (the demux asks the controller over the handout socket), and a
  connection registers one server id, released when it ends. A process of the demux's user
  could register the ids the controller would give the next instances (which were then
  refused HTTP/3), and several ids on one connection, all but the last of which stayed live
  after the connection closed and drew new clients' Initials, which were dropped. During an
  upgrade, a new demux under a controller of an older version (which cannot answer) keeps
  the older rule until the controller restarts, and the controller is asked only for a
  connection's first id.
- Shared listening sockets (`listen: inherited`): every socket option the instances'
  system call filter lets a holder set is now kept by the controller or cannot change what
  the shared sockets deliver, which a test checks against the filter's list. Set back each
  tick and reported: `IP_RECVERR` and `IPV6_RECVERR` (on the HTTP/3 socket, ICMP errors
  filled the receive buffer, which nobody reads from the error queue, until no datagram
  arrived for any instance; on a TCP listener, accepted connections ended at the first
  ICMP error), the options quinn-udp sets (now set by the controller the same way when it
  takes the socket), the TCP listener's accept backlog (`listen(fd, 0)` by a holder), its
  buffer sizes and the lock a size setting leaves (accepted connections lost
  autotuning; unlocked with `SO_BUF_LOCK`, Linux 5.14, and reported as lasting before
  it; a size that does not read back as set is reported once), `TCP_NODELAY`, `IP_TTL`,
  `IPV6_UNICAST_HOPS` and a device binding; a reuseport program on a TCP listener and a
  socket filter that is not locked are detached.
- Shared listening sockets held by a process without the enforced core filter (sandbox
  `off`, `audit`, not applied, or an instance on a binary an upgrade replaced) are tainted:
  such a holder could set states no check covers. A generation that runs with the filter
  enforced gets a new TCP socket instead (in the old one's reuseport group), a tainted UDP
  socket, which cannot be bound twice, is reported in `listeners.last_error`, and after a
  controller restart a TCP socket bound to one device is not recovered.
- Sandbox (L1): `sched_setaffinity` is allowed for the calling thread only (pid 0, as the
  event loops pin themselves); a compromised instance or demux could re-pin the threads of
  every process of the service user (other instances, the controller, the demux), which
  neither the kernel nor Landlock prevents. Refused with `EPERM`, like `prlimit64` for
  another process.
- Sandbox (L1): writable rules are checked on the descriptor they open, as read rules
  already were: a writable directory (`write_paths`, the runtime, ACME state or cache
  directory) that the owner of a directory above it swapped for a link to scalws-controller's
  state, or to a directory over it, between the sandbox plan and its application now fails
  the instance's start instead of making the generations, records and QUIC keys writable.
- scalws-controller: one fan-out slot is kept for root's clients: a peer of the service
  user (a compromised instance) that keeps the 4 shared ones busy with calls to its own
  slow admin socket no longer gets root's purge, tenant-limit change or usage, upstream and
  certificate views answered `busy`. The control API passes the client's uid
  (`SO_PEERCRED`) with each request that calls the instances.
- scalws-controller: read views (usage, upstreams, certificates) and the tenant-limit
  reply's `result` relay at most 1 MiB of an instance's answer, as it came (it was parsed
  and written back, which could make it nearly four times larger, up to 16 MiB read); a
  larger answer is refused. A request now holds its fan-out slot until its reply is
  written or its connection ends, so clients that do not read their replies cannot make
  the controller hold more than 5 of them.
- scalws-controller: run-time tenant limits are accepted only for tenants of the current
  generation (404 otherwise; the name must follow the configuration's name rule) and end
  with a tenant once a generation without it has taken over (it serves and no older
  instance does): a reload that is rolled back, or a generation that cannot be read, drops
  none. Any name used to be kept, in memory and
  in `tenant-limits.json` (written on every request), until the controller restarted.
  The file is written only when the kept limits change.
- scalws-controller: from an issued-generation record at the plausibility bound (planted
  while the sandbox was not in force) the controller counted on to numbers whose record it
  did not believe at its next start, so its own generations from 2^52 up were ignored and a
  planted generation below 2^52 (or an old one) was current at every start. It now never
  issues such a number: from a record at the bound it counts on from its numbers below
  2^52, and the plant is displaced for good.
- scalwsd: a protected directory that does not exist yet (the ACME state before the account
  is made, the disk cache before its first start) is judged by its nearest existing
  directory: a document root reached through a link at or over it is refused (503), where it
  used to be accepted and to serve the directory once ScalWS created it.
- scalwsd: a reload that protects a new directory (a TLS key directory or ACME state it
  names) opens the roots of applications with `root_symlinks: follow` again instead of
  keeping them: a kept root opened through a link into that directory went on serving it
  (keys written after the reload included) until a restart. Such a reload starts those
  applications' runtimes again. Each runtime records the protected set it was checked
  against, so a reload that protected a directory and then failed does not let the next
  reload keep such a root.
- `--restrict-suid-sgid` (and the OpenRC service sandbox) answer io_uring with `ENOSYS`:
  its open and mkdir operations take a mode no seccomp filter sees. openat2 with
  `O_CREAT` and a set-ID mode stays the one creation the filter cannot see (the bit is
  cleared on the first write without `CAP_FSETID`; see docs/guide/security.md for the
  older-kernel `fallocate` case).
- Upgrade: a drop-in with `RestrictSUIDSGID=false` (the former remedy for a runtime
  directory without POSIX ACLs) no longer has an effect, since the units pass
  `--restrict-suid-sgid` instead of setting it. Use
  `Environment=SCALWS_RESTRICT_SUID_SGID=false` in that drop-in (scalwsd.service and
  scalws-controller.service); the package names such drop-ins when it is installed.
- PHP output parked for slow clients: the pools' floors are now assigned from the quarter
  kept for them and never promised twice. They were an equal share recomputed at each
  charge, so when an in-process reload (SIGHUP, `scalwsctl reload`, `server.reload.watch`,
  a panel sync) added pools while another tenant held its floors and the shared part, the
  floors already held exceeded the reserve and an existing pool's slow responses failed.
  An existing pool now always keeps at least its current share; a pool added meanwhile
  gets the rest of its share as the earlier, larger shares are given back (their parks
  end within 5 minutes, and a renewed park keeps no more than the new share).
- OpenRC: root's drain (`rc-service scalws-controller shutdown`, `stop` while the system
  goes down, `apk del`) and `stop-quic-demux.sh` no longer read the service user's records
  in shell code: `scalws-controller recorded-pids` opens only the names the controller
  writes (`instances/web-0.json` to `web-4095.json`, `quic-lb.json`), so no flood of other
  entries hides a record, without following a link, and reads each only as a regular file
  of the service user under 64 KiB (never a FIFO). `instances.max` is now at most 4096. A record
  named with a newline led root through a link or to a FIFO the checks had refused, and
  many records or FIFOs held the drain for minutes. The drain's timeout now counts seconds,
  not rounds.
- Panel sync: a site put back to its previous file after a refused reload root cannot
  confirm no longer takes back a name its account gave up in the same pass and another
  account took (a hand-over): it is left out for the pass instead. The previous file and
  the other account's new one claimed the same name, and the next refusal reverted the
  other account's change or restored the whole pass, the operator's suspensions included.
  A site refused again after it was put back is left out too, rather than the whole pass
  restored.

### Fixed (2026-11-10): final VM checks
- SELinux, Plesk webmail on AlmaLinux 10: the webmail domain `scalws_webmail_t` got none of
  its unconfined rules there, so `scalwsctl panel webmail-fpm` was denied reading
  `/var/lib/scalws-panel`, `/etc/scalws` and `/etc/httpd`, restarted in a loop and every
  webmail name answered 404. The package's module is built against the EL8 policy, whose
  `unconfined_domain()` also names socket classes EL10's policy removed (`bridge_socket`,
  `ib_socket`, `mpls_socket`), so its optional block was left out at load time. The module
  now also spells those rules out with names EL8, EL9 and EL10 all have
  (`tests/packaging/selinux-webmail.sh` loads the EL8-built module on AlmaLinux 8, 9 and 10).
- The packaged `scalwsd.service` and `scalws-controller.service` no longer set
  `RestrictSUIDSGID=`: systemd's filter cannot read openat2's mode and refuses the whole
  call with `ENOSYS`, so every instance logged `openat2 unavailable` and served static files
  through the path walk instead of the kernel's `RESOLVE_BENEATH` lookups. The binaries take
  `--restrict-suid-sgid` instead, which the units pass: a seccomp filter with the same
  refusals (a set-user-ID or set-group-ID mode given to open or openat with `O_CREAT` or
  `O_TMPFILE`, creat, mkdir, mkdirat, mknod, mknodat, chmod, fchmod, fchmodat, fchmodat2),
  inherited by the instances, the QUIC demux and the applications, with openat2 allowed.
  openat2 with `O_CREAT` and such a mode is the one creation it cannot see; a write by the
  service user (no `CAP_FSETID`) clears the bit again. The service sandbox of OpenRC
  (`--service-sandbox`) now refuses the same creations; it never refused openat2. The
  console's unit keeps `RestrictSUIDSGID=` (it serves no files). A drop-in that repeats
  `ExecStart=` must keep `--restrict-suid-sgid`.
- logrotate under SELinux: `tests/packaging/selinux-logrotate.sh` now loads the EL8-built
  module on AlmaLinux 8, Rocky 9, AlmaLinux 10 and Fedora 44 and checks that `logrotate_t`
  may map its configuration (logrotate 3.18 and later mmap it). Since the configuration moved
  to `/etc/scalws-logrotate-instances.conf` (`etc_t`, run 5), the policies grant that map;
  the `scalws_etc_t` path of earlier packages failed with "Error mapping config file" on
  EL9 and Fedora 44.

### Security (2026-11-09): audit run 5
- HTTP/3: a QUIC handshake must finish within `tls_handshake_timeout` (it was bounded only
  by the idle timeout, so unanswered Initials held connection permits that TCP shares).
  Handshakes from addresses QUIC has not validated hold at most a quarter of
  `max_connections`, counted over all HTTP/3 listeners of the instance; beyond that a new
  one gets a Retry. Unvalidated handshakes count against their claimed source's
  `per_ip.max_connections` without taking its slots: a source at its limit gets a Retry and,
  validated, is refused before any TLS work, as on TCP; the slot of an unvalidated address
  is taken once the handshake has validated it. Forged source addresses hold at most a
  quarter of the permits and none of another address's slots, and their entries in the
  per-source table can always be evicted: a shard full of forged handshakes no longer
  leaves the sources that fall in it unlimited (a handshake that finds no room gets a
  Retry).
- HTTP/3: any frame other than DATA (HEADERS, trailers, reserved types, on request streams
  and the control stream) that declares more than `max_header_bytes` plus 1 KiB resets its
  stream with `H3_EXCESSIVE_LOAD` before its payload is read; h3 0.0.8 buffered such a frame
  whole before any limit applied.
- HTTP/3: response sends obey `write_timeout`: a send that makes no progress (a client that
  keeps the connection alive but grants no stream credit) resets the stream and drops the
  response, which releases the tenant's concurrency slot and any upstream connection. Body
  frames go out in steps of 16 KiB, each under the timeout, so a slow but steady client
  gets a large frame (a 256 KiB file chunk, a cached response) as over TCP.
- QUIC server ids: the controller never hands out an id that a live or adopted instance
  holds (the counter wrapped from 65535 to 1, and a lost counter write could reissue ids
  after a controller restart), and the QUIC demux refuses a registration of an id that
  another connected process holds, for any listener, so one instance can no longer take or
  unregister another's HTTP/3 traffic. A refusal is answered: the instance logs it, stops
  advertising HTTP/3 on that listener and registers again every second.
- The shared HTTP/3 UDP socket (`listen: inherited`): the instances' seccomp filter allows
  only the socket options ScalWS, its libraries and the C library set (by level and name)
  and refuses the rest, among them socket filters, `SO_BINDTODEVICE`, `UDP_ENCAP` (which
  hands every QUIC datagram to IPsec), `UDP_CORK`, `IPV6_ADDRFORM` and `IP_TTL`, so a
  compromised instance cannot stop the demux from receiving, or the other instances'
  replies, for good. Instances with `listen: inherited` and the demux, which bind nothing
  once sandboxed, are also refused `SO_REUSEADDR` and `SO_REUSEPORT`: with them a socket of
  their own could bind a more specific address on a shared port, or join a shared TCP
  listener's group, and take its traffic. The controller checks the sockets on every tick:
  `O_NONBLOCK` cleared on the shared file is set again (the demux's batch read would wait
  for a whole batch), a connect to one peer is undone, a reuseport group is closed to new
  members, `SO_REUSEADDR` is cleared, a shrunk receive buffer is set back, packet
  information (`IP_PKTINFO`, `IPV6_RECVPKTINFO`) is turned back on and `UDP_ENCAP`,
  `UDP_CORK` and `UDP_SEGMENT` are set back to 0, each reported in `listeners.last_error`; a
  socket filter or an `IPV6_ADDRFORM` (sandbox off) is reported, and a filtered socket is
  not recovered after a controller restart.
- `server.ktls`: a client that fragments its ClientHello so that rustls has fewer than 5
  bytes of room for the next record header no longer panics its connection task in the
  vendored ktls `CorkStream` (the header is handed over in parts).
- A document root reached through a symbolic link (`root_symlinks: follow`) is also refused
  when it leads into or over the directory of a TLS certificate or key the configuration
  names (listener certificates, `server.admin.remote`, and where their links lead, such as
  certbot's `archive/`): a tenant could otherwise serve a listener's private key, which the
  serving process reads. Such a refusal is logged as a warning naming the root and the key
  directory: a key kept directly in a wide directory (`/srv/server.key`) protects all of
  it, so keep keys in a directory of their own.
- `scalwsctl check`, `scalwsd --check` and the panel sync's check no longer run the
  configured `fpm.binary` (`-v`, for the PHP-FPM version): root runs the check in the
  package scripts and the panel sync over a file the console may write. The version is
  asked when the pool starts, by the process that starts it.
- scalws-controller: purge, tenant limit, usage, upstream and certificate requests (which
  call the instances) run at most 4 at once, more are answered `busy`; a purge or read view
  whose client went away stops, and replies carry at most 2 KiB of an instance's answer
  (they embedded it whole, each control byte escaped to six).
- scalws-controller control socket: a reply its client does not read ends the connection
  after 30 s, and 8 connections beyond the 64 shared ones are kept for root's clients
  (scalwsctl, the console), so peers running as the service user cannot hold every
  connection.
- scalws-controller keeps the highest generation number it issued in its state directory
  (`issued-generation`): a generation directory planted at or just below 2^52 while the
  instances ran without Landlock no longer becomes current again at every controller start,
  and a new generation never reuses an existing directory (an issued file is never written
  again).
- `scalwsctl` bounds the connect to a Unix socket (a full accept queue held it without end)
  and the mutual TLS handshake and reply of `--remote` (a peer sending a byte at a time
  kept one read going) by the call's timeout.
- PHP output parked for slow clients: a serving process parks at most 4 GiB, whatever the
  number of PHP pools (cPanel runs one per domain, so one account can have hundreds). A
  quarter of it is kept for floors: each pool parks its first bytes (an equal share of that
  quarter among the process's pools, at most 32 MiB) from there, so other pools, another
  tenant's applications among them, spending the rest no longer fail a pool's slow
  responses.
- Panel sync: a failed check blames a site file only where its whole path stands in the
  error (`a.test.yaml` no longer matches another account's `a.test.yaml.b.test.yaml`).
- Panel sync: a refused reload that root cannot confirm never puts a suspended site back to
  its previous, unsuspended file: the suspension is applied, or the site is left out for
  the pass.
- The instance log rotation's configuration moved from `/etc/scalws` to
  `/etc/scalws-logrotate-instances.conf`: logrotate runs it as root (scripts included), and
  the root console may write everything in `/etc/scalws`, so a compromised console could
  have had a script run as root outside its sandbox. SELinux no longer lets logrotate read
  `scalws_etc_t`.
- Sandboxed instances under scalws-controller: no Landlock read rule lies in or over the
  controller's state directory any more. A document root (or other read path) that is a
  link to a file beside the state opened the state's parent directory, and a root swapped
  for a link to the state between the plan and its application was followed; every
  directory a read path opens is now checked, and again on the descriptor opened when the
  rules are applied.
- The console's OpenRC service sandbox (root with CAP_CHOWN, CAP_FOWNER and
  CAP_DAC_OVERRIDE) now also makes the read-only mount view of its unit's
  `ProtectSystem=strict`: Landlock has no right for mode, owner, ACL, extended attribute or
  time changes, so a compromised console could chmod `/etc/shadow` or loosen root-run files
  outside its write fence. The service keeps CAP_SYS_ADMIN and CAP_SETPCAP (only with
  `service_sandbox=yes`); the console builds the view in a mount namespace of its own and
  drops both from every capability set before it serves. Such changes outside the fence now
  fail with `EROFS`, by path or through a descriptor opened for reading. Where the mount
  calls are refused although CAP_SYS_ADMIN is there (a container's seccomp profile, an
  LSM), the console starts without the view and logs `no read-only view (mounts refused:
  ...)`, as without CAP_SYS_ADMIN, instead of failing to start.
- `rc-service scalws-controller shutdown` (and `apk del`, and `stop` at system shutdown)
  drains every process in `/sys/fs/cgroup/scalws` once the controller is stopped, with
  `cgroup.kill` on the whole group after the timeout, as systemd's `--kill-who=all`: a
  process of the service user parked in a group whose name starts with a dot, or in the
  controller group, was left running. `apk del` reports survivors by group membership, not
  by process name.
- OpenRC: root's stop, shutdown, upgrade and removal steps read the controller's records
  (`instances/*.json`, `quic-lb.json`, in the service user's state directory) only as
  regular files the service user owns, never through a link, under 64 KiB, and then at
  most 64 KiB within 5 seconds: a record linked elsewhere was read and acted on, and a
  sparse record of many gigabytes made the step run for minutes and grow without bound.

### Security (2026-11-08): audit run 4
- The console's OpenRC service sandbox (root with CAP_DAC_OVERRIDE) no longer lets it write
  `/proc` (sysctls such as `kernel.core_pattern`) or device nodes: of `/dev` only
  `/dev/null`, `/dev/zero`, `/dev/full` and `/dev/shm` stay writable, as its systemd unit's
  PrivateDevices= and ProtectKernelTunables= give. Of `/run/openrc` it may write only the
  control file of the controller's supervisor (for the controller restart), never OpenRC's
  service state; starting or restarting scalws-controller restarts a running console so
  that it follows a new supervisor's file.
- Without Landlock the OpenRC service sandbox is the system call deny-list only, and
  `scalwsctl status` now says so (`no write fence (no Landlock)`) instead of claiming a write
  fence; the admin API's `sandbox` object has `service_fence`.
- Sandboxed instances: a document root with `root_symlinks: refuse` gets its Landlock read
  rule without following links (a link there gets none), a path whose link leads into
  scalws-controller's state gets no rule, and a read-only path the kernel refuses as a rule
  (a link to `/proc/self/ns/net`) is skipped with a note instead of stopping the instance.
- A document root reached through a symbolic link (the default `root_symlinks: follow`) is
  refused when it leads into or over ScalWS's own directories (`/etc/scalws`,
  `/var/lib/scalws*`, `/run/scalws*`, the configured ACME state, runtime and disk cache
  directories, the controller's state): a tenant could otherwise serve the ACME keys.
  The check is made on the opened directory (device and inode), so swapping the root for a
  link while it is opened does not get around it. `scalwsd --check` reports it.
- `rc-service scalws-controller shutdown` (and `apk del`) also drains the processes the
  controller recorded (instances, QUIC demux), checked by start time and owner: on cgroup v1
  or hybrid hosts and with `server.cgroups` off or an explicit path they were left running.
  The drain never splits the cgroup names the service user chose into words. `apk del` says
  which ScalWS processes still run.
- The instances' logs (`/var/lib/scalws-controller/logs/web-<n>.log`, one access log line
  per request) are rotated on every package type from
  `/etc/scalws-logrotate-instances.conf`: daily and at 100 MB, 7 kept, as the server user,
  checked every hour (`scalws-logrotate.timer` on systemd hosts, enabled once by the
  package, and `/etc/periodic/hourly/scalws-logrotate` on Alpine), with a state file of its
  own; the system's daily logrotate run does not handle these logs. The apk depends on logrotate, the deb and rpm recommend it; the OpenRC
  service logs rotate at 100 MB too. SELinux labels the directory `scalws_log_t` and lets
  logrotate reach it through the controller's state directory; the configuration is
  `etc_t`, which logrotate may read and map.
- The installer no longer says the console's port 8090 "stays closed" whenever a firewall
  is active. It says the port was not opened and the default policy blocks it only when
  that is so (ufw's default incoming deny or reject, a firewalld zone target other than
  ACCEPT, an nftables input policy of drop) and no rule for port 8090 was found; otherwise
  it says the console may be reachable and to check the firewall. Whenever it starts or
  enables the console it says that it listens on port 8090 of every address; an upgrade
  that enables a console the operator disabled says so with
  `systemctl mask --now scalws-console`, and a masked console is left alone. On an apk
  upgrade the console is restarted once (by the controller's restart), not twice.
- Stopping scalws-controller (systemd `stop` and `restart`, OpenRC `stop`) also stops its
  QUIC demux (`/usr/share/scalws/stop-quic-demux.sh`, checked by start time, owner and
  arguments), so HTTP/3 is no longer answered. Where the instances keep serving after a
  stop (systemd 254 and later, OpenRC) they also keep the UDP 443 sockets they were handed:
  the port stays bound, without answering QUIC, until the controller starts again (TCP
  keeps serving) or the instances end (`systemctl stop scalws-controller && pkill -TERM -f
  'scalwsd .*--instance-id'`, OpenRC `rc-service scalws-controller shutdown`). On systemd
  before 254 the stop ends the instances too, and nothing stays bound.
  Under SELinux the policy module lets the stop script run `scalws-controller` (systemd
  runs it as `initrc_t` with the unit's NoNewPrivileges); without that the demux was not
  stopped on the RHEL family and Fedora.
- With `server.ktls`, a TLS client could panic its connection task with a crafted control
  record (change_cipher_spec, an alert that is not 2 bytes) and leave the open-connections
  gauge raised: such records now end the connection with an error (third_party/ktls,
  SCALWS-CHANGES.md), and the connection close is counted on every way out of the task.
- PHP output parked for a slow client: stderr records are cut to what the log keeps
  (2 KiB), charged to the parking budgets and dropped at the park expiry (an HTTP/2 stream
  with a closed window held up to 4 MiB each, outside every budget, for as long as the
  connection lived). When a budget is spent, the response is no longer failed: the driver
  hands over what it parked and waits for the client (as nginx does at
  `fastcgi_max_temp_file_size`). Waiting holds a PHP-FPM worker, so it is bounded: one
  deadline per response, 5 minutes after it first parked (reading does not renew it), and
  at most a quarter of a pool's workers (rounded down: none in a pool of fewer than four)
  wait at once; a response beyond that fails as before.
- `io_bandwidth` on a tenant whose application roots have no block device (btrfs, ZFS,
  overlay) was silently not enforced. It is now reported (a warning once per tenant), fails
  the start in `cgroups.mode: required`, and the admin API (`io_bandwidth_enforced`,
  `io_unresolved`) and `scalwsctl limit` say it is not enforced.
- scalws-controller, shared listeners: a reload that pairs a kept `[::]:p` with an IPv4
  listener on `p` gets an IPv6-only TCP socket (the kept dual-stack one served IPv4 on every
  address); for UDP such a reload is refused with the reason. Sockets handed back after a
  controller restart are kept only if they listen (TCP) or are unconnected (UDP) and all
  instances handed back the same socket. A TCP listener a holder shut down listens again.
  The QUIC demux backs off on a UDP socket shut down for reading instead of spinning.
- scalws-controller start with a QUIC demux left running: the start no longer fails in a
  loop on `Address already in use` for the HTTP/3 UDP socket; the adopted demux is ended and
  the socket bound, and a generation whose sockets cannot be bound is retried instead of
  stopping the controller.
- The QUIC demux is restarted when it runs with a sandbox mode less strict than the current
  generation's or on a replaced binary (after a package upgrade); `status` shows its mode.
  Its record is bound to the boot and the program: a stale `quic-lb.json` naming a reused
  pid is removed, and that process is neither adopted nor signalled.
- Stored generation numbers above 2^52 (never issued by a controller) are ignored, and the
  controller counts on from the numbers it stored itself, below 2^53. A planted
  `generations/18446744073709551615` (or any number near the ceiling) no longer wraps or
  blocks the next reload, and does not come back at every start.
- Calls from the controller to an instance's admin socket have a 10 s deadline and a 16 MiB
  answer limit; the replay of queued purges and tenant limits to an instance that became
  ready ends within 10 s, and at most 64 purges are queued (then one purge of everything).
  The control socket serves at most 64 connections, one request each, with a 10 s limit on
  the request head. The controller's own descriptor exhaustion no longer counts as an
  instance not answering (it restarted healthy instances).
- An instance of scalws-controller whose metrics port another local account holds starts
  anyway; the controller then reads its readiness and metrics over the admin socket.
- The panel sync blames a failed check or refused reload only on what an error line names
  first (the application's `tenants[i].applications[j]`, a generated file's path). A
  customer's document root named after another site's file, after a descriptor shortage
  (`os error 24`) or with the log tail marker no longer takes other sites out or fails
  the pass for every account.
- A failed check that one account causes by removing its document roots after the probe
  uses one round for that account: its sites whose roots no longer open are left out
  together, and the other accounts' changes are applied.
- A refused reload (a controller rollback reason, which processes of the server user can
  write) leaves out a site only when root confirms that the server user cannot open its
  document root. A site, certificate or webmail name blamed without that keeps its
  previous file for the pass (with a status warning), or is left out when it has none;
  the other accounts' changes are applied.
- A document root with a control character (newline, CR, NUL, other C0, DEL) is refused:
  that site is left out with a status warning.
- A panel domain whose site file name is an operator's own file in `sites.d/panel/` (no
  generated header) is skipped; the operator's file is never replaced or deleted.
- scalwsctl reads an admin or controller reply up to 16 MiB and within one timeout for
  the whole reply (10 s for a GET, 300 s otherwise), not per read.

### Fixed (2026-11-08): managed PHP on EL8 and Alpine
- EL8's default PHP-FPM 7.2 refused every managed pool (exit 78) over
  `decorate_workers_output`, a PHP 7.3 directive. scalwsd now asks the binary for its version
  (`php-fpm -v`) and writes the directive only for 7.3 and later. The installation guide has
  a [PHP on EL8](https://scalws.com/docs/guide/installation/#php-on-el8) section: the `php:8.2` stream or Remi.
- Alpine names the binary after the version (`/usr/sbin/php-fpm83`), which managed PHP did
  not find. Without `fpm.binary`, scalwsd takes `php-fpm`, else the newest versioned binary
  in either naming (`php-fpm8.4`, `php-fpm84`).

### Added (2026-11-07): HTTP/3 in the packages
- The `.deb`, `.rpm` and `.apk` are built with HTTP/3 (feature `http3`, ADR-0019), the QUIC
  demux of scalws-controller included. It stays off: `http3: true` on a TLS listener turns
  it on, and neither the packaged configuration, `scalwsctl site add` nor the cPanel,
  DirectAdmin and Plesk generators set it. 0-RTT stays off.
- The package does not open UDP 443. The ufw profile `ScalWS` is now 80/tcp and 443/tcp
  only; the new profile `ScalWS HTTP3` is 443/udp (`sudo ufw allow 'ScalWS HTTP3'`). The
  installation guide has the commands for ufw, firewalld, nftables and awall.
- SELinux: `scalws_extra.cil` labels UDP 443 `http_port_t` (EL 8 and 9 leave it in
  `reserved_port_t`), so the confined server can bind it.
- The seccomp allowlist of `server.sandbox` is tested with HTTP/3 (a sandboxed scalwsd
  serves it). The out-of-box matrix has an `http3` check, passed on
  AlmaLinux 8, 9 and 10, Rocky Linux 8 and 9, Oracle Linux 8 and 9, Fedora 44, Debian 12 and 13, Ubuntu 22.04, 24.04 and 26.04 (also upgrading from 1.0.0~rc.1-11 on Debian 13 and Ubuntu 24.04 and 26.04), openSUSE Leap 15.6 and 16.0, SLE BCI 15.7 and 16.0, and Alpine 3.24; HTTP/3 also passed under
  SELinux enforcing on AlmaLinux 8, 9 and 10.
- `scalwsd --features` lists the optional features a binary was built with; the release
  scripts require `http3` in it.

### Added (2026-10-28): in-process sandbox (Landlock and seccomp)
- `server.sandbox: on` confines scalwsd with Landlock and a seccomp allowlist: it writes only
  its runtime, state, cache, log and temporary directories and the tenant cgroups, runs no
  program, creates no process and makes no dangerous system call (mounts, namespaces,
  `ptrace`, io_uring, keyrings, eBPF loading). Under scalws-controller it also reads only
  what its configuration names. Applied when the configuration starts no processes (no
  managed runtimes or tenant users) and the kernel has Landlock (not EL8); otherwise scalwsd
  says why and runs as before. Under scalws-controller, panel mode included, tenant users
  are refused instead: a reload with `tenants[].user` needs `sandbox: off`, also on a new
  install, whose first install adds `sandbox: on`.
  `audit` logs what `on` would refuse. `scalwsd --sandbox-selftest` checks it on a host.
  The QUIC demux is sandboxed the same way. A scalwsd running as root is not sandboxed
  (`not applied: running as root`): root standalone setups, eBPF accounting ones
  included, run without it; the guide shows how to run as `scalws` instead. Guide:
  `docs/guide/sandbox.md`.
- The first install of the package adds `sandbox: on` to `/etc/scalws/scalws.yaml`. The
  packaged file is unchanged and an upgrade or a reinstall never adds the key: an existing
  installation keeps running without it (`off`), without a configuration file prompt.
- `--service-sandbox` for scalwsd, `scalws-controller run` and `scalws-console run` gives
  systems without systemd (OpenRC) the write fence and system call settings of the systemd
  units.
- `scalwsctl status` and the admin status show the sandbox.
- With systemd 254 and later a restarted scalws-controller replaces sandboxed instances
  instead of adopting them for good: the tenant cgroups they may write are removed when it
  stops. Instances without the sandbox are adopted as before.

### Fixed (2026-10-28): stored configuration generations
- scalws-controller checks a stored generation against the digest it recorded before it
  starts an instance from it, validates generations it does not know again (after a
  restart), and takes the sandbox mode from its own record. Generation files are written
  read-only.

### Upgrade notes
- A configuration with `server.sandbox` is refused by older versions (unknown keys are
  errors): remove the key before downgrading.
- scalws-controller keeps the files instances read in `<state_dir>/shares/` and the QUIC
  demux socket in `<state_dir>/quic-lb/`; the old files are kept current while adopted
  instances of the previous version read them and removed afterwards. After a downgrade
  the older controller writes the old files again (its instances start with those paths);
  `shares/` and `quic-lb/` are then unused and can be removed. Stored generations are now
  read-only (0400), which older versions read without trouble.
- ufw: the upgrade narrows an existing rule `ScalWS` that still opens 443/udp (added with
  `ufw allow 'ScalWS'`, as older packages suggested, while the profile listed 443/udp) to
  TCP 80 and 443 with
  `ufw app update ScalWS`, and says so; no older package could serve HTTP/3. A listener
  with `http3: true` is refused by packages before HTTP/3 was built in: remove it before
  downgrading.

### Docs: panel and system coverage
- `docs/guide/control-panels.md` has one matrix of cPanel, DirectAdmin and Plesk against
  every supported system, as tested: tested, tested in part, not supported by the vendor,
  or deferred.

### Added (2026-10-28): Ubuntu 26.04 LTS
- Supported system: Ubuntu 26.04 LTS (amd64), from the same `.deb` and apt repository.
  Tested on a plain server (AppArmor, ufw, cgroup v2, systemd 259, PHP 8.5) and with
  DirectAdmin and Plesk in panel mode. cPanel: when the vendor supports it.

### Fixed (2026-10-28): found by the Ubuntu 26.04 tests
- The upgrade from 1.0.0~rc.1-11 or older on systemd 259 (Ubuntu 26.04) restarts the
  controller: the old controller left the cgroup controllers on in the unit's group when it
  stopped, so the restart failed with "unavailable resources" and systemd retried for ever.
  The package now releases them and restarts once more; it also repairs that restart loop
  when an older release left it behind (`systemctl restart scalws-controller` with
  1.0.0~rc.1-11 on Ubuntu 26.04).

### Added (2026-10-28): Alpine Linux 3.24
- `.apk` for Alpine Linux 3.24 (x86_64): a static musl build of `scalwsd`, `scalwsctl`,
  `scalws-controller` and `scalws-console` (`scripts/release-build-apk.sh`, built in
  `docker/alpine-build.Dockerfile` with the compiler of the glibc build; ktls is vendored in
  `third_party/ktls` with a fix that lets it compile for musl). Versions are mapped for apk:
  `1.0.0-rc.1` release 12 is `scalws-1.0.0_rc1-r12.apk`.
- OpenRC services `scalws-controller`, `scalwsd` and `scalws-console` with the systemd
  units' behaviour: controller restarts hand the instances over, `rc-service
  scalws-controller shutdown` (and a system shutdown) drains them, cgroup v2 delegation for
  tenant limits in `/sys/fs/cgroup/scalws`, the same users and capabilities. Output goes to
  `/var/log/scalws/`, rotated by logrotate. The services start with `--service-sandbox`:
  the units' write fence (ProtectSystem=strict, ReadWritePaths=; `rw_paths` in
  `/etc/conf.d/<service>`) and system call settings, in process; `scalwsctl status` says
  what it covers (no private /tmp, devices or namespaces).
- Signed apk repository `https://apt.scalws.com/alpine/v3.24/main` (packages and index
  signed with RSA and SHA-256). The first install starts ScalWS on ports 80 and 443 and the
  console, as on the other systems, and opens 80 and 443 in an active ufw or a running
  nftables service with the stock ruleset (`/etc/nftables.d/50-scalws.nft`). With awall it
  only prints the commands for its policy `scalws` (`awall activate` replaces the whole live
  iptables ruleset).
- Messages that name a service command or the logs use the host's init system (OpenRC:
  `rc-service`, `/var/log/scalws/*.log`, `doas`).
- Guide: the Alpine section of `docs/guide/installation.md`.

### Added (2026-10-28): openSUSE Leap and SLES
- Supported systems (x86_64): openSUSE Leap 16.0 and 15.6, SUSE Linux Enterprise Server
  16.0 and 15 SP7, with the same `.rpm` and repository as the RHEL family: import the key
  (`rpm --import`, after checking its fingerprint), `zypper addrepo
  https://rpm.scalws.com/scalws.repo`, `zypper install scalws`. The `.rpm` now depends on
  `(shadow-utils or shadow)` instead of `shadow-utils`, and on `/usr/bin/awk`, which the
  install scripts need. `scalws.repo` has `type=rpm-md` and `autorefresh=1`, so zypper sees
  new releases.
- On Leap 16 and SLES 16 ScalWS runs with SELinux enforcing under the same policy module,
  unchanged; SUSE's php8-fpm (127.0.0.1:9000) works with it. On Leap 15.6 and SLES 15 SP7
  (AppArmor or none) it runs unconfined, as on Debian and Ubuntu. No control panel
  supports SUSE.

### Added (2026-10-28): the RHEL family, Fedora 44, Debian 12 and Ubuntu 22.04
- Supported systems (x86_64): AlmaLinux, Rocky Linux and Oracle Linux 8, 9 and 10, Fedora
  44, Debian 12 and 13, Ubuntu 22.04 and 24.04. One build linked against glibc 2.28 serves
  all of them: the `.deb` depends on `libc6 (>= 2.28)`, the `.rpm` on `glibc >= 2.28`,
  `shadow-utils` and `/usr/bin/setpriv`. Rocky Linux 10, Oracle Linux 10 and the standard
  (x86-64-v3) AlmaLinux 10 were tested under CPU emulation; full verification follows in the
  next release. AlmaLinux 10's x86_64_v2 build is fully tested.
- Signed dnf repository: `curl -o /etc/yum.repos.d/scalws.repo
  https://rpm.scalws.com/scalws.repo`, then `dnf install scalws`. Packages and the
  repository metadata are signed with the ScalWS archive key (`repo_gpgcheck=1`).
- SELinux policy module in the `.rpm`: ScalWS runs with SELinux enforcing in its own domains
  (`scalws_t`, `scalws_console_t`, and `scalws_app_t` for the applications it starts). The
  console's port 8090 is `scalws_console_port_t`. The boolean `scalws_can_network_connect`
  (default on) lets proxies and applications connect to any TCP port. The container runtime
  is not supported under SELinux enforcing in this release.
- The first install opens ports 80 and 443 in an active ufw (rule `ScalWS`) or a running
  firewalld (services `http` and `https`, in the zone of the default route's interface),
  and says so. It never starts a stopped firewall and never opens the console port 8090;
  the output prints the command for it. Removal leaves the rules and prints how to remove
  them. This replaces the ufw hint.
- On a cgroup v1 host (EL8 by default) ScalWS serves with tenant limits off, and the first
  install prints how to switch to cgroup v2
  (`grubby --update-kernel=ALL --args=systemd.unified_cgroup_hierarchy=1`).
- With systemd before 254 (EL8, EL9, Debian 12, Ubuntu 22.04) the package adds a
  `KillMode=control-group` drop-in for `scalws-controller`: a controller restart or an
  upgrade restarts the instances too (a short interruption instead of the handover).
- Guide: `docs/guide/installation.md` (supported systems, dnf, firewall, SELinux, cgroup v1).

### Fixed (2026-10-28): found by the RHEL-family tests
- Tenant limits stay in place after `systemctl restart scalws-controller` and package
  upgrades: systemd (255 and later) removes the empty tenant groups when the unit stops, and
  the instances the restarted controller adopted now rebuild them, where their reload was
  rejected until the next `scalwsctl reload`.
- `systemctl restart scalws-controller` works with systemd 259.5 (the Fedora 44 release),
  where every restart with tenant limits failed with "Failed to spawn executor: Device or
  resource busy": a stopping controller removes the empty tenant groups and disables the
  cgroup controllers in the unit's group, which the adopted instances enable again.
- `scalwsd.service` starts with the package's default configuration: a `server.listeners`
  entry on the IPv6 wildcard `[::]:p` is IPv6-only (`IPV6_V6ONLY`) when the same
  `server.listeners` also has an IPv4 listener on port `p` (`0.0.0.0:p` or a specific IPv4
  address), so `[::]:80` no longer takes the IPv4 port that `0.0.0.0:80` binds (it failed
  with "Address already in use" while `net.ipv6.bindv6only` is 0). A `[::]:p` without an
  IPv4 listener on `p` keeps the system's default and stays dual-stack, as before.
  scalws-controller's shared sockets (TCP, and UDP for HTTP/3) follow the same rule.
- Tenants with a Unix `user` work under the packaged `scalwsd.service`: the tenant's socket
  directory is mode 0770 with a default ACL for group `scalws` instead of the setgid mode
  2770, which the unit's `RestrictSUIDSGID=true` refused.
- A managed PHP-FPM pool of a tenant with a Unix `user` starts: the output pipes of such a
  tenant's applications belong to the tenant, so PHP-FPM can reopen `error_log =
  /proc/self/fd/2` (it failed with "Permission denied"), and its errors reach the ScalWS
  log. The SELinux policy lets scalwsd hand the pipes over.
- SELinux: managed PHP-FPM pools start with PHP 8.5 (Fedora 44), whose opcache locks a
  memfd ("Cannot create lock - Permission denied").
- The rpm requires `/usr/bin/setpriv` (util-linux-core or util-linux): without it,
  applications under SELinux and tenants with a Unix `user` refused to start (minimal
  Fedora images lack it).
- cPanel panel mode (found on AlmaLinux 9): `panel enable cpanel` waits up to 30
  seconds for the PHP-FPM pools of cPanel's conversion, which runs in the background; PHP
  failed after the handover until a later sync when the domains were not on PHP-FPM before.
- cPanel: the first suspension on a server is served within seconds: `panel enable cpanel`
  creates `/var/cpanel/suspended` (root:mail 0710, as cPanel does) when cPanel has not yet,
  since the sync's path unit cannot watch a directory that does not exist.
- cPanel: PHP for a new subdomain no longer waits for the 5-minute timer when cPanel's queued
  PHP-FPM conversion takes longer than 30 seconds: a sync that rewrote sites and still finds
  a vhost without a pool asks for one more sync.
- cPanel: `panel enable cpanel` on a server whose cPanel licence cannot be read reports
  cPanel's message ("whmapi1 servicestatus service=httpd: Cannot Read License File")
  instead of a parse error, and changes nothing.
- DirectAdmin panel mode: a domain or subdomain created in DirectAdmin is served within
  seconds on AlmaLinux and Rocky Linux too. DirectAdmin runs its hook before it makes the
  new document root, so that sync left the domain out until DirectAdmin's next task queue
  run or the 5-minute timer; a vhost newly left out for a missing document root now gets
  one more sync 5 seconds later.
- Panel mode on cPanel and DirectAdmin: one retry sync for both (unit
  `scalws-panel-sync-retry`, to the second). It leaves the sync request, so a retry that
  lands while a sync runs is not lost, and a retry that still finds a vhost without its
  PHP-FPM pool or document root re-arms itself up to 3 times, so domains created one after
  the other are not left to the 5-minute timer. A retry that cannot be scheduled is named in
  the sync's output.

### Added (2026-10-27): Plesk panel mode
- `scalwsctl panel enable plesk`: ScalWS replaces Plesk's nginx and serves the
  subscriptions' domains, additional domains, subdomains and aliases with the domains' PHP-FPM
  pools and Plesk's certificates, the hostname's default site and Plesk webmail
  (`webmail.<domain>`) through the PHP-FPM unit `scalws-panel-webmail.service`. Every PHP
  handler that is not FPM (domains and service plans) is switched to the FPM handler of the
  same version; `panel disable --restore-php` puts the recorded handlers back. The unit
  `nginx` is kept down by a systemd drop-in while panel mode is on (Apache keeps running
  behind it on 127.0.0.1:7080/7081, untouched), and
  Plesk event handlers (35 events, registered with `plesk bin event_handler`, ids recorded
  in `state.json`) start a sync within seconds. `scalws` joins the group `psaserv`.
  `panel disable` deletes the handlers and hands the ports back. The sync only reads
  Plesk's data (`plesk db` SELECT queries, pool files, certificates); `enable` changes PHP
  handlers and service plans. Every site answers Let's Encrypt challenges from Plesk's
  shared directory, also over plain HTTP; webmail is HTTPS only and refuses Roundcube's
  files without an extension as Roundcube's own rules do. `SCALWS_PANEL=none` skips the
  takeover at install; removing the package prints the manual steps if `panel disable`
  failed. Guide: `docs/guide/control-panels.md`.
- The Console names the panel ("add the domain in Plesk", "managed by Plesk").
- A Plesk alias with `seoRedirect` on (Plesk's default) answers with a 301 to its domain,
  keeping the path, as Plesk does, instead of serving the domain's content; a subdomain's
  name on it (`<label>.<alias>`) redirects to the subdomain.

### Changed (2026-10-27): Plesk panel mode leaves Apache running
- `panel enable plesk` hands over `nginx` only; `apache2` is no longer recorded, stopped or
  given a drop-in. The live test showed that every Plesk web configuration change (domain
  create, PHP handler change, `plesk repair web`) fails while Apache is stopped: Plesk
  regenerates Apache's configuration and restarts it gracefully. Apache listens on
  127.0.0.1 only. Apache alone on port 80 (nginx off in Plesk) is refused. A state written
  by an earlier `enable` that handed `apache2` over is still given back by `panel disable`
  (drop-in removed, enabled and started before nginx).

### Security (2026-10-27): panel mode audit, run 3 (Plesk)
- Plesk webmail names are never taken from another site: they are reserved against every
  domain and active alias in Plesk's database (also forwarding domains and domains without
  hosting) and against the domains of the operator's own site files. A check error or a
  refused reload that blames the webmail site through one of its names leaves out that
  name alone, so Roundcube stays served for every other domain; a webmail site still left
  out is a warning that webmail is not served.
- One domain's Plesk webmail configuration that is missing, unreadable, runs as root or
  names another user, group or handler loses only that domain's webmail names (a skip note
  names it); the pool runs as the identity most domains share.
- A refused reload that names a site leaves out every new or changed site of the same
  account in that round: one account can use at most one of the three rounds, and the
  other accounts' changes are applied. A failed check still leaves out that site alone.
- Webmail's PHP-FPM pool: `user` and `group` written quoted; a user or group that does not
  exist, or is uid or gid 0, refuses the webmail; an `open_basedir`, `disable_functions` or
  `disable_classes` value that the pool cannot take keeps the webmail from starting.
  Roundcube's `/plugins/enigma/home` and `/program/actions` are denied.
- Aliases are served only with web on in Plesk, and get a webmail name only with mail on; a
  domain whose webmail is off in Plesk has no webmail names.
- The event handlers also cover customers' and resellers' status changes and deletions (35
  events). `panel disable` deletes a recorded handler only while it still runs the hook
  script.
- `panel enable plesk`: a domain or service plan whose switch to PHP-FPM fails is a warning
  and is not recorded (all failing still stops `enable`); the Plesk ids of switched domains
  and plans are recorded and `--restore-php` restores only a row that still has its id.
- An `nginx` unit that is installed but stopped and disabled is held with the drop-in too
  and is never started by `panel disable`; every sync warns while it runs in panel mode.
- `scalws-panel-sync.service` stops a sync after 15 minutes; `scalws-panel-sync-request.path`
  starts at most 10 syncs a minute; the removal's Plesk recovery steps remove the hook
  script. An access probe that cannot run is a status warning naming why, and the
  hostname's document root is asked of the probe on DirectAdmin and Plesk.

### Security (2026-10-27): panel mode audit, run 2
- The panel sync asks the kernel what the server user can open: a short child process
  (`scalwsctl panel probe-access`) runs as `scalws` with its groups and opens each
  document root, webapp directory and PHP-FPM socket the way the server does, so an
  account's ACL that denies `scalws` leaves that vhost out instead of failing every
  reload. The mode bits remain the fallback when the probe cannot run.
- A refused reload is traced to its site: scalws-controller's `last_rollback` carries the
  failed instance's start error (`reason`), and the sync leaves out the site it names and
  reloads again (at most three times); only a refusal that names no site restores every
  account's previous files. Without a start error the reason is the instance's last log
  lines (`reason_from: log tail`), which blame no site.
- A route whose own document root cannot be opened (a directory shared by many sites)
  answers 503 under its prefix alone; the application's root and its other routes are
  served, at a start, a reload and a controller instance start. The application's own
  root keeps its rules (and so do the route roots of an application without a root);
  `scalwsctl check` still reports such a root.
- DirectAdmin: a webapp directory, or `/var/www/html`, that `scalws` cannot open leaves
  out the webapps routes (with a warning), never the sites. The hostname's site opens its
  roots with `root_symlinks: refuse` and refuses `/phpMyAdmin-<version>/log` too.
- DirectAdmin certificates: paths a domain's configuration names are used only inside
  the account's own `domains` directory (or the server certificate and key); certificate
  files are read without following links, as regular files of at most 1 MiB; the copy
  holds only the certificates and key that parsed, written again as PEM, each certificate
  once.
- The package never starts ScalWS on ports 80 and 443 on a panel's server (also with
  `SCALWS_PANEL=none` or on an upgrade); it prints the command that switches over.
- A `panel sync` that gives up waiting for the lock leaves DirectAdmin's sync request for
  the one that runs.

### Added (2026-10-27): DirectAdmin panel mode
- `scalwsctl panel enable directadmin`: ScalWS replaces the web server CustomBuild
  installed (Apache, nginx, LiteSpeed, OpenLiteSpeed) and serves the main and additional
  domains, subdomains, alias and redirect pointers, Force SSL, suspended accounts and the
  hostname, with the accounts' PHP-FPM pools and DirectAdmin's certificates, plus
  `/roundcube`, `/phpMyAdmin`, `/pma`, `/config`, the ACME challenge path and the mail
  autoconfiguration. The old server's line in `services.status` is set to `OFF` and a
  systemd drop-in keeps its unit down while panel mode is on; DirectAdmin's hooks
  (`user_httpd_write_post`, `user_destroy_post`, `ssl_save_post`) start a sync within
  seconds; `scalws` joins the groups `access` and `apache`. Every PHP slot in use must be
  php-fpm (`enable` names the `da build` command otherwise). `panel disable` hands the
  ports back. Guide: `docs/guide/control-panels.md`.
- The Console names the panel ("add the domain in DirectAdmin", "managed by DirectAdmin").

### Security (2026-10-27): PHP include files
- PHP include files (`.inc`) are no longer served as files: PHP applications send them to
  PHP like `.php`.

### Added (2026-10-26): cPanel panel mode
- `scalwsctl panel detect | sync | status [--json] | enable cpanel [--dry-run] | disable
  [--restore-php]`: ScalWS replaces cPanel's Apache and serves its main, sub, addon and
  parked domains, the service subdomains (`cpanel.`, `webmail.` and the others, proxied to
  `cpsrvd`), the server's hostname and a page for suspended accounts. Certificates come
  from AutoSSL. The sites are generated into `/etc/scalws/sites.d/panel/`; the units
  `scalws-panel-sync.path` and `.timer` keep them in step. `enable` undoes its steps when
  one fails; `disable` hands the ports back to Apache. Guide: `docs/guide/control-panels.md`.
- `certificates_file` in a listener's `tls`: more certificate entries from a separate YAML
  file (`-` before the path: a missing file means none). Panel mode uses it for the
  AutoSSL certificates.
- The Console's Domains page shows cPanel-managed sites read-only, with the sync status.
- The first install on a cPanel or DirectAdmin server takes over the panel's web server
  (`scalwsctl panel enable`; a failed switch is undone and the install still succeeds);
  the installer's `--panel=none` (`SCALWS_PANEL=none`) skips it.
- `root_symlinks: refuse` on an application or site: its document root must be canonical
  and is opened without following symbolic links (static files, PHP, `.htaccess`). Panel
  mode sets it on every account site, so an account cannot point its document root at
  another account's files or at the certificate keys. Default `follow`: unchanged.
- Panel mode details: `enable` enables `scalws-controller` at boot, reloads it after the
  restart and waits until an instance answers HTTP; `disable` and a failed `enable` also
  stop the controller's instances (they outlive the unit) before Apache starts, and
  `disable` leaves the controller disabled. The panel's state, status and certificate
  copies live in the root-owned `/var/lib/scalws-panel/`; panel commands take a lock; the
  sync gives new document roots the group `nobody` (FileProtect) and leaves out document
  roots reached through a symbolic link. Removing the package in panel mode runs
  `scalwsctl panel disable` first.

### Security (2026-10-26): panel mode audit fixes, server and packaging
- PHP applications send `.phtml` and `.php3` to `.php8` (any case) to PHP like `.php`,
  and an `index` with such a suffix is a script; those files, `.phar` and `.phps` are
  never served as static source. Before, their source was returned as a static file.
- Without `openat2` (kernels older than 5.6, seccomp policies that block it) file lookups
  below a document root walk the path one component at a time from the opened root
  without following links (a link is refused), instead of checking a path and opening
  it again, which a tenant could race to read another account's files.
- A running server no longer fails a start, or a reload that leaves an application's
  root and runtimes unchanged, because that application's document root cannot be
  opened: it answers `503`, the error is logged, the others are served, and the next
  reload tries again. A reload that adds or changes an application whose root cannot be
  opened is still refused; under `scalws-controller` the instances of the new
  generation get the previous generation's configuration (`scalwsd --previous-config`)
  and fail to start, so the controller rolls the generation back. `scalwsctl check` and
  the Console report it as an error.
- The package keeps its "autostart done" marker in the root-owned `/var/lib/scalws-pkg`
  instead of the server user's `/var/lib/scalws`, where a planted link could make the
  root package script create a file elsewhere; an old marker (or link) counts as done
  and is never written through; a directory planted there does not stop an upgrade or a
  removal.
- The installer requires gpg (it installs `gnupg` when missing) and installs only the
  pinned repository key, re-exported from the downloaded file, which must hold exactly
  that key.
- Console drafts: `include` and `certificates_file` may only name files below the
  configuration directory, the certificates file is checked like a site file, and a file
  that does not parse is reported by name and position only, never with its content.
  The other files a draft's checks read (`basic_auth.users_file`, certificates and keys,
  CA bundles) must be below that directory too, unless the configuration on the server
  already names them.
- Panel mode: a failed `panel enable` that starts `scalws-controller` again reloads it
  with the restored configuration and reports ScalWS as serving only once that
  generation is active (and says whether the controller did not start, did not load
  it, or does not listen on port 80); a controller without a running instance can be
  reloaded.
  Generated site names carry 96 bits of the domain's hash (before: 48). The manual
  repository instructions check the downloaded key and install only the pinned key.

### Fixed (2026-10-26): Console DNS state
- The Domains page showed every domain as "Points elsewhere": the console unit did not
  allow netlink sockets (`RestrictAddressFamilies`), so `ip -j addr` could not list this
  machine's addresses. `AF_NETLINK` is allowed now, and when the addresses cannot be read
  the state is "unknown" instead of "elsewhere".

### Changed (2026-10-26): document roots in home directories
- The server units (`scalws-controller`, `scalwsd`) use `ProtectHome=read-only` instead of
  hiding `/home`, so a site can be served from `/home/<user>/public_html` or
  `/home/<domain>`. `/root` and `/run/user` stay hidden.
- The Console's Domains page accepts document roots below `/home/` (besides `/srv/` and
  `/var/www/`); its unit may create them (`ReadWritePaths=-/home`).
- `scalwsctl site add` warns, with the fix, when user `scalws` cannot enter a directory on
  the way to the document root or read its `index.html` (mode bits; `warning` in `--json`).
  The Console shows the warning after adding a domain.

### Added (2026-10-25): Domains page in the ScalWS Console
- **Manage, Domains**: every site with its other domains, type, target, HTTPS certificate
  state and whether its DNS points at this server. Administrators add a domain (static,
  PHP through an existing PHP-FPM socket, proxy or redirect) and remove one; both need a
  password confirmation, are audited (`site.add`, `site.remove`) and are serialised with
  configuration applies. New capability `sites.manage` (administrators only).
- Backed by **`scalwsctl site add|remove --json`** (new) and the extended
  `site list --json` (`kind`, `target`, `acme`, `site`, `domain_list`), so the console takes
  the same checked path as the command line; **controller `GET /certs`** relays the
  certificate state of a serving instance.
- `scalwsctl site add` writes the site file (0640) and the placeholder page (0644) with
  explicit modes, independent of the umask (the console's unit runs with `UMask=0077`).
- The console unit may write `/srv/www` (created by the package) for new document roots.

### Changed (2026-10-25): ready to publish after installation
- **Default configuration** (`packaging/scalws.yaml`): listeners on ports 80 and 443
  (IPv4 and IPv6; the IPv6 ones are commented out on hosts without IPv6), Let's Encrypt
  for every site (`server.acme.enabled`), and a catch-all application that answers hosts
  no site serves with a welcome page (`/usr/share/scalws/welcome`). Before, it answered
  only on `127.0.0.1:8080`, so an added site was not reachable.
- **The package starts the server**: a fresh installation (and, once, the first upgrade to
  this version) enables and starts `scalws-controller`, unless `scalwsd` or the controller
  is already enabled or another program listens on port 80 or 443 (the output names it).
  An upgrade that restarts the controller now also reloads, so a changed configuration
  file is applied to the adopted instances. ufw application profiles `ScalWS` and
  `ScalWS Console`.
- **Instances on small machines**: the controller pins an instance only to CPUs the host
  has. With the packaged `cpus: "0-3"` on a 1 or 2 CPU server, the second instance of a
  rolling reload got CPUs 2-3, `taskset` failed and every reload (also the one of
  `scalwsctl site add`) was rolled back; instances now share the CPUs there are.
- **`scalwsctl site add`**: without `--root`, a static or PHP site's document root is
  `/srv/www/<domain>`; a missing document root is created, a static site with a
  placeholder `index.html`; both are taken back when the check or the reload fails.
- **`scalwsctl status|apps|tenants|certs|top|history|diff`** work under scalws-controller
  without `--socket`: they use the first instance's admin socket.

### Added (2026-10-19): `user_agent` in the access log
- Access log lines carry the request's `User-Agent` header as `user_agent` (at most 256
  bytes, bytes that are not UTF-8 replaced, `-` without the header). The header is kept
  only while the access log is on.

### Added (2026-10-15): Gateway API (ADR-0052)
- `scalws-ingress run --gateway-api` serves GatewayClass, Gateway, HTTPRoute
  (`gateway.networking.k8s.io/v1`) and ReferenceGrant (`v1beta1`) next to Ingresses, in
  the same pod and the same translation; `--ingress=false` makes a Gateway-only install.
  New flags `--gateway-controller-name` (default `scalws.com/gateway-controller`) and
  `--gateway-listener PORT=NAME` (default `80=http`, `443=https`). Gateway listeners map
  by port onto the pod's fixed `scalwsd` listeners; every Gateway shares the Service
  address. HTTPRoute matches, header modifiers, redirects, URL rewrites, timeouts and
  weighted `backendRefs` become routes; unsupported filters (RequestMirror, CORS,
  ExternalAuth, ExtensionRef, filters on `backendRefs`) and unknown fields inside matches
  and filters make the rule's matches answer 500 under their own keys
  (`PartiallyInvalid`, `Dropped Rule ...`); client certificate validation and
  `tls.options` make the listener `Accepted: False`; ExternalName Services are refused.
  Status with `observedGeneration`, merge patches, shared `status.parents` (stale entries
  removed, at most 32), Events (`HostnameConflict`, `WeightRounded`, `UnsupportedFilter`,
  `UnsupportedField`, ...) and metrics `scalws_ingress_gateway_api_available`,
  `scalws_ingress_gateways`, `scalws_ingress_httproutes`,
  `scalws_ingress_status_writes_total`. The CRDs are optional: discovered at start and
  every 60 s, Ingresses keep serving without them. Supported CRD bundles: standard
  channel v1.3.0 to v1.6.x.
- Conformance (Gateway API v1.6.3, GATEWAY-HTTP): core `partial`, 35 passed with one
  skip, `HTTPRouteMultipleGateways` (needs per-Gateway addresses, planned as phase 2d);
  extended 17 of 17 passed for the claimed features. Workflow `gateway-conformance` keeps
  the report; `conformance/run.sh` runs it locally. Guide:
  `docs/guide/gateway-api.md`.
- Helm chart: `ingressController.gatewayAPI.enabled`, `.controllerName`,
  `.gatewayClass.create`, `.gatewayClass.name`, `.extraPorts` (extra Gateway listener
  ports), and `ingressController.ingress.enabled`. The chart never installs the Gateway
  API CRDs; it fails with the pinned install command when they are missing.
- Configuration: application `listeners` (serve an application on some listeners only;
  domains are unique per listener), `**.example.com` domains (one or more labels, never
  `example.com` itself; lookup exact, `*.`, longest `**.`, catch-all; not with
  `acme: true`), and `backends` entries `{status: 500..599, weight}` that answer a share of
  the requests with that status. Configurations without them take the existing code paths.

### Changed (2026-10-15): route precedence among equal paths
- Among routes with the same path type and path, a route with a method matcher is tried
  first, then the one with more header matchers, then more query matchers, then the
  earlier one (the Gateway API order); before, the total number of matchers decided.
  Order changes where same-path routes differ in the kind of matcher: a method list
  counts once however many methods it names, and header matchers outrank any number of
  query matchers. Configurations whose same-path routes use only header matchers, or only
  query matchers, keep their order, and so do the routes the ingress controller
  generates (ADR-0050 amended).

### Changed (2026-10-15): ingress controller host ownership
- One ownership rule for Ingress and Gateway API: a host on a listener is served by the
  oldest claim (Ingress namespace, Gateway listener hostname or HTTPRoute namespace
  through a Gateway); an Ingress and an HTTPRoute never serve one host together.
- A host under an older wildcard of another namespace is no longer served for the newer
  namespace: an Ingress for `shop.example.com` gets `PathConflict` when another
  namespace's older Ingress holds `*.example.com` (before, host patterns were compared
  only as written). Owners of the wildcard's own namespace are not affected.
  `ingressController.crossNamespacePaths` (`--cross-namespace-paths`) restores the old
  behaviour among Ingresses, and now also lets routes of several namespaces share a host
  of a Gateway; it never merges Ingresses with HTTPRoutes.
- An Ingress `spec.defaultBackend` claims the catch-all host like a rule without a host.

### Changed (2026-10-15): default certificate without server names, `*.org` SANs
- The `default` entry of `server.listeners[].tls.certificates` may have
  `server_names: []`; it is then served only for an absent or unknown SNI name. Every other
  entry still needs at least one name. The Kubernetes controller uses it for the
  certificate of a hostname-less Gateway HTTPS listener whose routes have no hostnames.
- The check that a certificate covers a server name accepts a wildcard SAN directly under
  one label (`*.org` covers `example.org`), as RFC 6125 and Go clients do; before, such
  a certificate was refused for that name. Browsers do not trust such certificates.

### Changed (2026-10-15): fountain accept policy caps connections per event loop
- With `server.accept_policy: fountain` an event loop also counts as full while it holds
  twice its fair share of the open connections (`max(8, ceil(2 x connections / loops))`),
  and a loop at its cap leaves new connections to the loops after it (at most 2 ms).
  Keep-alive connections that arrive a few at a time no longer pile up on the first one
  or two loops: in the Kubernetes ingress benchmark fountain's p99 at a fixed rate fell
  from 2.80 to 2.46 ms (11.15 to 2.35 ms with Ingress churn), its requests/s rose to
  0.92x to 0.98x of `shared`, and its CPU saving is unchanged. Connections opened in one
  burst are still placed by the burst estimate; `shared` (the default) is unchanged and
  stays the recommendation for proxies and ingress mode (ADR-0044).

### Changed (2026-10-14): ingress controller host ownership and retries
- Only the namespace a host belongs to (the namespace of its oldest Ingress for the host,
  served or not; rules without a host count as one host) may add paths to it. A rule of an
  Ingress of another namespace for the host is not served and gets a `PathConflict` Event
  naming the owning namespace; its rules for other hosts are still served. Before, every
  namespace merged paths into the host as in ingress-nginx, so another namespace could
  add a path or catch the owner's unserved paths with a broad prefix or regex. The old
  behaviour is opt-in: `--cross-namespace-paths`, chart value
  `ingressController.crossNamespacePaths: true`.
- Generated pools retry twice instead of once (three tries, the ingress-nginx default),
  still only for a failed connect or an idempotent request that failed before anything
  reached the client. A scale-down that stops several pods at once no longer gives `502`
  when the single retry hit another stopping pod.

### Fixed (2026-10-14): no resend of a written POST on a stale keep-alive connection
- When a kept-alive upstream connection idle for 1 s or more turned out to be closed after
  a bodyless request was written to it, the request was sent again on a fresh connection
  whatever its method. A bodyless `POST` the upstream processed before closing could run
  twice. Both upstream clients now resend a written request only for idempotent methods
  (`GET`, `HEAD`, `OPTIONS`, `PUT`, `DELETE`); a request none of which was written is
  still resent for any method.

### Fixed (2026-10-14): findings of the Kubernetes ingress benchmark
- Upstream pools retry an idempotent request (`GET`, `HEAD`, `OPTIONS`, `PUT`, `DELETE`)
  on another member when the connection breaks before the response head, for example a
  reset keep-alive connection to a pod that is shutting down. Before, such requests got a
  `502` (about 40 per backend scale-down in the benchmark). Other methods are still not
  repeated once written.
- The shared listener socket (default `listener_mode`) listens with a queue of 4096
  connections (capped by `net.core.somaxconn`) instead of std's 128, which dropped part
  of a burst of a few hundred simultaneous connections (1 s SYN retransmission).
- Helm chart: no memory limit on the ScalWS container by default (was `256Mi`, which got
  `scalwsd` OOM-killed proxying 100 KiB responses at 256 connections); the memory request
  is `128Mi`.

### Added (2026-10-14): ingress controller (ADR-0051)
- `scalws-ingress`: Kubernetes Ingress controller that runs next to `scalwsd` in the pod.
  It watches IngressClass, Ingress, Service, EndpointSlice and Secret resources, translates
  Ingresses and the common `nginx.ingress.kubernetes.io/*` annotations (rewrite, regex
  paths, redirects, TLS Secrets, basic auth, source ranges, CORS, timeouts, affinity,
  canary) into configuration, reloads `scalwsd` through `POST /v1/reload` and keeps pool
  members current with `PUT /v1/upstreams/{pool}` without reloads. Ingresses asking for
  access control ScalWS lacks (`auth-url`, `auth-tls-*`, ModSecurity) are not served; one
  bad Ingress does not affect the others. Events, metrics on `:10254`, Lease leadership
  for the Ingress status. Guide: `docs/guide/ingress-controller.md`.
- Helm chart ingress mode: `ingressController.enabled` installs the controller, the
  IngressClass `scalws`, RBAC and a `LoadBalancer` Service; kind e2e in CI.
- `domains: ["*"]`: the catch-all application for hosts no other domain matches (at most
  one).
- Route `https_redirect`: overrides the application's value for one route, both ways.

### Added (2026-10-12): site files (ADR-0048)
- `include:` in `scalws.yaml` reads one short file per site, e.g. `sites.d/*.yaml`:
  `domain`, `aliases`, `www: none|alias|redirect`, `root`, `tls: auto|manual` and one
  runtime shorthand (`static`, `php`, `node`, `python`, `proxy`, `redirect`) or the full
  syntax. Sites are expanded into tenants and applications at load time; messages name the
  site file; a domain may be served once. Site files must belong to root and must not be
  writable by group or others. Guide: `docs/sites.md`.
- `scalwsctl site add|list|remove`: writes `<domain>.yaml`, refuses domains already served,
  checks like a reload (and removes the file again on failure), reloads through
  scalws-controller when it runs. Under the controller, managed runtimes are refused up front
  with the alternative (`--php-fastcgi`, `--proxy`).
- `scalwsctl migrate nginx|apache`: reads an nginx or Apache configuration (with its
  includes; only read) and writes one site file per virtual host: names, root, index, PHP-FPM
  pools, proxies (also under other paths), redirects, HTTPS-only port-80 hosts
  (`https_redirect`), `www.` handling and `.htaccess`; everything else becomes `# TODO:` lines
  with file and line. Domains already served are asked about (`--overwrite`,
  `--skip-existing` without a terminal) and never written twice; a failed check or reload
  undoes the whole run.
- `redirect` runtime (`to`, `status`, `keep_path`): used by `www: redirect`.
- `https_redirect: true` on an application or site: plain HTTP gets a 301 to HTTPS (ACME
  challenges are still answered over HTTP).
- scalws-controller stores a configuration with site files expanded as its generation;
  the console validates and checks drafts with the site files and counts their sites.
- Package: `/etc/scalws/sites.d` (root:scalws, 0750) and `include: sites.d/*.yaml` in the
  default configuration (existing configurations are not replaced).

### Fixed (2026-10-12): tenant limits under scalws-controller
- `scalws-highcpu`/`highram`/`highio` and `scalws-limit*` answered "cgroups are not
  enabled" on servers run by `scalws-controller`: the controller process sat in the
  service's delegated cgroup, so scalwsd could not enable the cpu/memory/io/pids
  controllers there (cgroup v2 allows no processes in a group that delegates). The
  unit starts the controller in `<cgroup>/controller` (`DelegateSubgroup=`, systemd >= 254;
  without systemd the controller moves itself there) and instances use the parent. Running
  instances pick this up on the next `scalws-controller reload`.
- `scalwsctl` prints the server's message instead of a JSON envelope; the usage tables size
  their columns to the content and show sizes as KiB/MiB/GiB.

### Changed (2026-10-12): runtime performance
- Python runtime: managed processes start with `MALLOC_MMAP_THRESHOLD_=524288` and
  `MALLOC_TRIM_THRESHOLD_=1048576` (unless the application sets `MALLOC_*`). CPython's
  256 KiB socket buffer otherwise went through mmap/mremap/munmap per read until glibc's
  adaptive threshold happened to rise; the same uvicorn app ran at 5 940 or 6 360 req/s
  depending on that. Resident memory is unchanged.
- `respond` routes are answered without building a request context or a handler future,
  after every check of the pipeline (`.htaccess` routes keep the regular path).

### Fixed (2026-10-12): console on a fresh install
- The install text said `systemctl enable --now scalwsd`, but the console manages the server
  through `scalws-controller`, so it showed "controller unavailable". The package message,
  README and OPERATIONS.md now enable `scalws-controller` (`scalwsd.service` stays for
  managed runtimes and HTTP/3); the console's error names the command that starts it.
- Console: live statistics stayed empty under `scalws-controller`: the console (without
  `CAP_SYS_PTRACE`) could not read the instances' fd links, so no metrics port counted as
  the instance's. It now accepts a listening socket owned by the instance's user then.
- The package restarts an active `scalws-controller` and `scalws-console` on upgrade (the
  console kept running the old binary) and disables the controller on removal.

### Benchmarks (2026-10-12): run 7 on the VM
- The run-7 binaries on the development VM of the 2026-10-06 runs (two server CPUs,
  `MODE=release`) against nginx 1.31.6 and 1.24.0: ahead on the small static file (1.03x),
  proxy (1.06x), cache hits (1.57x), TLS + HTTP/2 (1.04x), HTTPS 1 MiB (1.50x) and PHP
  (1.16x); level on Python and Node.js; behind on fixed responses (0.94x) and the 1 MiB
  file over plain HTTP (0.95x). `docs/benchmarks/2026-10-12-vm-release-run7.md`.

### Benchmarks (2026-10-12): Adaptive Runtime on bare metal
- D1 and D5 repeated on the bare-metal host: web-tier paths scale with efficiency
  0.98-1.04 and N instances are 1.02-1.05x one instance with N loops; PHP stays bound by
  PHP-FPM (11.8k req/s with 1, 2 or 3 instances). Bursts of 1024 connections from idle:
  47.0k, 95.6k, 144.5k req/s with zero errors; every D5 check passed.
  `docs/benchmarks/2026-10-12-xeon-adaptive-runtime.md`.

### Benchmarks (2026-10-12): run 7, LiteSpeed Web Server Enterprise
- Bare metal, `MODE=release`, PGO + BOLT build of a7dc639 against nginx 1.28/1.31 and
  LiteSpeed Web Server Enterprise 6.3.7 (trial licence: two workers) instead of
  OpenLiteSpeed: ahead of nginx 1.31 on static-small (1.09×), proxy (1.07×), cache-hit
  (1.87×), TLS + HTTP/2 (1.39×) and php (1.15×), level on static-1m and node, behind on
  respond (0.97×) and python (0.97×, from 0.94×). Against LSWS: ahead on everything but
  static-small (0.98×) and node (0.93×). `docs/benchmarks/2026-10-12-xeon-release-run7.md`.
- `bench/run.sh`: LiteSpeed is stopped with USR2 + TERM repeated until it exits (a TERM it
  ignored once kept the harness waiting); `bench/instances.sh` and
  `scripts/controller-d5.sh` take `UPSTREAM_CPU` and `LOAD_CPUS`.

### Benchmarks (2026-10-12): release mode after the run-6 fixes
- Bare metal, `MODE=release`, PGO + BOLT build of 2f0e5b5 against nginx 1.28/1.31 and
  OpenLiteSpeed 1.9.3: ahead of nginx 1.31 on static-small (1.13×), proxy (1.07×),
  cache-hit (2.01×), TLS + HTTP/2 (1.37×) and php (1.06×); behind on respond (0.95×) and
  python (0.94×). `docs/benchmarks/2026-10-12-xeon-release-run6.md`.

### Added (2026-10-12): apt repository
- Signed apt repository at https://apt.scalws.com (`stable main`; https://scalws.com/apt
  redirects there): `apt install scalws`
  on Ubuntu 24.04+ / Debian 13+ (docs/OPERATIONS.md, "Install").

### Added (2026-10-12): Tenant resource commands
- `scalws-highcpu`, `scalws-highram`, `scalws-highio` (`scalwsctl high cpu|ram|io`): the
  tenants using the most CPU, memory or disk I/O now, with their limits.
- `scalws-limitcpu`, `scalws-limitram`, `scalws-limitio` (`scalwsctl limit cpu|ram|io`):
  limit a tenant (by tenant name or Unix user) at once, until scalwsd restarts; `--persist`
  also writes it to `scalws.yaml` (comments kept) and reloads; `--clear` removes it.
  Under scalws-controller every instance gets the limit, also instances started later.
- Console: a Resources page lists tenants by CPU, RAM or disk I/O with their limits;
  operators set or remove run-time limits there (audited as `tenant.limits`).
- Admin API: `POST /v1/tenants/{tenant}/limits`, `GET /v1/tenants/usage`; `GET
  /v1/tenants` shows each tenant's user.
- Configuration: `resources.io_bandwidth` (`io.max` on the disks of the tenant's
  application roots); `io_weight` returns to the default 100 when removed.

### Security (2026-10-12): fixes from security audit run-6 (`audits/run-6/REPORT.md`)
- Console: a draft in which a YAML anchor, alias or merge key copies a redacted
  placeholder to a field that is not secret is refused (after the save the view showed
  the secret).
- `.htaccess`: `DirectoryIndex` keeps at most 16 names (each is looked up for every
  directory request); the directory cache weighs the parsed items, not only the source.
- `.htaccess`: the `<Files *>` deny for cut access rules is added after the file's own
  `<Files>` blocks, so an earlier grant no longer overrides it.
- `.htaccess`: every regular expression run costs 4 KiB of the request's budget on top
  of its subject, and `<FilesMatch>` patterns are charged too.
- PHP: parked output expires five minutes after parking began, also while the script is
  still running.
- Tenant limits: instances started later (scale-up, restart) receive the run-time limits
  from the controller instead of resetting the shared cgroup to the configuration; the
  controller refuses invalid limits with 400.
- Workers: the port owner check fails closed when `/proc/net/tcp` cannot be read and
  refuses a connection accepted by another user.

### Security (2026-10-12): fixes from security audit run-5 (`audits/run-5/REPORT.md`)
- Console: draft validation messages quote no source lines (a parser's cropped snippet
  showed fragments of a secret); secrets are also replaced in their escaped form.
- `.htaccess`: `<Files>` access rules inside an unsupported container, open at the
  directive limit or never closed now deny every name; a file cut at 64 KiB or replaced by
  the parse-budget stand-in denies below child directories that grant access too.
- PHP: an expired parked response returns its parking budget, not only its disk blocks
  (a stalled HTTP/2 stream could hold the shared budget indefinitely).
- `.htaccess`: the directory cache weighs a parsed file's source and warnings (warnings
  are cut at 240 bytes); a request's regular expressions may scan at most 8 MiB (500
  past that).
- Console: sign-in, sign-out and re-authentication are audited at most 20 times a minute
  per account (failed sign-ins per client network), the rest counted in one notice; the
  sign-in throttle keys IPv6 clients per /64; at most 16 sessions per account.
- Workers: the per-connection owner check judges the listening socket (the kernel lists
  a connection not yet accepted with uid 0).
- `ErrorDocument`: the path of the document's URI (no query or fragment) is what is
  checked against the deny rules and routed.

### Security (2026-10-11): fixes from security audit run-4 (`audits/run-4/REPORT.md`)
- Console: secrets are replaced by `(secret)` in draft validation errors, warnings and
  `--check` output (parser messages quoted the restored secret's line; high).
- `.htaccess`: access rules inside `<IfModule>` for a module scalws does not model, past
  the 1000-directive limit or in the part of a file beyond 64 KiB deny instead of being
  dropped.
- `.htaccess`: the directory cache is weighed by path length too (long missing paths
  could keep ~560 MiB per application); nearly every pattern is weighed as 4 KiB; an
  application may spend at most 100 ms a second parsing files (past that, uncached
  directories deny until the next second).
- Deny rules: segment-prefix matching is linear in the path (8 KiB paths cost ~20 ms of
  CPU each with the WordPress profile).
- A local `ErrorDocument` that the deny rules block is not served.
- Cache: entries are bound to the application that produced them (a host moved to another
  tenant by a reload got the previous owner's cached responses).
- PHP: parked output for slow clients is limited to 1 GiB per pool and 4 GiB in total, and
  expires after 5 minutes unread.
- Workers: every new connection to a TCP worker's port must reach a socket of the worker's
  user (a port released by a descendant listener could be taken by another account).
- Console: connections that have not presented a valid session are closed after 30 s;
  request bodies must arrive within 10 s; the audit view pages back up to 64 MiB; at most
  30 new drafts per user a minute.

### Security (2026-10-11): fixes from security audit run-3 (`audits/run-3/REPORT.md`)
- Console: secrets nested in a changed section no longer appear in the draft validation
  change list (a Developer could read every redacted secret; high).
- PHP: a client that stops reading (e.g. an HTTP/2 stream whose window never opens) no
  longer holds a PHP-FPM driver: output it does not take is parked in an unlinked
  temporary file, as nginx `fastcgi_buffering` does (one connection could take a tenant's
  PHP site down; high).
- Console: at most 16 connections per client address, request-head and idle deadlines;
  throttled re-authentication is not audited one by one; audit search survives a window
  starting inside a UTF-8 character; stats are scraped only from an instance's own
  listener; at most 8 open drafts per user.
- Controller: readiness is read only from the instance's own `127.0.0.1` listener (a
  listener on `127.0.0.2`/`[::1]` with the same port made the controller kill every
  instance).
- FastCGI client (vendored): buffered records are emitted before reading more (output no
  longer piles up in memory); a connection that ends before `END_REQUEST` is an error.
- `.htaccess`: access rules that cannot be evaluated (HTTP authentication, `<RequireAll>`,
  `<Limit>`, …) deny instead of being ignored; tenant regular expressions are budgeted
  (32 KiB each, at most 8 up to 256 KiB per file) and the parsed-file cache is weighed.
- Cache: purged entries are not spilled back to the disk tier; bypass rules match the
  normalised client path after a rewrite.
- Deny rules cover PATH_INFO, trailing slashes and directory indexes
  (`/wp-content/uploads/*.php` no longer bypassed with `shell.php/` or an `index.php`).
- Runtimes: a worker leaves rotation as soon as its process exits.
- Own HTTP/1 server (experimental): a pending response body is dropped when the client
  leaves; tiny request-body frames are copied out of the read buffer.
- PHP: client `X-Forwarded-*` and client-address headers are stripped like the proxy does;
  FastCGI stderr is rate-limited; a managed FPM socket must belong to the tenant user.
- Static files: `openat2` support is decided once per document root, not on a request's
  `EPERM`.
- Console install: the generated administrator password is never printed (apt records the
  installer's terminal); the installer says how to read it from the credentials file.

### Added (2026-10-08): Per-domain request counters (ADR-0042)
- `scalws_http_host_requests_total{tenant,app,host,status}`, `..._response_bytes_total`,
  `..._request_bytes_total`, `..._cache_total{result}`, `..._requests_in_flight`: per
  configured domain pattern, counted by index from the host router's entry, sharded per
  event loop (no lock, no label hashing, no allocation per request). Unknown hosts and
  domains past `metrics.max_hosts` (default 1000) count as `_other`. On by default
  (`metrics.hosts`); A/B gate: no throughput or CPU-per-request regression
  (`docs/benchmarks/2026-10-08-domain-metrics.md`).
- Console: **Domains** tab on Traffic and "Top domains" on Overview (requests/s, trend,
  status shares, bytes in/out, cache hit ratio, in flight, totals).
- `scalws-h3-probe --stall-ms/--on-stall` and `scripts/h2-stall-dump.sh`: the soak runs an
  independent HTTP/2 client and snapshots sockets, controller and instance state while a
  request is pending > 2 s (forensics for the rc1 soak's unexplained HTTP/2 timeouts).
- Soak memory-pressure probe fixed (it probed before memory was low); `FAULTS_ONLY`.
- `scripts/console-systemd-e2e.sh`: console -> `systemctl restart` -> controller with the
  packaged units' sandboxing; 12/12. Fixed: an apply re-sent after it completed (draft
  gone) returned 404 instead of the same operation.
- `bench/run.sh` refuses to measure when the server it started has exited (a leftover
  process holding the port was measured once).

### Added (2026-10-08): ScalWS Console: live traffic, every setting editable, redesign
- **Traffic** page and overview charts: requests/s, latency p50/p95/p99, 4xx/5xx, bandwidth,
  connections, TLS handshakes per site (with its domains), listener, instance and method,
  from the instances' metrics (2 s samples, 15 min kept, server-sent events).
- **Configuration** rebuilt on JSON Schemas of the config structs (`scalws-config` feature
  `schema`, `scalws-controller config-schema`): Server, Listeners & TLS, Tuning, Security,
  Cache, Logging & metrics, Sites, PHP / FastCGI, Proxy & applications, Advanced and
  Adaptive Runtime (controller.yaml) pages with every field pre-filled, defaults, units,
  inline validation, set/changed markers, reset and undo, search; review lists changed
  settings before the text diff; controller.yaml applies by controller restart with
  automatic restore. `scalws-controller check-config`.
- New design system (tokens, rail navigation, metric strip, charts with table views, status
  shapes, dark and light), screenshots in `docs/console-screenshots/`.

### Added (2026-10-07): ScalWS Console (web administration, port 8090)
- **`scalws-console`** (`cmd/scalws-console`, `docs/console-*.md`): HTTPS web administration
  shipped with ScalWS (same packages, own unit `scalws-console.service`, enabled by the
  installer, which creates user `admin` with a random password and prints it once). Separate
  process; talks to `scalws-controller` over its local socket only.
- Overview, Adaptive Runtime (decision and pressure contributors, distribution, instances,
  desired count, autoscaling mode), Listeners (socket generations, QUIC demux), Logs, Audit
  log, About (versions, capability matrix, accounts).
- Configuration transactions: drafts (raw YAML editor and structured listeners / sites /
  limits editor), validation (`scalws-config` + `scalwsd --check`), redacted diff and impact,
  apply as a new generation with health check and automatic restore of the previous file,
  history with restore, conflict detection (base hash), idempotent operations.
- Security: argon2id credentials file (re-read on change, refused when readable by others),
  server-side sessions, `__Host-` cookie, CSRF token + same-origin, login throttling,
  re-authentication for apply/rollback/purge, strict CSP, roles administrator / operator /
  developer / viewer checked server-side, secrets redacted in every view and in the
  append-only audit log.

### Added (2026-10-07): remaining gaps: listener generations, HTTP/3 with several instances
- **Listener generations** (ADR-0037, `docs/listener-generations.md`): `reload` adds and
  removes ports, changes bind addresses, adds HTTPS, IPv6 or HTTP/3 without restarting the
  controller. New addresses are bound before the generation is published (a failed bind
  rejects the reload, nothing changes); a socket is closed when no generation uses it.
  A restarted controller takes the sockets back from running instances (one queue per
  address survives). A generation whose instances do not start is rolled back while the
  previous one serves.
- **HTTP/3 with several instances** (ADR-0039 … 0041, `docs/http3-multi-instance.md`): the
  controller's QUIC demux (`scalws-controller quic-lb`) routes datagrams by routable,
  encrypted connection IDs; new connections are placed on instances that accept them;
  replies leave directly on the shared UDP socket. Scale-out/in, rebinding, controller
  restart and demux crash keep established connections. `scalws-controller quic-lb-status`.
- **Connection distribution** (ADR-0038, `docs/connection-distribution.md`): per-instance
  work, pressure imbalance and a `harmful` flag in `status`; logged, not acted on.
- `scalws-h3-probe` (`bench/h3probe`): HTTP/3 load and correctness client (pinned test
  certificate, rebinding, truncation/reset/refused counts). `scripts/controller-h3.sh`,
  `scripts/controller-listeners.sh`, `scripts/controller-soak.sh`, `bench/h3-instances.sh`.

### Fixed (2026-10-07, found by the soak and the new tests)
- HTTP/3 shutdown closed every connection at once (also with one instance); connections
  now drain: GOAWAY, in-flight requests finish, the server waits for the client to close
  (response bytes in flight are not discarded), then `H3_NO_ERROR`.
- `scalwsd --worker-threads` without `event_loops` in the file made **every** reload fail
  ("requires a restart"): the event-loop count was applied at start only. Under the
  controller this meant limit shares never reached running instances.
- Per-IP limits were part of the restart-only topology: changing them (or the instance's
  share) rejected the whole reload. They now change on reload; only switching per-IP
  limiting on/off or its table size needs a restart. Reload errors name what changed.
- An instance could fail to receive its sockets (EPIPE): it wrote its id in two writes
  while the controller answered after the first.

### Added (2026-10-07): Adaptive Runtime limitations addressed
- Controller `listen: inherited` (new default): the controller opens the listeners once and
  hands them to its instances (`SCM_RIGHTS`, `scalwsd --listen-socket`); every instance
  accepts from one queue. Scale-in no longer needs `net.ipv4.tcp_migrate_req`; no failed
  request over 120 rolling reloads under connection churn (reuseport: 3); with a new
  connection per request +8…17 % req/s and lower p99; equal with keep-alive.
  `listen: reuseport` keeps the previous behaviour.
- WebSocket tunnels end with a close frame `1001 Going Away` at a frame boundary when the
  server drains (scale-in, restart, SIGTERM), after the HTTP connections; clients reconnect.
  Test: `scripts/controller-ws-drain.sh` (dependency-free echo server/client in
  `bench/apps/ws`).

### Fixed (2026-10-07)
- Per-core event loops dropped their runtime as soon as the HTTP drain finished, killing
  tasks that the next shutdown step still needed (WebSocket tunnels were cut without a
  close frame in about half of the scale-ins). Loops now run until the server stops them.

### Changed (2026-10-07): renamed to Scale Web Server (ScalWS), https://scalws.com
| Before | Now |
|---|---|
| `scb-webd` | `scalwsd` (web server daemon) |
| `scbctl` | `scalwsctl` (CLI) |
| `scb-controller` | `scalws-controller` (ScalWS Adaptive Runtime controller) |
| crates `scb-*` | `scalws-*` |
| package `scb-web` | `scalws` |
| `/etc/scb`, `/run/scb`, `/var/lib/scb`, user/group `scb` | `/etc/scalws`, `/run/scalws`, `/var/lib/scalws`, `scalws` |
| metrics `scb_*` | `scalws_*` |
| environment `SCB_*` | `SCALWS_*` |
| response header `server: scb` | `server: scalws` |

The on-disk response-cache format keeps its magic (`SCBC1`); existing disk caches stay
valid. Records written before the rename (pre-Adaptive-Runtime baseline and backup,
dated benchmark reports) keep the old names: they describe artefacts that carry them.

### Added (Adaptive Runtime, 2026-10-07)
- `scalws-controller` and the ScalWS Adaptive Runtime (ADR-0033…0036): several `scalwsd`
  instances on SO_REUSEPORT listeners, lifecycle and generations, observe-only and
  web-tier autoscaling, limit sharing, cache purge fan-out; `docs/adaptive-runtime.md`.
- Drain: responses after the shutdown signal carry `Connection: close`; fresh and idle
  connections get a grace period; accept loops are tracked by the drain.

### Added (performance and .htaccess, 2026-10-06)
- Per-core event loops (`server.event_loops`, ADR-0029): one current-thread runtime per
  CPU sharing the listening socket; per-loop upstream and FastCGI connection pools.
- Open file cache for static files (`server.open_file_cache`, ADR-0028).
- Kernel TLS for HTTPS/1.1 (`server.ktls`, opt-in, ADR-0030): large files with `sendfile`
  over TLS.
- `.htaccess` support (`applications[].htaccess: true`, ADR-0031): mod_rewrite, mod_alias,
  access rules, ErrorDocument, DirectoryIndex, Header, Expires; new crate `scalws-htaccess`.
- mimalloc as the global allocator of scalwsd (feature `mimalloc`, default on).

### Changed
- Connections are served by hyper's HTTP/1 or HTTP/2 builder directly (protocol from ALPN
  or a peek at the first bytes) instead of hyper-util's auto-detection; TLS without ALPN is
  HTTP/1.1 (RFC 9113 §3.2).
- Response cache: hit-for-pass markers (10 s) for responses that cannot be stored, sharded
  miss-coalescing map, pre-resolved lookup counters; request metrics resolved once per
  label combination.
- Accept loops take a connection before waiting for a connection slot (fair with several
  sockets).

### Added (tenant users and zero-copy files, 2026-10-06)
- `tenants[].user` (ADR-0026): the tenant's PHP-FPM/Node/Python processes run as that
  account (setpriv; no capabilities, no new privileges), own socket directory `2770`;
  needs CAP_SETUID, CAP_SETGID, CAP_CHOWN and CAP_KILL, checked at activation.
- Large static files on plain-TCP HTTP/1 are sent with `sendfile(2)` (ADR-0027,
  `server.sendfile`, default on): 1 MiB files ~1.8× faster.

### Fixed
- Proxied responses kept the upstream's HTTP version (an HTTP/1.0 upstream answered
  HTTP/1.1 clients with `HTTP/1.0`); the client connection now decides.

### Added (hardening and serving, 2026-10-06)
- Application processes die with scalwsd even when it is SIGKILLed outside systemd
  (`setpriv --pdeathsig TERM`); processes left in cgroup leaves by a previous instance are
  killed at start (`cgroup.kill`).
- Metric series of tenants/applications removed by a reload are dropped (after the old
  generation drained).
- `scalws_tls_certificate_expiry_seconds{listener,certificate}` for configured certificates;
  warning 14 days before expiry, error once expired.
- Static `precompressed: true`: `.br` / `.gz` siblings by `Accept-Encoding` q-values, with
  `Vary: Accept-Encoding`; siblings older than the file are ignored.
- Response cache: concurrent misses for one URL are coalesced (one upstream request;
  others wait up to 5 s and are answered from the cache).
- `security.rate_limits: [{path, requests_per_second, burst}]` per client address
  (429 + `Retry-After`, `scalws_security_blocked_total{reason="route_rate"}`).

### Added (eBPF network accounting, 2026-10-06)
- Optional `scalws-ebpf` (feature `ebpf`, ADR-0025): cgroup_skb programs count network bytes
  and packets per application cgroup; `server.ebpf.network: true` publishes
  `scalws_app_network_bytes` / `scalws_app_network_packets`. Load failures are warnings only.

### Added (cache disk tier, 2026-10-06)
- `server.cache.disk` (ADR-0024): disk tier for evicted and oversized entries, bounded
  size with LRU, asynchronous writes, persistent across restarts, purge/invalidation on
  both tiers; metrics `scalws_cache_disk_entries`, `scalws_cache_disk_bytes`.

### Added (Python process pool, 2026-10-06)
- Python `process_pool: true`: scalws runs `workers.min..max` single-worker server processes
  (uvicorn/hypercorn/gunicorn with one worker each) as a scalable pool: live scaling by
  the optimizer or `scalwsctl scale`, zero-drop `scalwsctl restart`.

### Added (ARM64 packages, 2026-10-06)
- `ARCH=arm64 scripts/package.sh [--verify]`: aarch64 cross-compiled DEB/RPM, verified in
  arm64 Debian 12 and Fedora 41 containers (QEMU).

### Added (AI advisor over HTTPS, 2026-10-06)
- `server.ai.endpoint` may be `https://` (system roots plus optional `ai.ca_bundle`);
  non-loopback endpoints still need `allow_remote: true`.

### Added (remote administration, 2026-10-06)
- `server.admin.remote` (ADR-0023): admin API over TCP with mandatory client
  certificates (mutual TLS, TLS 1.3); mutations audited with the certificate subject;
  `scalwsctl --remote host:port --ca … --client-cert … --client-key …`.

### Added (trusted proxies, 2026-10-06)
- `server.trusted_proxies` (ADR-0022): client address from `X-Forwarded-For` of trusted
  peers only (right-most untrusted entry), forwarded chain extended upstream; PROXY
  protocol v1/v2 per listener (`proxy_protocol: true`), untrusted peers refused; per-source
  limits, access logs and `REMOTE_ADDR` use the real client.

### Changed (proxy performance, 2026-10-06)
- Reverse proxy drives upstream HTTP/1.1 connections inside the request task with its
  own LIFO pool instead of hyper-util's per-connection tasks: +28 % rps, −15 % CPU per
  request (0.51× → 0.66× nginx on the 13-byte proxy benchmark).
  `docs/benchmarks/2026-10-06-proxy-profile.md`; diagnostic `scripts/proxy-compare.sh`.

### Added (M10 multi-node design, 2026-10-06)
- ADR-0021: multi-node control plane design (pull-based controller, signed configuration
  bundles, staged rollout and rollback). Design only; no implementation.

### Added (M10 container runtime, 2026-10-06)
- `runtime: {type: container}` (ADR-0020, crate `scalws-runtime-container`): containers run
  by `podman run` / `docker run` as supervised workers in a scalable pool; bridge (loopback
  publish) or host networking; `--security-opt no-new-privileges`, `--init`, optional
  read-only root, dropped capabilities, user, validated bind mounts, pull policy; with
  podman and cgroups, containers live under the application's tenant cgroup.
- Supervisor `cleanup` hook (argv run after every worker exit): no container outlives
  its worker.
- Linux test image: podman + catatonit; end-to-end container test.

### Added (M10 HTTP/3 evaluation, 2026-10-06)
- Experimental HTTP/3 over QUIC behind the cargo feature `http3` (ADR-0019; quinn, h3):
  `listener.http3: true`, same pipeline as HTTP/1.1/2, reloadable/ACME certificates,
  global and per-source connection limits, GOAWAY on shutdown, `Alt-Svc` on TCP.
- Bench: `h3-static-small` scenario (scalws vs Caddy), HTTP/3 in the soak test;
  `docs/benchmarks/2026-10-06-http3.md`.

### Fixed
- HTTP/3: completed request tasks were kept per connection until it closed (found by
  the benchmark before release: 1.1 GiB after 10 s).

### Added (M10 ACME, 2026-10-05)
- ACME certificate automation (ADR-0018, `instant-acme`): HTTP-01, one certificate per
  application (`acme: true`), served on listeners with `tls: {acme: true}`, renewal
  through the configuration controller (no restart), per-application backoff, state in
  `server.acme.state_dir` (0600 keys), `GET /v1/certs`, `scalwsctl certs`, metrics
  `scalws_acme_orders_total`, `scalws_acme_certificate_expiry_seconds`.
- `scripts/acme-e2e.sh`: issuance, reload-triggered renewal and restart against Pebble.
- Durations accept days (`30d`).
- systemd unit: `StateDirectory=scalws` (/var/lib/scalws writable under ProtectSystem=strict).

### Added (acceptance gate 6, 2026-10-05)
- `bench/soak.sh`: sustained mixed load over every serving path with RSS/fd/thread
  sampling and a pass/fail verdict; `bench/overload.sh`: quota overload with refusal,
  memory, isolation and recovery checks. Both pass (30-minute soak: 43 M requests, flat
  memory). Bench upstream: `/api/delay` (50 ms).

### Fixed
- Wording of the "running as root" warning.

### Added (M9 operations, 2026-10-05)
- Admin API on a Unix socket (`server.admin.socket`, default `<runtime_dir>/admin.sock`,
  mode 0660) with audited mutations: reload, rollback, application restart, scale, cache
  purge, explain requests; views: status, apps, tenants, config history and diff,
  diagnose, optimizer, explain (ADR-0017).
- Configuration controller with history of the last 10 configurations, rollback, line
  diff, and zero-drop per-application restart.
- Read-only dashboard at `/dashboard` on the metrics listener.
- `scalwsctl`: status, apps, tenants, top, reload, rollback, history, diff, restart, scale,
  purge, backup, restore, completion; global `--config`, `--socket`, `--address`.
- DEB/RPM packaging (`packaging/nfpm.yaml`, `scripts/package.sh [--verify]`), `scalws`
  system user, package default configuration, shell completions;
  `docs/OPERATIONS.md`.

### Changed
- Cache purge and explain requests moved from the metrics listener to the admin socket;
  the metrics listener is read-only (`POST` → 403).
- `workers.autoscale` accepts the YAML 1.1 boolean `off`/`false` as `off`.
- systemd unit: `RuntimeDirectoryMode=0750` so group `scalws` reaches the admin socket.

### Added (M8 local AI advisor, 2026-10-05)
- `scalws-ai` (ADR-0016): redaction of all model input, size-capped input preparation,
  advice JSON schema with strict validation, OpenAI-compatible HTTP provider.
- Advisor service: `server.ai` (disabled by default; loopback endpoint unless
  `allow_remote`; `api_key_env`; `timeout`, `max_queue`, `min_interval`, `max_tokens`),
  automatic explanations on new warning/critical findings, `GET/POST /explain`,
  `scalwsctl explain [--refresh]`, metrics `scalws_ai_requests_total`, `scalws_ai_queue_depth`.

### Added (M7 diagnostics, 2026-10-05)
- `scalws-diag` (ADR-0015): deterministic findings with severity, evidence, suggestion and
  correlated resource causes.
- Evidence collection per window: upstream failures by reason, quota rejections, runtime
  state and restarts, cgroup v2 memory/limit, OOM kills and pressure stall information.
- Recent failed/slow requests per application (`server.diagnostics.slow_request`,
  `recent_requests`); `GET /diagnose[?app=tenant/app]`; `scalwsctl diagnose`.
- Metrics `scalws_diagnostic_findings_total`, `scalws_http_response_transfer_seconds`,
  `scalws_tls_handshake_seconds`; log target `scalws::diag`.

### Changed
- Responses refused by tenant quotas no longer count as application requests in the
  optimizer telemetry.

### Added (M6 deterministic optimizer, 2026-10-05)
- `scalws-policy` (ADR-0014): pure rule engine (scale_up/scale_down with bands, streaks,
  cooldowns, bounds and memory precondition; outcome observation with rollback and rule
  suppression; memory-pressure and error-rate advisories).
- Per-application telemetry (requests, 5xx, latency percentiles, in-flight, cache hit
  ratio, tenant memory pressure) and the optimizer task.
- Live worker scaling of managed Node.js pools (`workers.autoscale: auto`); Python
  recommendations; PHP advisories.
- Audit: `scalws::audit` log target, `scalws_optimizer_decisions_total`, `GET /optimizer` journal
  on the admin listener, `scalwsctl recommendations`.
- Configuration: `server.optimizer {enabled, interval, journal_size}`,
  `workers.target_concurrency`.

### Changed
- `workers.autoscale` defaults to `recommend` (recommend-only by default).

### Added (M5 cache and security, 2026-10-05)
- `scalws-cache` (ADR-0012): opt-in bounded memory response cache (moka) with explicit
  freshness only, `Vary` variants, profile/config bypass rules, stale-while-revalidate
  with single-flight refresh, invalidation on unsafe requests, purge by URL, prefix, tag
  or all (`POST /cache/purge` on the loopback admin listener), `X-Cache`/`Age` headers.
- `scalws-security` (ADR-0013): profile + configured deny paths; per-source connection limit
  at accept and request rate (IPv4 / IPv6 /64) with bounded sharded state.
- `limits.write_timeout` for slow readers; `strict_sni` listeners answer 421.
- Metrics `scalws_cache_lookups_total`, `scalws_cache_entries`, `scalws_cache_bytes`,
  `scalws_security_blocked_total`; rejection reason `source_connection_limit`.
- Property-based fuzz tests for path/host normalisation, ranges, Cache-Control, CGI
  headers, units and configuration parsing.
- Benchmark scenario `cache-hit`.

### Added (M4 application profiles, 2026-10-05)
- `scalws-profiles` (ADR-0011): profiles as YAML data in `profiles/` (php, wordpress,
  woocommerce, laravel, node, nextjs, python, django, flask, fastapi) with weighted
  detection rules, runtime templates, health checks, static paths, cache-bypass and
  security rules.
- Detection engine with evidence and confidence; bounded, symlink-free scanning; fact
  extraction (Python application object, Django WSGI module, virtualenv, npm command).
- `scalwsctl detect <dir> [--json]` (read-only proposal) and `scalwsctl profiles`.
- `profile:` application key: supplies the runtime when omitted (static profiles) and
  health checks; `runtime` is optional when a profile is set.

### Added (M3 tenancy, 2026-10-05)
- `scalws-cgroups` (ADR-0010): cgroup v2 hierarchy under scalws's delegated group (or
  `server.cgroups.path`), tenant limits `cpu`, `memory` (+ `swap`, default 0), `pids`,
  `io_weight`; workers join `tenants/<tenant>/<app>` before their first instruction;
  limits rewritten on reload; removed groups pruned; modes `auto`/`required`/`off`.
- Per-tenant request quotas: `max_concurrent_requests` (503) and `requests_per_second`
  + `burst` (429), metric `scalws_tenant_limited_total`.
- Accounting metrics `scalws_tenant_{cpu_seconds,memory_bytes,pids,oom_kills}`,
  `scalws_app_{cpu_seconds,memory_bytes,pids}`, `scalws_cgroups_enabled`.
- systemd unit: `Delegate=yes`, `KillMode=control-group`, `RuntimeDirectory=scalws`.
- Linux test runs use a privileged container with a delegated cgroup root; OOM isolation
  and live limit change are tested end to end.

### Added (M2 runtime platform, 2026-10-05)
- Process supervisor (ADR-0008): argv without shell, cleared environment, own process
  group, readiness probes (socket or HTTP path), exponential backoff, restart-loop
  detection (`Failed`), graceful stop (SIGTERM/SIGQUIT then SIGKILL), rate-limited and
  sanitised stdout/stderr capture.
- `scalws-runtime-node`: managed Node.js processes (N workers, round-robin over ready ones)
  or external upstreams.
- `scalws-runtime-python`: ASGI (uvicorn, hypercorn, gunicorn + UvicornWorker) and WSGI
  (gunicorn) launch templates, virtualenvs, explicit commands with `{socket}`/`{port}`.
- `scalws-runtime-php` (ADR-0009): managed PHP-FPM pools with generated configuration or
  external FastCGI endpoints; PHP/static/front-controller routing with `PATH_INFO`; CGI
  response parsing; httpoxy protection; `.php` never served as static content.
- Reverse proxy: WebSocket tunnelling with a server-wide limit and idle timeout; HTTPS
  upstreams (system roots + optional CA file).
- Reloads reuse unchanged runtime instances; new ones start before the swap, retired ones
  drain in the background.
- Metrics `scalws_runtime_ready_workers`, `scalws_runtime_restarts_total`.
- Integration tests for supervision and acceptance tests with real PHP-FPM, Node.js,
  uvicorn and gunicorn; Linux test image `docker/test.Dockerfile`; CI installs runtimes.
- Benchmarks: PHP, Node and Python scenarios for scalws, nginx and Caddy.

### Changed (2026-10-05, PHP performance)
- Persistent FastCGI connections (`FCGI_KEEP_CONN`) to managed PHP-FPM pools, bounded by
  `max_children`, with stale-connection detection and replay of small requests; 2 s
  routing plan cache. PHP throughput 0.70× → 0.93–1.0× nginx, CPU per request −34 %.
- PHP request bodies ≤ 64 KiB are buffered (replayable); larger ones stream.

### Changed (M2)
- `server.runtime_dir`, `limits.max_upgraded_connections`, `limits.upgraded_idle_timeout`
  configuration keys; `proxy` runtime gains `websocket` and `tls_ca_file`.
- PHP request planning uses the same non-blocking cached lookup as static files.

### Changed (2026-10-05, static file performance)
- Static files: Linux lookups via `openat2(RESOLVE_BENEATH | RESOLVE_NO_MAGICLINKS)` from
  a root directory fd (closes the symlink TOCTOU window); non-blocking hot path with
  `RESOLVE_CACHED` + `preadv2(RWF_NOWAIT)`; small files read in the lookup call; large
  files streamed with 256 KiB positional reads. 3.4× (13 B) and 4.6× (1 MiB) throughput.
- Absolute symlinks inside a document root are now refused on Linux (ADR-0006).
- `scripts/profile.sh`: perf-based profiling of any benchmark scenario.

### Added (M0 + M1 vertical slice, 2026-10-05)
- Workspace, ADRs 0001–0007, architecture and threat-model documents.
- `scalws-config`: YAML schema with `deny_unknown_fields`, size/duration/CPU units, upstream
  parsing, semantic validation that reports every error with its document path.
- `scalws-router`: host routing (exact + wildcard) and segment-aligned path routing on
  normalised paths.
- `scalws-tls`: PEM loading, key/cert match and SAN coverage checks, SNI resolver with
  atomic replacement on reload.
- `scalws-static`: confined static files (traversal, encoded-slash, dotfile and symlink
  protections), ETag/Last-Modified, conditional and single-range requests.
- `scalws-proxy`: HTTP/1.1 reverse proxy over TCP and Unix sockets with hop-by-hop
  stripping, forwarding headers, timeouts, failure classification.
- `scalws-http`: accept loop with connection cap, TLS handshake timeout, HTTP/1.1 + HTTP/2
  limits, idle-connection closing, graceful drain.
- `scalws-server`: request pipeline, prepare/activate/reload, `/metrics` and `/healthz`.
- `scalwsd` daemon (SIGHUP reload, SIGTERM drain) and `scalwsctl check`.
- Integration and security test suites; Docker-based benchmark harness with nginx and
  Caddy comparison configs; CI workflow; cargo-deny policy; systemd unit.
