Changelog
All notable changes to Conduit are documented here. Format follows Keep a Changelog.
Unreleased
Removed
- Direct dependencies that no code used any more, left over from the move into member crates (#777):
anyhow,axum,dashmap,indexmap,pingora-core,pingora-http,pingora-proxy,serde_yamlandx509-parserfrom the root crate,anyhow,serdeandtempfilefromlopatnov-conduit-runtime. Every crate stays in the build through the member crates that do use it, so binaries are unchanged.
Changed
-
An IPv4-mapped IPv6 network shorter than
/96is refused inipFilter,proxyProtocol.trustedSourcesandPOST /ip-deny(::ffff:10.0.0.0/8). The prefix of such a network counts bits of the 128-bit address, so it is the IPv6::/8and would name every IPv4 address; write::ffff:10.0.0.0/104(96 plus the IPv4 prefix) or plain10.0.0.0/8. Before, the prefix was read as an IPv4 one, so a config that spelled it this way now stops at start with an error instead of being widened. - A
tcpconnection that is quiet in both directions for an hour is now closed (tcp.idleTimeoutSecs, default 3600;0keeps the old never-closed behaviour). Before, a connection lived until a side closed it, so a client that vanished without closing held a slot for ever. A session that must stay silent for longer (an idle SSH login, a database pool with a long idle time) needs a larger value or0. - A reload that adds, removes or changes a
tcpsite is refused as a cold change (restart to apply). The TCP services are registered once at start, so such a reload used to be accepted and silently left the old targets in use. - The
ConduitSiteAPI group is nowconduit.lopatnov.github.io(wasconduit.io) (#573; breaking for anyone who installed the CRD).conduit.iois a domain nobody here owns, so no one could vouch for the name and anyone who registered it could have claimed it; the new group is a subdomain of the project’s own address. The version staysv1. Objects of the old group are not read: keep the manifests you applied (or export the objects, seedocs/kubernetes.md), delete the old CRD (kubectl delete crd conduitsites.conduit.io, which deletes its objects), apply the newcontrib/k8s/conduitsite-crd.yaml, changeapiVersiontoconduit.lopatnov.github.io/v1in the manifests, change the RBACRole’sapiGroupstoconduit.lopatnov.github.io, and apply the manifests again (the sites are gone until you do). Without the newapiGroups, the pod gets a 403 on the list and says so in its log.
Fixed
-
Kubernetes startup now installs rustls’s
ringprovider before creating the Kubernetes client. Builds that include both rustls providers previously panicked before loading their initialConduitSiteconfiguration. -
The Kubernetes provider retries a failed watch with exponential backoff and reloads the current ConduitSite list after reconnecting. A transport error could otherwise leave a replica serving stale configuration indefinitely.
Added
contrib/k8s/example-site.yamlhas aServicein front of its Deployment (port 80 to the sites’ port 8080), asdocs/kubernetes.mddescribes; before, the example applied cleanly but nothing routed to the pods.-
An end-to-end test on a real Kubernetes API server (#764; CI job
e2e-kubernetes,scripts/e2e/kubernetes.sh): k3s in Docker runs the shipped CRD and example manifests with the CI binary, and checks requests through the Service,ConduitSiteobjects added, edited, broken and deleted while Conduit runs (no pod restart, last good version kept,503for a new invalid site),status.readywritten back, the exit withkubernetes provider erroron a Role for the old API group, andCONDUIT_REDIS_URLfrom aSecretsharing one rate limit between two replicas. - TLS termination on
tcpsites (#757, item 3 of 5): atcpsite withtls: { cert, key }terminates TLS and relays the decrypted bytes to the upstream;tls.clientAuth(mutual TLS) keeps a client without a certificate of the CA from the upstream;proxyProtocolon such a site is read before the handshake, so the client address in the header is the one the caps count andsendProxyProtocolpasses on. Refused on such a site:tls.acme,tls.httpRedirectPortand a missingport, andport: 0together withproxyProtocol. A changedtlsblock of atcpsite is a cold change (restart), and so is a changedtls.clientAuthof an HTTPS port, ACME ones included (it was not detected before). Before, atlsblock with a certificate on atcpsite was accepted and ignored, so the port served plaintext. Tests:tests/tcp_tls.rs(real TLS client) andscripts/e2e/tcp-tls.sh. - The Redis address is set once, by the operator (#760).
global.redis.urlin a file config, or theCONDUIT_REDIS_URLenvironment variable for a pod that readsConduitSiteobjects (aConduitSitecannot setglobal; the value is trimmed, andglobal.redis.urlwins when both are set). Sites, routes and consumers writestore: redis(rate limits and caches), with no address, and all of them share the process’s one Redis connection as before.store: rediswith no address anywhere is a validation error. Astore: "redis://host"written on a site still works and is now deprecated: a warning at start and on reload, and a validation error when it differs fromglobal.redis.url. AConduitSitethat names aredis://orrediss://address is refused like a host path, so a writer of one site can no longer send the counters (client IPs) or cached responses of every site to a Redis of their choice. The address is read at startup: a change takes a restart, and a reload that changes it is refused (cold field). - Connection limits and an idle timeout for
tcpsites (#757, item 1 of 5):tcp.maxConnections(connections open on the site),tcp.maxConnectionsPerIp(per client address; IPv6 per /64) andtcp.idleTimeoutSecs. A connection over a cap is closed at accept, before any upstream is tried, and the refusals are logged as one line per site every 10 seconds. Zero caps are a validation error. TheTcpConfigblock is now inschema/conduit.schema.json. Proven by unit tests (crates/conduit-tcp), real sockets throughprocess_new, and the e2e scenarioscripts/e2e/tcp-limits.sh. - The PROXY protocol, versions 1 and 2 (#757, item 2 of 5):
sites[].proxyProtocolreads the header of a load balancer in front of Conduit on plain HTTP ports (before HTTP parsing), TLS ports (before the TLS handshake) andtcpsites, andtcp.sendProxyProtocol: v1 | v2writes one to the upstream. The header is required and believed only fromtrustedSources; any other connection, a missing or invalid header and one that is not complete withintimeoutMsis closed. The client of the header is the client foripFilter, rate limits,tcp.maxConnectionsPerIp, logs andX-Forwarded-For. A change is a cold change, and sites sharing an HTTP or HTTPS port must agree. The CIDR matcher ofipFiltermoved intoconduit-config-coreto be shared. Proven by unit tests (the parser against truncated, oversized and malicious input), real sockets, a real server with HTTP and TLS clients (tests/proxy_protocol.rs), a TCP client (tests/tcp_proxy.rs) and the e2e scenarioscripts/e2e/proxy-protocol.shwith HAProxy. - A Kubernetes guide,
docs/kubernetes.md(#573): the CRD, RBAC and Deployment, a first site, what aConduitSitemay contain, what is checked on each change and what a rejected update leaves (the whole previous config), what needs a restart (a new port,tls.acme), who may write the objects, and troubleshooting. EveryConduitSitein the guide, incontrib/k8s/example-site.yamland the other manifests is checked by a test (the_documented_conduitsite_manifests_are_accepted); the example site used afallback.file, which aConduitSiterefuses, and the deployment guide’s earlier ACME example settls.acme.storage, which is refused too. - A protocol guide,
docs/protocols.md: for SSE, WebSocket, gRPC, GraphQL, HLS/DASH, WebRTC, RTMP, MQTT, PostgreSQL, Redis, SMTP, FTP and SFTP/SSH it says whether the protocol is an HTTP route or a TCP site, gives a working config, the limits (idle timeout, no TLS termination or PROXY protocol on TCP sites, FTP passive ports, no UDP) and which e2e scenario tests it. The TCP section ofdocs/configuration.mdpoints to it. ws://andwss://are accepted in proxytargetsashttp://andhttps://(a WebSocket handshake is an HTTP request, RFC 6455 section 4.1); the validation message lists all four schemes.- A WebDAV section in the protocol guide and an e2e scenario,
scripts/e2e/webdav.sh: the WebDAV methods, their bodies and theDepth,Overwrite,Timeout,Lock-Token,If,Destinationheaders reach the upstream as sent (a 1 MiBPUTby SHA-256), and theDAVandLock-Tokenresponse headers come back. Conduit does not rewriteDestination,Ifor multistatushrefs; the guide says what that means forstripPrefix. rewriteDestination: trueon a proxy route (WebDAV, opt-in, default off): applies the route’sstripPrefixandrewriterules to the paths in theDestinationandIfrequest headers, so aCOPYorMOVEthrough a stripping route names a resource the upstream knows. The authority, the query, the state tokens ofIfand URLs of another host are left alone.http2: "h2c"on a proxy route: HTTP/2 with prior knowledge (RFC 9113 section 3.3) to a plaintext upstream, so gRPC servers without TLS can be proxied.http2: truestill means ALPN only, and over TLS"h2c"behaves liketrue.-
Three e2e scenarios in
scripts/e2e/:streaming.sh(SSE and WebSocket over plain HTTP and TLS: events not held back,Last-Event-ID, the idle timeouttimeout.readMs, upgrade, ping/pong, fragments, a 1 MiB binary message, close codes, 502 withoutwebsocket: true),grpc.sh(unary, streaming, error status, deadline over h2c, TLS and a TLS upstream) andprotocols.sh(Redis, MQTT, PostgreSQL, SMTP, SSH, RTMP, FTP with a passive data port and TLS passthrough through TCP sites). The e2e client image gainspython3-grpcio. - Third-party licence notices (#640).
THIRD-PARTY-LICENSES.txtlists every crate that can end up in a binary with its licence and the licence and notice texts it ships (including the CDLA-Permissive-2.0 text of the bundled root certificates); it is inside every release archive (withLICENSE), the Debian package, the Docker image (/licenses/) and a release asset, and the npm package carries it gzipped.scripts/third_party_licenses.pygenerates it and the newlicensesCI job checks the allow-list inci/license-policy.jsonand that the file is current. The README has a “Technologies stack” section, anddocs/technologies.mdthe longer list. - mimalloc, in its hardened
securemode (guard pages around allocator metadata, encoded free lists, randomised allocation addresses, double-free detection), is the global allocator of theconduitbinary (#486, #516): featuremimalloc, indefaultand in every bundle (standard,gateway,static-server,full);--features jemallocuses jemalloc instead (with both on, jemalloc is used);--no-default-featureskeeps the system allocator. On the passthrough benchmark (4 cores,workers: 1, 5 ABBA rounds) it served 3.8 % more requests per second at 3.9 % less CPU per request than the system allocator for +225 KiB of binary, as fast as jemalloc (+2.1 % for jemalloc, within noise); mimalloc withoutsecurewas 11.6 % faster than with it and is not offered. Seedocs/building.md, “Allocator”. - External processing filter (#27): a
middlewareentrytype: "ext_proc"(featureext-proc, part offull) talks to a gRPC processor that speaks Envoy’sext_procprotocol. Per entry, what is sent is chosen: the request headers (default,requestPhase), the request body (requestBody: bufferedheld up tomaxBodyBytesand refused with 413 above it, orstreamedchunk by chunk), the response headers (responsePhase) and a copy of the response body (responseBody: observe). The processor can set and remove headers (Envoy’s append actions, a fixed list of headers it may not touch, caps on count and value size), rewrite the request body, replace the response, or end the request with an immediate response. A request whose body is rewritten is forwarded with chunked framing. Fail-closed by default: a processor that is unreachable, later thantimeoutMs(200 ms) or answers with something not accepted refuses the request withstatusOnError(503);failOpen: truelets it continue. A build without the feature refuses to start with a fail-closed entry. Not implemented: trailers, rewriting the response body, a per-route override (Conduit has no per-route middleware). Tested against an in-process processor and against a processor generated from Envoy’s own.protofiles (scripts/e2e/). A guide of its own,docs/ext-proc.md(with a runnable sample processor inexamples/ext-proc/), sits beside the Rhai and WASM guides. - The ACME time limits are configurable under
tls.acme, with today’s values as the defaults:orderTimeoutSecs(60),validationTimeoutSecs(180),ariTimeoutSecs(30),retryAfterMinSecs(300),retryAfterMaxSecs(86400) andcheckIntervalSecs(43200). Each must be 1 to 86400 seconds (60 to 86400 forretryAfterMinSecs, 300 to 86400 forcheckIntervalSecs, so that a CA that limits failed orders is not polled every few seconds) and the minimum must not exceed the maximum, otherwise validation fails. The renewal loop is shared by all sites, so the shortestcheckIntervalSecscounts. They are read at start-up like the rest oftls.acme. An inverted clamp no longer risks a panic in the renewal loop (#746). sticky.secureandsticky.maxAgeSecs: theSecureandMax-Ageof the cookie Conduit sets insecretmode.secureunset means “when the site hastls”;maxAgeSecsunset is a session cookie,0is rejected (#644).sticky.sameSite(lax, the default,strictornone): theSameSiteof that cookie.nonealways addsSecure(browsers refuse it otherwise) andsecure: falsetogether with it is a validation error (#644).- ACME renewal follows the CA’s renewal information (ARI, RFC 9773): the 12-hour check asks the CA for the renewal window of
each certificate and renews inside it, earlier than the lifetime rule when the CA says so and never later; the renewal
order names the certificate it replaces (
replaces, which Let’s Encrypt exempts from its rate limits). No ARI, an unreachable CA or an invalid window (empty or inverted) changes nothing. The CA’sRetry-Afteris honoured: it is not asked about a certificate again before that (clamped to 5 minutes .. 24 hours) and that certificate is checked sooner than every 12 hours when the CA asks to be consulted earlier (other certificates keep their own cadence). Tests run against a mock CA (#594).
Changed
- Fewer allocations on every proxied request (#486), with no change to what a request sees: the guards that would answer
Continueand nothing else (health bypass, redirect, middleware) are not built for a request that does not need them, the guard list is sized once, the request authority is read once, routing no longer formats a key per candidate route, and an empty runtime-override table is not queried. Measured withscripts/bench/cachegrind.sh(instructions per request, one worker, 2000 and 6000 requests): bare site 152 537 → 148 329 (−2.8 %), a site withsecurityHeadersandresponseTime180 014 → 174 933 (−2.8 %). - Smaller binaries, same speed (#516): the crates that never run per proxied request (config schema and parsing, CLI, Admin
API, ACME, Kubernetes, the file watcher, and
clap,serde_yamlanddialoguerbehind the CLI) are compiled withopt-level = "s"through[profile.release.package.*]. The release binary with--no-default-featuresgoes from 13.56 MiB to 12.96 MiB (−4.5 %, two local builds); the default build is 18.13 MiB here against the 19.01 MiB of the Footprint report onmain(the Footprint report of the PR is the check). The instructions per request, measured withscripts/bench/cachegrind.shon the tree after #754 (--no-default-features --features proxy, one worker), stay at 141 019 and 142 064 (two runs) against 141 404 for the same tree without the package profiles.conduit-serveris left out on purpose: it instantiates Pingora’s generic proxy code, and compiling that for size cost +4.6 %. - A static site answers
POST,PUT,DELETE,PATCHand WebDAV’s methods for a file that exists with 405 andAllow: GET, HEAD, OPTIONS(RFC 9110 section 15.5.6); it used to answer them with the file as if they wereGET. A path with no file keeps its answer (404 or the fallback), andOPTIONSis unchanged. - An ACME order can no longer hold the renewal loop (or start-up) forever: every request of the order is limited to 60 s and the challenge validation to 180 s. A CA that accepts a connection and never answers used to block renewal of every certificate; it is now an error for that certificate and the cached pair is kept.
- The response filter chain borrows the per-request header list, the response transform, the response-time setting and
the middleware entries instead of cloning them for every response: 148 195 → 145 069 instructions per request on the
bare site and 182 758 → 176 987 with
securityHeaders,corsandresponseTime(scripts/bench/cachegrind.sh,EXTRA_SITEadds site fields) (#486).
Security
- A
ConduitSiteno longer drops the site fields its Rust type did not name (#573).jwtAuth,consumers,forwardAuth,securityHeaders,limits,tcp,outlierDetection,maskErrorsand the other fields that are not in the list of theConduitSitespec were removed by the API server (the definition was a closed schema) and again by the parser, with no message, so a site that asked for a JWT or a consumer check was served open. The definition now keeps unknown fields ofspec(x-kubernetes-preserve-unknown-fields; applycontrib/k8s/conduitsite-crd.yamlagain) and the spec keeps every field it does not name; a key that no site field matches is warned about, as in a config file. The guard against host paths (static,tls.cert, …) is unchanged, except that acache.storeof the formdisk:<path>(reachable before, a directory of the host) is now refused too (behaviour change). - One invalid
ConduitSiteno longer holds back the others (#573; behaviour change). A spec that did not convert (a host path, a wrong type) or that has a hard validation error of its own rejected the whole update, and at start it stopped the pod. The site is now logged and not active, or, when it worked before, keeps its last good version, and the other sites apply. A site that has no valid version at all answers503for itshostwhere other sites share its port, so that its requests do not fall through to the upstream of another site. A conflict between sites (onehostandporttwice) still rejects the update as a whole. Conduit now writesstatus.readyandstatus.messageof each object (theREADYcolumn ofkubectl get conduitsites); that needspatchonconduitsites/status, and without it Conduit says so once and carries on. -
The Admin API of a pod that reads
ConduitSiteobjects now always has a token (#573). It was on loopback with no token, and aConduitSitemay route to loopback (proxy: http://127.0.0.1:2019, or atcptarget), so whoever could write one could callPOST /shutdownorPOST /upstreams/addthrough their own site. The token isCONDUIT_ADMIN_TOKENfrom the pod’s environment when set (the variable the admin commands read), otherwise a random one made once at start (behaviour change: set the variable to use the Admin API in this mode). Surrounding whitespace of the variable (a mountedSecretends in a newline) is dropped, and a value under 32 characters is warned about. - A credential that is an unset environment variable is now warned about (issue #624, the “sshole” class: a failed
lookup that degrades into a value an attacker can predict).
basicAuthpasswords,apiKeykeys,jwtAuth.secret, consumer keys, passwords and secrets,consumers.sharedJwt.secret,metrics.token,sticky.secret(on aproxyroute or aroutes[]entry) andglobal.admin.tokenwhose whole value is$NAMEwithNAMEnot set kept the text$NAMEand accepted it as the credential.conduit validate, start-up and reload now warn for each one. Refusing to start would be stricter and is put to the owner (the examples and the documentation use such references on purpose).
Fixed
- A missing or non-PEM TLS certificate or key file, or a key that does not belong to the certificate, stops the start with an
error that names the file (HTTPS ports and
tcpsites withtls). Before, the paths were only stored and Pingora read the files when the listener was built, so such a start ended in a panic with no port or file in the message. - The first rate-limited request of every instance that uses
store: rediswas counted in the in-memory fallback, not in the shared bucket (the connection is made at start in a throw-away runtime, so the first command failed with a broken pipe and only the next one worked). The first use of the connection now sends aPING(which changes nothing and is repeated if it fails) before the check, so the connection is back when the request is counted; the check itself is never retried, so a request cannot be counted twice. With N instances that let N requests through above the limit once per start;scripts/e2e/redis-limit.sh(two instances, a real Redis) shows the shared limit now holds exactly. - Active health probes of an
https://orwss://upstream: the probe is plaintext HTTP/1.1, which a TLS listener does not understand, so a healthy TLS upstream was marked unhealthy (or healthy by accident, behind a server that answers plaintext on its TLS port). Such an upstream is now probed by opening a TCP connection (pathis not used for it; behaviour change). - A
tcpsite that also hadipFilter,rateLimit,basicAuth,apiKey,jwtAuth,forwardAuth,consumers,limitsormiddlewarewas accepted and the key silently ignored, so an operator could believe a database port was protected. Validation now refuses it, with a message that points to a firewall or network policy (behaviour change). - Static files and fallback
file:responses use the media types of adaptive streaming:.m3u8isapplication/vnd.apple.mpegurl(wasaudio/x-mpegurl),.m3uaudio/mpegurl,.tsvideo/mp2t(wasvideo/vnd.dlna.mpeg-tts),.m4svideo/iso.segmentand.mpdapplication/dash+xml(RFC 8216 section 4, IANA). docs/configuration.mdsaid compression applies to proxied responses. It applies to static files, fallback responses and the metrics page; proxied responses are sent as the upstream sent them.p2cno longer favours an upstream that fails fast (issue #734). A response of 500 or more (and a connect failure or timeout) now counts as at least one second in the latency estimate, so an upstream that answers every request with an error right away stops looking like the cheapest one;ewma_latency_msofGET /upstreamsshows it.- The npm launcher retries a start that fails with
ETXTBSY(issue #732). A freshly installed binary can be refused with “text file busy” for a moment on Linux (it was seen once as a flake of the launcher test, so a user ofnpxcould meet it); the launcher tries again a few times with a short pause (the download itself already resolves at the file’s close). - The feature warnings and
conduit featuresnow see acacheblock on aroutes[]entry (they looked at theproxyroute map only), and aredis://cache store counts as needingredis(only rate-limit stores did); a build withoutrediswarns that such a route will not be cached (#737).
Changed
- The sticky cookie of a site that has
tlsis nowSecureunlesssticky.secure: falsesays otherwise (a client that also talks plain HTTP to that site will not send the cookie back there); a plain-HTTP site is unchanged (#644). sticky.cookiemust be a non-empty HTTP token: a name with;, a space or a control character is a validation error (it was written into theSet-Cookieline unchanged).- A
sticky.strictrefusal answers503with the reasonsticky_upstream_unavailableinstead ofupstream_overloaded(the upstream is down, not overloaded; the status is the same) (#644). disk-cachegates the disk store now (#645): it was a flag that gated nothing. Acachebuild without it is a memory (and, withredis, Redis) cache, and a route whosecache.storeisdisk:<path>is not cached there, with a start-up warning andconduit featureslistingdisk-cache.standard,gatewayandfullinclude it, so the published builds keep the disk store; a custom--features cachebuild that useddisk:stores needs--features disk-cache.- The systemd unit (and the
.deb) is hardened further (issue #670).PrivateDevices,ProtectKernelTunables,ProtectKernelModules,ProtectKernelLogs,ProtectControlGroups,ProtectClock,ProtectHostname,RestrictSUIDSGID,RestrictRealtime,RestrictNamespaces,LockPersonality,RestrictAddressFamilies,SystemCallArchitectures=native,CapabilityBoundingSet=CAP_NET_BIND_SERVICEandUMask=0027;systemd-analyze securitygoes from 8.3 EXPOSED to 3.2 OK. The proxy, a static site, name resolution, the Admin API,systemctl reloadand port 80 through theAmbientCapabilitiesdrop-in were run under a real systemd; the WASM runtime, ACME, Redis and the Kubernetes provider were not. Upgrading: files Conduit creates (ACME account and certificates, logs, the disk cache) are no longer readable by other users (UMask=0027), and a path it writes outside/var/log/conduitand/var/cache/conduitneedsReadWritePaths=in a drop-in (docs/deployment.md) (#736).
[2.3.1] — 2026-11-14
Fixed
- The npm package no longer carries the binaries, so it can be published again (issue #712).
npm publishof@lopatnov/conduit2.3.0 failed with413 Payload Too Large: the package held the binaries of all 13 platforms inbin/native/(31-46 MB each, 208.7 MB packed, 466.1 MB unpacked; 2.2.1 was 129.1 MB with 8 platforms), so 2.3.0 is not on npm (nor on GitHub Packages) and the latest there is 2.2.1. The release job now downloads the binaries only to hash them intochecksums.json; the package is about 12 kB, and a check before the publish fails the job if it holds a binary or grows past 200 kB.
Changed
- The npm launcher downloads the binary when it is missing (issue #712). The binary of the platform comes from the
GitHub release of the package’s version, is verified against
checksums.json, and is fetched after the install (as before: a prefetch, which npm hides unless--foreground-scriptsis given) and at any run where it is not there, so an install with--ignore-scriptsor one whose download failed works at the firstconduit. Every download prints, on stderr, the source URL, the destination file, the progress and the verification. The binary is stored in the package’sbin/native/, or, when that directory cannot be written (a global install owned by root), in a per-user cache (CONDUIT_CACHE_DIRreplaces its base); the cache is for its owner only, on Linux and macOS (an entry is used only when it is not a link, belongs to the running user, cannot be written by others, and every directory above it is root’s or the user’s and not open to others; root never uses it, becausesudocan keep the user’sHOME, and Windows never does, because it cannot tell an elevated process), and a binary found there is checked against its hash at every run and replaced when it differs. A download follows redirects only to https, gives up after 60 s without data or 30 minutes in all, and refuses more than 200 MiB.CONDUIT_SKIP_DOWNLOAD=1never downloads. Seenpm/Readme.md.
Tests
- The tests of the npm package (
npm/test) run in CI, on Node 18 and 24 (issue #711); until now no job ran them. New: the launcher’s download at run time (source and destination on stderr, nothing on stdout, a second run downloads nothing, the cache fallback, a tampered or unreachable download,CONDUIT_SKIP_DOWNLOAD) and the proof that the packed package carries no binary.
[2.3.0] — 2026-11-11
Added
healthCheck.timeoutMs(issue #652): the timeout of an active probe, one deadline for the whole probe (connect, send and the first line of the answer), default 5000, minimum 1 (validaterefuses 0). The docs had listed an option that did not exist; the probe used a fixed 5 seconds for each of the three steps, so an upstream that hangs took up to 15 seconds to count as failed, and now takestimeoutMsat most (5 seconds by default).- Release builds for 32-bit Linux and for Windows ARM64 (issues #696, #671):
i686-unknown-linux-gnu,armv7-unknown-linux-gnueabihf,arm-unknown-linux-gnueabihf(ARMv6, Raspberry Pi 1 and Zero),arm-unknown-linux-gnueabiandaarch64-pc-windows-msvc, each in the four builds (full without a suffix, as a bare binary and an archive;-standard,-gateway,-staticas archives), and in the npm package forlinux-ia32,linux-arm(the ARMv7 build where Node reports ARMv7, the ARMv6 build otherwise, which runs on both) andwin32-arm64. CI builds the full build of the four Linux targets on every pull request and runs thestandardtests of the 32-bit x86 one, then runs its finished binary in ani386/debian:12container (start, static file, proxy, upload). The three 32-bit ARM builds are built and unit-tested only: the proxy-path tests cannot run under QEMU. A 32-bit x86 process in a container under the default seccomp profile of Docker 29.4.2 cannot create a socket (a regression that Docker 29.4.3 fixes; Docker 28 is fine; Docker’s notes recommend theseccomp/v0.2.1profile as the workaround;seccomp=unconfinedworks but turns off the container’s syscall filter, and both allowsocketcall, so they need a kernel with the CVE-2026-31431 fix: seedocs/building.md, issue #708). See the platform tables in the README anddocs/building.md.i686-pc-windows-msvcand Android are not released (Pingora does not compile for them; cloudflare/pingora#1119).
Changed
conduit validatewarns about aproxykey that is not a path (issue #706):proxy: { targets: [...] }is one route namedtargets, which no request path can match, so every request got the site’s fallback (a 404) and nothing said so. The warning names the key and the two forms that send every request to one upstream (proxy: "http://host:port",proxy: { "/": [...] }); an empty key is the catch-all and is not warned about.examples/file-upload,examples/middleware-demo(YAML and JSON) and a recipe indocs/recipes.mdwere written in that shape and now use a form that works;scripts/check_doc_configs.pyfails a documentation block that gets this warning.conduit validatewarns about a mistyped key outside a site (issue #681): underglobal(global.workerz), underglobal.admin(global.admin.tokn, which would leave the Admin API without a token) and at the top of a full configuration (globl). Until now only keys inside a site were reported and the rest were dropped silently, with the default in force. The value is still ignored; it is a warning, not an error. This also reports a leftoverglobal.providers(removed in 2.1.0, issue #582).conduit validatewarns thatphasehas no effect on awasmmiddleware entry (issue #660): the plugin’son_requestalways runs in the request phase and itson_responsein the response phase.conduit validatereports a mistyped key in any nested object (issue #682), such assites[0].cors.orignsorsites[0].securityHeaders.frameOptions, by comparing the document with what was read. Until now such a key was dropped without a word and the default stayed in force (onlyrateLimitrefused unknown keys). It is a warning, and the top-levelversionand$schemaare known keys.- Environment variables in a YAML file arrive unchanged (issue #680).
$VARwas replaced by its value written as a JSON string, which is right inside"..."and wrong anywhere else: a backslash or a quote in a password came out doubled or escaped in an unquoted or'...'value, and ` #or: ` in a value truncated or broke it. The value is now written for the place where the reference stands (seedocs/configuration.md); a value that cannot be written there without changing it is a load error that names the variable. This can turn a value that was silently corrupted into an error, and a reference inside a YAML comment is no longer replaced. JSON files are unchanged.
Fixed
-
HTTP/2 requests were rejected with
400 Bad Request: host not allowedby every browser (Chromium negotiates h2 whenever ALPN offers it). h2 clients send nohostheader — the authority rides in the:authoritypseudo-header — so thehost-header lookup saw an empty value and, withallowedHostsor a sitehost:configured (secure by default in this release), rejected the request. The host is now read with a fallback touri.authority(), which also restores host-based site routing, cache keys andX-Forwarded-Hostfor h2 requests. (The upstreamHostof an HTTP/1.1 upstream was already set from the authority by Pingora.) - Six examples and the README used option names that were silently ignored, found by the new key check: the
security-hardened,tls-h2,multi-siteandapi-gatewayexamples sethsts,contentSecurityPolicyandframeOptions(the options arehstsMaxAgeSecs,hstsIncludeSubDomains,hstsPreload,csp,xFrameOptions),cors.headersisallowedHeaders,hotReload.watchdoes not exist, and the README’s load-balancing example putmaxConnectionsPerUpstreamnext tohealthCheckinstead of inside it, so its circuit breaker was off. conduit fmtno longer writes secrets from the environment (issue #679). It wrote the configuration with each$VARreplaced by its value, into the file with--write. It now refuses a file that refers to a variable that is set, naming the variable and not the value.- A diagnostic re-parse no longer expands a
$NAMEinside an environment value (issue #586), and the rejected value of an enum field is not echoed in the error message. - A health probe reads at most 8 KiB of the status line (a hostile upstream could stream bytes for the whole
timeoutMs). - The upload server’s 5 GiB request ceiling can be raised (issue #700). A fixed router-wide limit of 5 GiB, not
documented anywhere, capped every request before the site’s own limits were consulted, so
maxFileSizeBytes: 53687091200still got a413at 5 GiB. The bound is now worked out per request from the site’s config: the larger of 5 GiB andmaxFileSizeByteswhenmaxTotalSizeBytesis not set (a site with no limits at all keeps the 5 GiB safety net),maxTotalSizeByteswhen it is. It is enforced on the whole body as it arrives (every field, chunked bodies included), and fromContent-Lengthbefore the body is read. See the Upload section ofdocs/configuration.md. - The tier column of
docs/building.mdand the RISC-V line of the npm Readme were out of date:x86_64-unknown-linux-muslandx86_64-apple-darwinare Tier 2 andaarch64-pc-windows-msvcis Tier 1 on the Rust platform support page; the npm Readme said RISC-V had the standard build only, since 2.2.1 it has all four. --features upload(sofull) compiles on 32-bit targets (issue #696): the 5 GiB constant was ausizeand overflowed there. The bound is au64now.- An upload request that is refused keeps none of its files: a request that failed after it had saved a file (a
later file over its limit, a body over its bound, a multipart error, or a client that went away) used to leave the
completed files on disk although the status said nothing was kept. They are removed now. A saved file’s extension
is kept only when it is ASCII letters and digits (16 at most), so a name like
x.a:bcannot make an NTFS alternate data stream on Windows. The removal runs on the blocking pool, not on an async worker, because a large file can take long to unlink (issue #702); for a request cancelled while the server is shutting down it may not run, as when the process is killed.
Internal
- The SonarCloud job checks for
SONAR_TOKENand skips the coverage run and the scan, with an annotation, when there is none (a pull request from a fork or by Dependabot gets no secrets); it used to fail there with “Not authorized” (issue #710). A green job with skipped steps means that no analysis ran. ConfigFile::Fullof the (internal, decision #32) cratelopatnov-conduit-confignow holds aBox<AppConfig>:AppConfiggrew the maps of unknown keys and the enum became large (clippylarge_enum_variant). Code that buildsConfigFile::Full(app)by hand needsBox::new(app);normalize()and the parse functions are unchanged.
Tests
- Real HTTP/2 and HTTP/1.1 requests against a running Conduit (
tests/h2_authority.rs: the request host, ahostthat disagrees with:authority, ambiguous HTTP/1.1 hosts, a spoofedX-Forwarded-Host,CONNECT) and a Docker end-to-end harness,scripts/e2e/(an isolated network with go-httpbin as the upstream and curl and nghttp as the clients), whose first scenario is the HTTP/2 request host (issue #704). - The integration-test harness keeps the spawned server’s stderr and prints its tail when a test cannot start the server or its redirect listener, and retries once, on the same ports, when the server could not bind them (issue #677: a listener that failed to bind under load was invisible).
- A guard (
every_path_like_field_of_the_schema_is_refused_or_known_to_be_a_url_path, issue #587) walks the JSON schema and fails when a field named like a path (file, dir, cert, key, ca, storage, …) is neither refused in aConduitSitenor listed as a URL path.
[2.2.1] — 2026-11-08
2.2.0 was released without its Docker images, and the Debian package gets its final name. No code of the proxy changed.
Fixed
- The arm64 Docker images are published (PR #672). In the 2.2.0 release run the four
arm64image jobs failed at the Trivy scan (no child with platform linux/amd64 in index: Trivy looked for an amd64 image in an arm64 index), so no multi-architecture manifest and none of the2.2.0image tags were pushed. Each job now scans its own platform. Until 2.2.1 there are no Docker tags for the 2.2 line; use 2.2.1 or later.
Changed
- The Debian package is called
conduit, notconduit-proxy:conduit_<version>_amd64.deband_arm64.deb. There is no other package of that name in Debian or Ubuntu. It replacesconduit-proxy2.2.0 (ReplacesandConflicts):sudo apt install ./conduit_2.2.1_amd64.debremoves the old package and keeps your/etc/conduit/conduit.yaml; a running service is stopped by the old package, so start it again afterwards. - RISC-V 64 has every build (
riscv64gc-unknown-linux-gnu): full under the plain name, plus-standard,-gatewayand-static, as on the other platforms. Until now only-standardwas published. The full build is cross-compiled in CI. -
Fewer files in a release. Every build is still published as an archive (
.tar.gz,.exe.zip), but the bare binary is attached for the full build only: it is what the npm package downloads and the.debis made of. The archives are about 2.5 times smaller. Build-provenance attestations now cover every archive as well (before, the archives were covered by the checksums only), sogh attestation verifyworks on any file of a release. - The systemd unit creates its log and cache directories itself (
LogsDirectory=conduitandCacheDirectory=conduitinstead ofReadWritePaths=). WithReadWritePaths=a missing directory stopped the service from starting (status 226); now every start recreates/var/log/conduitand/var/cache/conduit. Applies to the.deband to the unit incontrib/conduit.serviceand the deployment guide.
Fixed (tooling)
scripts/bump-version.pyalso updatesREADME.md, and leaves a historical “Since 2.2.0 …” sentence alone.
[2.2.0] — 2026-11-07
Added
tls.acme.profileand a renewal threshold that follows the certificate’s lifetime (issue #594). Renewal starts when no more than a third of the lifetime is left, never later than 30 days before expiry: unchanged for 90-day certificates, 21 days for 64-day ones (Let’s Encrypt from 2027-02-10), 15 for 45-day ones, and a 6-day certificate is no longer due on every check.profileis sent with the order. Not done: ARI (RFC 9773) renewal windows, whichinstant-acmesupports and which stays open on #594.
Fixed
- ACME follow-ups of #548 (issue #555): a reload that changes
tls.acme.email/directory/storage/challenge, or adds or removestls.acmeon a site, is now refused as a cold change (it silently kept the old values). Pointingdirectoryat another CA no longer tries the first CA’s account there: the account file records its directory and a second file is used for another one. A PKCS#1, SEC1 or encrypted private key in the storage directory is named in the log before it is replaced (only PKCS#8 is read). Still open: swapping a renewed certificate into the running listener (#451).
Security
- Windows: a symlink or junction swapped in after the check is no longer followed (issue #600,
CWE-59/367). Static files are now opened component by component with
NtCreateFilerelative to the directory above (FILE_OPEN_REPARSE_POINT), asopenat+O_NOFOLLOWalready did on Unix, so a directory junction (which needs no privilege) or a symlink at any level below the root is refused. The access-log file refuses a symlink, junction or other reparse point at its path the same way. For static files, a reparse point that is not a link (OneDrive placeholder, deduplicated file) is reopened normally after an identity check; that path has not been run against a real placeholder, and the file is refused if the open fails (a500) or the identity differs (not found). The Windows open uses the safe wrappersfs_atandsame-file, so the workspace has no first-partyunsafe(issue #621); a parent directory that turns into a link while a child is opened is refused too. - Windows: an NTFS 8.3 short name no longer reaches a file the
dotFilespolicy hides (issue #617)./HTPASS~1opened.htpasswd; a name shaped like a generated short name (BASE~N[.EXT]) is now answered as not found on Windows, in any path segment and as an index name. A real file named like that is not served there either. - Dependencies: the advisories in the shipped lock are fixed (OSV on
Cargo.lock: 16 packages with 63 advisories before, 5 packages with 5 after; the five left are four “unmaintained” notices andcrypto-bigint0.5.5, which only thep2560.13 dev-dependency of the tests pulls). Pingora 0.9.0 -> 0.9.1 (also fixes a panic on every accepted connection with tokio 1.54 and later, and requires the fixedzstd), wasmtime 49.0.2 -> 49.0.5 (19 advisories, among them RUSTSEC-2026-0379/0378, fixed in 49.0.4, and 0422-0424, which 49.0.4 and 50.0.0 still have), rustls 0.23.45 -> 0.23.46 (8), tokio 1.53.2 -> 1.54.1 (RUSTSEC-2026-0386),zstd0.14.3 withzstd-safe8.2 andzstd-sys2.1.2 (RUSTSEC-2026-0391, 0395-0406, 0410),aws-lc-rs1.18.2 (aws-lc-sys0.46),rustls-webpki0.103.16,webpki-root-certs1.0.11,ctutils0.4.8, and patch bumps of libc, sha2, serde_json, schemars and wat. wasmtime is now built without its default features exceptgc,gc-drcandthreads, which decide which plugin modules load (the plugin crate usesEngine,Module,Store,LinkerandConfigonly): the compile cache, component model, async, profiling, debugging, parallel compilation and.wattext input are not compiled in, and thewasmbuild has 118 unique crates instead of 184 (cargo tree -p lopatnov-conduit-plugin-wasm -e normal), withoutzstd0.13. A plugin file must be a binary module (documented indocs/wasm.md). Worth knowing when upgrading:rustls-webpki0.103.16 refuses certificate chains that go through eight distrusted intermediates (the emSign CAs; RUSTSEC-2026-0382,webpki-root-certs1.0.11 is RUSTSEC-2026-0383), so an HTTPS upstream behind one of them now fails the handshake.
Added
least-bandwidthload-balancing strategy (issue #627). Sends each request to the upstream moving the least traffic. Of two upstreams sampled at random it picks the lower ofsqrt((bytes per second + 1) * (requests in flight + 1)) / weight: request plus response body bytes, smoothed over about ten seconds, times the in-flight count thatp2candleast-connalso use. The first version, bytes per second alone over a full scan, was measured with the new harness (scripts/lb_compare.py, issue #629) and swung one upstream’s share by 26 points a second and could not see a slow upstream; with the in-flight factor and the sampling the swing is 1.4 and the slow upstream gets 12% instead of 25%, and weights 3:1:1 give 58/21/21. Only routes that use it are metered (one atomic add per body chunk). The JSON schema’s strategy lists also gainp2c, which a valid config could use but the schema rejected.
Changed
- Release names (issue #665): the full build has the plain name,
standardgets a suffix, andgatewayandstaticare published too. Releases now carry up to four builds of a platform (RISC-V: standard only):conduit-<target>is full (it was the standard build up to 2.1.x, where full ended in-full),conduit-<target>-standardis the standard build,-gatewayis the gateway bundle and-staticthe static-server bundle, both built with--no-default-features(RISC-V stays standard only). The Docker images follow the same rule::latest,:X.Y.Zand:X.Yare the full image (up to 2.1.x the standard one), and:latest-standard,:latest-gateway,:latest-static(with:X.Y.Z-…and:X.Y-…) are the others; every image is scanned with Trivy. A script that downloads the plain name or pulls:latestnow gets the full build (about 39 MiB against 22 MiB for standard): pin-standard/:X.Y.Z-standardto keep the old one. The npm package is unchanged for users (it installs the full build) and now vendors only the full binaries. Releases up to 2.1.x keep their old names.scripts/test_release_matrix.pychecks that the workflow, the npm tables and the Docker matrix agree. - New platforms: Linux ARM64 musl and Docker images for
linux/arm64. The release now also buildsaarch64-unknown-linux-musl(all four bundles). On Linux the npm package now picks the static musl build on a musl libc (Alpine,node:alpineimages), where the glibc build does not start; one table innpm/bin/platform.jsserves the launcher and the downloader. Every Docker image is built forlinux/amd64andlinux/arm64, each on a runner of its own architecture (no emulation) and scanned with Trivy, then joined into one multi-architecture tag;contrib/Dockerfilebuilds for the architecture it runs on. Continuous integration now tests on a native arm64 Linux runner, shows on every pull request whether Windows ARM64 builds and passes the tests (it is not released yet), and tests inside Debian 13 and Debian 12 containers (and Debian 13 on arm64), builds the Docker image on both architectures on every pull request, and cross-builds the musl ARM64 target. Android (aarch64-linux-android) is not built:pingora-core0.9.1 does not compile for it (server/daemon.rs, issue #668). - A
.debpackage (issue #669). Each release hasconduit-proxy_<version>_amd64.deband_arm64.deb: the full build as a static musl binary (so it installs on Debian 12 and 13 and on any Ubuntu, with onlyadduseras a dependency), the systemd unit, a sample/etc/conduit/conduit.yamlkept on upgrade and remove, and theconduitservice account. The service is installed but neither enabled nor started;docs/deployment.mdsays how to start it. The package is built byscripts/build-deb.shin the releasebuildjob (attested and checksummed like the binaries) and installed, run, removed and purged in cleandebian:12anddebian:13containers on amd64 and arm64 on every pull request (scripts/test-deb.sh, with lintian).contrib/conduit.servicenow points atconduit.yaml, the file the documentation tells you to install (it saidconduit.json). -
Load balancing:
least-connandp2creadweight(issue #506).least-connnow picks the upstream with the fewest active connections per unit of weight (as nginxleast_conndoes), so a weight-3 upstream carries three times the in-flight requests of a weight-1 one;p2cdivides its cost by the weight (see the next entry). With every weight 1, which is every config withoutweight, nothing changes, with one exception: a target withweight: 0(the schema asks for 1 or more, but nothing rejected 0) was treated like any other by these two strategies and now receives nothing while another target has weight, as withweighted-round-robin.conduit upstreams weightandPOST /upstreams/weightnow apply to these two as well. Thedocs/configuration.mdtext forp2csaid it compares connection counts; it compares latency, and now says so. -
p2ccounts requests in flight (issue #628). Its cost was the EWMA latency alone, so with two upstreams of different speed the faster one got every request however busy it was (100 held-open requests, one upstream twice as slow: 100 to 0). The cost is nowlatency × (in-flight + 1) ÷ weight, Tower’sPeakEwmaload, as linkerd’s P2C balancer uses; the same case ends at 67 to 33, and at equal latency, with two upstreams, a weight-3 upstream carries about three times the in-flight requests of a weight-1 one (with three upstreams and weights 3:1:1 the harness measured 47/26/27 of the requests). A behaviour change for everyp2croute. The request is now counted in flight (active_connectionsinGET /upstreams) and released when it is logged, likeleast-conn. - The CI performance report tells noise from a change (issues #475, #629). One 10-second run on a
shared runner scatters by 6–9% (24 runs of one binary, measured), so the old single-run “−6%” was not a
finding. Each build is now run four times, alternating head and base, at one worker thread (the
default) and at four; the Δ column says within noise or beyond noise (2.5 times the standard error
of the difference) and only an adverse difference beyond the noise is flagged. The report also
measures four-upstream load balancing for
round-robin,least-conn,p2candleast-bandwidth, once with one worker thread and, in addition, once with four (single runs, flagged only above 25%). Seedocs/benchmarks.md.
Fixed
- The Rhai guide’s API tables are checked against the engines (issue #566). A test lists the functions and
properties the request and the response engine register (Rhai’s own signature list) and compares them with the
marked tables of
docs/rhai.md, in both directions, so a function added, renamed or removed without the guide fails it; the check foundresponse.status(readable in a response-phase script) missing from the guide. The language reference keeps all its examples and gains a short list of what is specific to Conduit (only a booleanfalsestops the request, absent values are"",configis()without a config and reading a field of it is an error that lets the request through, which a new test shows). - A WASM plugin may use the host functions of both phases (issue #565). Each phase linked a module against
only its own functions, so a plugin that read a header in
on_requestand the upstream status inon_responsedid not instantiate in either phase and was skipped, fail-open, on every request and every response (measured with the real binary:unknown import: conduit::conduit_get_response_status has not been defined). A function that belongs to the other phase now links and traps only if it is called there. A plugin withouton_responseis also skipped before an instance is built for the response, where it used to log a link warning for every response if it imported a request function. conduit validatereports a WASM plugin that cannot run (issue #565): a file that is missing or not a binary module, noon_requestof type() -> i32, an import that does not exist or has the wrong type (a misspelt host function, a WASI import), a shared memory or any memory declared over the 16 MiB limit, a file that is not a regular file or is over 64 MiB (a plugin file is now read with that cap, in validation and at run time), and, as warnings that say the plugin still runs, a module that calls memory-reading host functions but exports nomemory, anon_responseof the wrong type and a missingon_requestnext to a workingon_response. A module that compiles but cannot be run (the cases above that fail to link or instantiate) no longer replaces the version that last worked after a reload; before, only a file that did not read or compile fell back. At run time an unusable plugin is skipped and the request passes through; the server logs the same text as a warning at start-up and on reload,conduit validateexits non-zero.-
docs/wasm.mdrewritten, and its samples are built in CI (issue #565). The Rust sample at the top of the old guide did not link (the host functions were declared without#[link(wasm_import_module = "conduit")], so they were looked up inenv), and neither would the C one. The guide now starts with the install that has WASM, fail-open and a table of limits, walks through a first plugin end to end, and every Rust plugin in it is built forwasm32-unknown-unknownand validated (scripts/check_doc_wasm.py), then run behind a real Conduit (scripts/repro-wasm-guide.sh) in thedocs-configsjob. - A configuration reload picks up an edited Rhai script or WASM plugin (issue #566). Compiled scripts and
modules are cached by path, and nothing ever emptied the cache, so a file edited at an unchanged path took
effect only after a restart, although the Rhai guide said
conduit reloadwas enough (the WASM guide said it was not). A reload (conduit reload,POST /reload, a live update from the Kubernetes provider) now empties both caches, and a file that then cannot be read or compiled (a typo, a save that stopped half-way) does not switch a guard off: the last version that compiled stays in use and one warning is logged per reload. Measured with the real binary: a script edited from “block with 403” to “allow” and reloaded still answered 403 before, and answers from the new file now; edited into a syntax error and reloaded it keeps answering 403 from its last good version. conduit validatereports a Rhai script that cannot be read or compiled (issue #566). Such an entry is skipped at run time and the request passes through (fail-open), so a mistake in a guard script was visible only as a log line on the first request;validateaccepted a missing file and a syntax error alike. It now printsscript "..." does not compile: ... (line N, position M)or... cannot be read (entity not found)and exits non-zero; the server logs it as a warning at start-up and on reload and carries on, as before. The documented configurations are checked against stub script files byscripts/check_doc_configs.py, and every ```rhai block ofdocs/rhai.mdis compiled by a test.- An upstream removed by
outlierDetectioncomes back (issue #650). After an ejection expired, the health query that builds the candidate list promoted the upstream to “half-open” and offered it as the probe; when the strategy picked another upstream no request was sent, nothing resolved the probe, and the upstream stayed out for as long as Conduit ran (measured: 0 of 6 trials, two upstreams, ejection 2 s, the upstream healthy again for six seconds and more). A promotion that gets no answer now lapses after 10 seconds and the upstream is offered again (measured: back after about 10 seconds in 4 of 4 trials). conduit reload,status,shutdownandupstreamsnow authenticate and now fail when the server says no (issues #568, #567). The docs promised that the CLI sendsCONDUIT_ADMIN_TOKEN, but the CLI never read it, so withglobal.admin.tokenset every admin command (including thesystemctl reloadof the shipped unit) got a401; and the CLI ignored the reply’s status, printed the error body and exited 0, also for a reload the server rejected (a restart-only field changed). It now sendsAuthorization: Bearer $CONDUIT_ADMIN_TOKENwhen the variable is set and not empty (a token that is not valid Unicode or has a line break is refused) and exits 1, printing the server’s message, for any reply that is not2xx. The help texts ofupstreams addandupstreams weightno longer say that only weighted-round-robin reads weights.- Documentation examples are now checked (issue #567):
scripts/check_doc_configs.pyrunsconduit validateon every config block of the README anddocs/and on every file ofexamples/in CI (jobdocs-configs). First run: eightglobal:-only examples did not validate (globalis read only next tosites:), andexamples/spa-with-api.jsonasked for ACME without ahost; both fixed.docs/cli.mdis checked against--help(flags that only the server accepts, what a rejected reload does, exit codes), and counts that rot are replaced by names (issue #568, partly: the split ofdocs/configuration.md, the glossary and the FAQ remain). - A route with
groupsand a load-awaregroupStrategyno longer leaves a counter on every group name (found by the review of PR #631). The outer pick runs the strategy over the group names and threw away the in-flight slot thatleast-conntakes (and, since this release,p2candleast-bandwidth), so the counter of each group name grew by one per request and nothing released it. The slot is handed back at once; the real one is taken by the inner pick. The load-aware strategies still compare the names’ own counters (all 0), that is, they choose among groups at random: #632 is about choosing by the group’s real load. - WASM: an engine that cannot be built no longer makes every plugin fail open (issue #626). A failed
Engine::newused to fall back to a default engine without fuel, on which every call failed and every request passed through, so a plugin that was supposed to reject requests (authentication, say) rejected none. The engine is now built once when awasmmiddleware is validated, and a config (or hot reload) that cannot get one is refused. A module that fails to load is still fail-open, as documented. least-connno longer sends every request of a lightly loaded pool to its first target (issue #506). When several upstreams had the same number of active connections, which is all of them whenever requests are short enough that none is still in flight when the next arrives, the first one in the list always won. The tie is now broken at random, in proportion toweight.p2cdraws its two samples from a per-thread generator instead of one seeded by the clock, which gave the same pair to every request inside one clock tick (100 ns on Windows).- Static files: a refused or failed open no longer cuts a
200off after its headers (issue #618). The file is opened once before any header is written, and its size,ETagandLast-Modifiedcome from that handle, so a link swapped in after the lookup cannot leak the size or modification time of a file outside the root. A miss is answered as not found, an unreadable file as403, another failure as500, all before the headers. A304and aHEADrequest now open the file too. - Static files: a
Rangethat runs past the end of the file is answered, not rejected. A last byte at or past the end now means “to the end”, and a suffix longer than the file selects all of it (206, RFC 9110 §14.1.2); both were a416. A first byte at or past the end is still a416. Found while documentingparse_rangefor this PR.
[2.1.0] — 2026-10-11
2.1.0 builds on 2.0.0 with security hardening, config-correctness fixes and one
new command (conduit features). No config shape or CLI flag is removed except
the unimplemented global.providers field. Two changes need attention when
upgrading: ip-hash, consistent-hash and the no-secret sticky mode now use
rendezvous hashing, so every client moves to a different upstream once; and JWT
verification now rejects RSA keys outside 2048-8192 bits (it fails closed).
The main changes are security hardening (the npm postinstall now verifies the
binary it downloads, the HTTP-to-HTTPS redirect refuses a malformed Host, a
ConduitSite can no longer name host files, ACME certificates are renewed
while the process runs) and config correctness (tls.acme needs a host,
upstreamTls.serverName takes effect, config type errors name the field). The
maintainer release guide is docs/releasing.md.
Security
- The HTTP-to-HTTPS redirect server refuses a
Hostthat is not a valid host name or address (issue #556) instead of reflecting it intoLocation. - The npm postinstall verifies the downloaded binary against SHA-256 values baked into the package (issue #571) and fails closed.
- A
ConduitSiteresource can no longer set host file paths (static,upload,middleware, TLS files,tls.acme.storage,logging.file,fallback.file) (issue #580). - Two kid-less keys in a JWKS are no longer collapsed into one (issue #351). The second used to replace the first under the same synthesized id, so a kid-less token was checked against whichever key survived instead of being rejected as ambiguous.
- A directory symlink inside a static path is no longer followed (issue #400, CWE-59). Only the
last path component was checked, so
assets/secret.txtwithassets -> /etcread outside the static root. Every directory between the root and the file is now checked. - The
Hostheader must carry a numeric port, or none (issue #474).allowed.example:80@evil.comused to passallowedHostsand site routing asallowed.examplewhile the value echoed intoX-Forwarded-Hostnamed another host; it now matches nothing. POST /certs/reloadkeeps the key file’s mode (issue #481). Rotating a0600key no longer leaves a world-readable one, and the temporary file is created exclusively under an unpredictable name instead of following a planted<path>.tmpsymlink.- A
tls.acmesite’shostcan no longer name a file outside the storage directory (issue #554, CWE-22). The certificate and key are stored as<host>.crt.pemand<host>.key.pem, and a host such as../../etc/xmade the ACME flow write a private key (and read a cached pair) outsidetls.acme.storage, which matters where less-trusted people can write sites (KubernetesConduitSiteobjects). Validation now rejects atls.acmehost that is not a plain DNS name (letters, digits and-in dot-separated labels, optionally a leading*.), and the flow re-checks the name and that the path stays directly inside the storage directory before touching the disk or the CA. Behaviour change: a host with_, a port suffix, a trailing dot or non-ASCII characters used to fail later with an error log and fall back to plain HTTP; withtls.acmeset it is now a validation error. A private CA (acme.directory) with such internal names needs a plain DNS name for the site. The directory itself (tls.acme.storage) is not constrained yet (issue #580); Windows device names such ascon.example.comare refused too (issue #579). - The HTTP-to-HTTPS redirect answers
421 Misdirected Requestfor aHostthat no site on that listener serves, instead of reflecting it intoLocation(#556, #588). - The static file handler opens files with
openat+O_NOFOLLOWone component at a time, so a directory swapped for a symlink after the check can no longer be followed (Unix; #557).
Added
conduit features(issue #473) prints the Cargo features a configuration needs, a ready-to-pastecargo installline and the smallest bundle that covers it (--jsonfor scripts). It exits with1when the running binary lacks one of them, so it doubles as a deploy-time check.
Changed
-
ip-hash,consistent-hashand the no-secret sticky mode are now actually consistent (issue #377). The upstream was picked withhash % healthy-count, so one upstream going unhealthy (or coming back) moved almost every client. They now use rendezvous hashing: only the clients that were on the affected upstream move. On upgrade every client lands on a different upstream once, then stays stable; expect a one-time cold start of any per-upstream cache or session state. Capacity limits (maxConnectionsPerUpstream) spill a key to its next-best upstream instead of the next list entry. -
JWT verification now uses the
aws-lc-rscrypto backend instead of the pure-Rustrsastack. This removes thersacrate (CVE-2023-49092, “Marvin”, no upstream fix) fromCargo.lock; Conduit only ever verified signatures with public keys, so it was not exploitable. The supported algorithms are unchanged (HS256 forsecret; RS256/384/512 and ES256/384 forjwksUrl). RSA keys must be 2048 to 8192 bits: theaws-lc-rsverifier rejects a JWKS or PEM key outside that range (fails closed) instead of verifying with it.
Fixed
tls.acmenow needs ahostand only acceptschallenge: http-01(issues #577, #578). A site withtls.acmeand no host used to start and serve plain HTTP on its TLS port;conduit init --tls-acmenow takes--host. DNS-01 was documented but never implemented. On Windows, hosts whose first label is a device name (con,nul, …) are refused, and renewal de-duplication ignores case (issue #579).upstreamTls.serverNametakes effect (issue #583): it is sent as SNI and used to verify the upstream certificate.- Config type errors name the field (issue #570), and a full config (
sites: [...]) with an invalid site no longer loads silently as one empty site.$schemais no longer reported as an unknown key (issue #569). The do-nothingglobal.providersfield is removed (issue #582). - WASM
on_responsebody replacement also skips205responses (issue #561). - The npm package’s “install from source” hint named the wrong crate. Its error messages said
cargo install conduit-proxy; they now saycargo install lopatnov-conduit. - Docs: wrong config snippets and defaults. A top-level
http2: truedoes not parse (the setting is an object,http2: {}enables it) and appeared in the README, the npm README and three recipes; two recipes settls.versions, whichconduit validaterejects; a missing closing fence indocs/cli.mdmade every section after “fault-injection” render with code and prose swapped; the config reference saidglobal.workersdefaults to the CPU count when it defaults to one thread;hotReloadwas documented as watching the config file when it only watches the servedstaticdirectories and reloads browsers (config changes needconduit reload); theconduit validateexample showed an error format the command does not print; the Linux release archive was said to unpack to./conduit(it unpacks to a file named like the archive). The README and the npm README were rewritten to match the code (the README has its table of contents back, eleven SVG diagrams that work in light and dark themes, a configuration example for each feature, KubernetesConduitSitemode included), theserverTimingoption is now documented, and the benchmark page now gives the exact setup the CI performance report uses; the old per-feature throughput tables, the nginx/Traefik comparison and the build-size table were removed: they were one-off measurements, some could not be reproduced (issues #475, #487). global.shutdownTimeoutSecsnow takes effect (issue #489). It is passed to Pingora’s grace period (default 30 s; Pingora used to wait its own 300 s, so operators with long-lived streams (uploads, SSE, WebSocket) should raise it). On SIGTERM Pingora waits the whole period and does not end early when connections drain;POST /shutdownstill exits at zero in-flight. Changing the value now needs a restart (cold field).global.backlogis reported as ignored (issue #490). Pingora fixes the listen backlog at 65535; validation warns, and a change no longer counts as a cold-restart field.conduit manon a terminal prints a hint instead of raw roff, and the description no longer uses non-ASCII bullets. Piped or redirected output is unchanged.- A
routes[]entry honours the same route options as aproxymap route (issue #412). It used to resolve through its own, smaller resolver, sogroups(the route did not work at all),hashKey,sticky,backup,rewrite,mirrorandupstreamTlswere accepted and silently ignored. Both mechanisms now share one resolver. Two behaviour changes follow:ipHash/consistentHashonroutes[]hash thehashKey(default: client IP) instead of the request path, andstripPrefixremoves the literal prefix ofmatch.pathinstead of the whole request path. hashKey: "header:<Name>"hashes that header (issue #412). It was documented but treated as the client IP everywhere; a request without the header still falls back to the client IP.- Active health checks run for
routes[]entries andgroups(issue #376).healthChecksettings (intervalSecs,path, thresholds) were only acted on for theproxymap with flattargets; elsewhere only passive health applied. The/__health__?full=1upstream list now includes a group route’s targets too. - A live config update that changes a cold field is rejected (issue #494), as
POST /reloadalready did. A Kubernetes CRD edit to a port or TLS cert path used to be swapped into the config while the listeners kept the old ones. Cold fields are now compared per listener port, not per site position, so adding, removing or reordering sites on an already-bound port stays hot (also for/reload). - A hot reload that changes the Redis rate-limit store now warns that a restart is needed (issue #358).
The connection is made once at startup; the edit was silently ignored. The warning is in the log and in
the
warningsof the/reloadresponse. - The Redis proxy cache connects at most 16 distinct store URLs per process (issue #349). Pingora’s
Storageneeds&'static self, so each connected store is kept for the process lifetime; URL churn across reloads (e.g. a rotated ConfigMap) used to grow without bound. A reload past the cap logs an error and needs a restart. - The proxy cache key includes the site’s listener port (issue #482). Two sites that share a
hostand differ inportused to share cache entries, so one site could serve the other’s cached response.DELETE /cache/purgenow purges the listener named by the URL’s port, or every served listener port when the URL has none. Persistent caches (disk/redis) start cold once after the upgrade. - ACME certificates are renewed while the process runs (issue #491).
spawn_renewal_taskhad no caller, so a certificate was obtained at startup and never renewed. One background loop now checks every 12 h, answers the HTTP-01 challenge through the listener that already owns the port (a bind would fail withEADDRINUSE), and stops on shutdown. The renewed files take effect at the next restart. Certificate, key and account credentials are each written atomically (staged,fsynced, renamed); a cached certificate is reused only when its key matches it; and if renewal fails while the cached certificate is still valid the site keeps serving it instead of falling back to plain HTTP. Renewed files are always owner-only (0600). Rangerequests honourIf-Range(issue #402, RFC 9110 §13.1.5): a stale validator now gets200with the whole file instead of a206splice of two versions.- A route with
groupsno longer gets a false “slowStartSecs is ignored on this route” warning from a leftoverstrategy/stickyit never reads (issue #483). - The log targets in
docs/rhai.md,docs/wasm.mdanddocs/cli.mdmatch the crates that emit them (issue #476). - The Admin API and the metrics endpoint accept
bearer/BEARERas well asBearer(issue #484, RFC 9110 §11.1); the token itself is still compared exactly and in constant time. - WASM
on_responsecan replace the response body (issue #379). A plugin that calledconduit_set_response_bodythere used to leave the upstream body untouched and leak the replacement to the client as two internalx-conduit-wasm-body-*headers (one carrying the whole body in base64). The headers are gone and the client now gets the replacement, withContent-Lengthset and the upstreamContent-Encoding,Transfer-Encoding,ETagandContent-MD5dropped. The last plugin that sets a body wins. A response that cannot carry a body (1xx,204,304,Content-Length: 0) is left as the upstream sent it, with one warning logged. docs/wasm.mdstates whatconduit_get_header_names/_countreally return: distinct names, no guaranteed order, one value per repeated header (issue #380).- Failing over to a route’s
backupupstream keeps the route’s own settings (issue #417): timeouts, pool, HTTP/2, cache, WebSocket permission, passive-health thresholds, strip/rewrite/mirror/upstream TLS. Awebsocket: trueroute no longer answers 502 to upgrades after it fails over. - The Kubernetes provider rebuilds the config once per resync instead of on every
Init/InitApplyevent (issue #408), which cut M+2 list-and-rebuild cycles to one at start-up and watch recovery. - ACME certificate and key files are named from the lower-cased host, so
EXAMPLE.comandexample.comshare one pair on every file system. On case-sensitive file systems a mixed-case host orders its certificate once more after the upgrade (#579). - A WASM
on_responsebody replacement decides on the upstreamContent-Lengthas received, so aresponseTransformthat removes the header no longer makes the guard miss an empty body (#561).
Documentation
- New maintainer guide
docs/releasing.md.
[2.0.0] — 2026-10-03
Conduit 2.0 splits the single lopatnov-conduit crate into a Cargo workspace
of one crate per feature (issue #114), so a build only compiles the code and
dependencies a chosen feature set actually needs — no behavior, config shape,
route, or CLI flag changed by the split itself. Issue #148 wires up real
multi-crate publishing: every lopatnov-conduit-* member crate is
cargo publish --workspace-able in dependency order (native cargo, not
cargo-workspaces/release-plz), pinned at 2.0.0 in lockstep, with its own
MSRV (rust-version, 1.89 workspace-wide / 1.96 for conduit-plugin-wasm
which needs wasmtime 49+); CI proves the publish would succeed
(workspace-publish-dryrun) on every PR. The security, correctness, and
behavior fixes below landed alongside the migration and apply to 2.0.0
regardless of which feature crates a given build pulls in.
Changed
- The npm package (
@lopatnov/conduit) now installs thefullfeature-bundle binary instead ofstandard(issue #239). Redis-backed rate limiting/caching, WASM plugin middleware, Rhai scripting, OpenTelemetry OTLP tracing, and TCP proxy mode all work immediately afternpm install— no separate full-binary download needed. The download is correspondingly larger. A smaller binary is still available by building from source (cargo install lopatnov-conduit --features standard). This is npm-specific: the unsuffixed GitHub Release assets and the default:latest/:2.0.0GHCR Docker image are unchanged and still ship thestandardbundle — only the-full-suffixed release assets and:latest-fullDocker tag match what npm now installs.
Security
global.admin.token: ""is now a validation error (issue #480). The Admin API compares the bearer token in constant time, and a request with noAuthorizationheader is an empty string, so an empty configured token authenticated every request — which is what an unresolved$ADMIN_TOKENexpands to.metrics.token: ""was already rejected for the same reason; omit the field to leave the Admin API unauthenticated.- A Redis URL whose password contains a raw
/is no longer logged with the password. Credentials are redacted before a Redis URL is logged, but the search for theuser:password@part stopped at the first/, so inredis://alice:pa/ss@host:6379the@looked like part of the path and the URL was printed as it was — as wereredis://alice:/pw@hostandredis://default:1234/abc@host, and a password holding both@and/was cut in the middle. Everything before the last@is now treated as credentials, since a Redis URL’s path (/or/<db-number>) never holds an@; a malformed URL such asredis://host:6379/db@1is therefore printed asredis://***@1. (The redaction helper is now shared by every crate that prints config values.) - The vulnerable
protobuf 2.28.0(RUSTSEC-2024-0437 / CVE-2025-53605) is gone from the dependency tree. It was pulled in unconditionally bypingora-core 0.8throughprometheus 0.13; Pingora 0.9 no longer depends onprometheusfrompingora-core, so only Conduit’s ownprometheus 0.14(withprotobuf 3.7.2) remains and thecargo-auditignore for it is removed. The unmaintaineddaemonizecrate (RUSTSEC-2025-0069) is replaced bydaemonixin the same upgrade, so its OSV ignore is removed as well. - Pingora 0.9 hardening applies to every proxied request — stricter request-target and authority validation, hop-by-hop upstream header sanitisation (see Changed), and bounded default HTTP/2 server limits.
- Per-route and per-consumer rate limiting no longer bypass the shared
memory-exhaustion cap.
rateLimitat the site level has always refused to create more than 100,000 distinct token buckets, to stop an attacker sending unbounded uniquekeyBy: "header:X-Name"values from exhausting memory. Per-route and per-consumer rate limits shared the same underlying map but bypassed that cap entirely — confirmed as a real DoS vector on the documented usage pattern. All three layers (plus the Redis fallback path) now share one capacity-checked admission point. - Per-route
rateLimitis now validated at config-load time. PreviouslywindowSecs/limit/algorithm/keyBy/storeon a per-route rate limit were parsed but never checked — a malformedkeyBy: "header:bad name"silently collapsed every client into one shared bucket at runtime instead of failing validation up front. Site-level and per-consumer rate limits already validated these fields; per-route now does too, matching them. - CORS
credentials: truenow requires an explicit, non-wildcardoriginsallowlist. Previously,credentials: truewithoriginsunset (or containing"*") echoed the request’sOriginheader back verbatim withAccess-Control-Allow-Credentials: truefor any origin — a real CSRF/data-exfiltration vector (CWE-942), not just a spec nicety. Config validation now rejects this combination at startup/reload. - Forward-auth no longer lets a client-forged identity header survive
when the auth service doesn’t return it.
forwardAuth.responseHeadersonly ever inserted headers the auth service’s response actually contained — a header configured but not returned by the auth service (e.g. an anonymous/guest session) left the upstream trusting whatever value the client itself sent under that name. Configured header names are now stripped from the client request before the auth-service-returned values are inserted. - Redis-backed rate limiting no longer leaks a TTL-less key on a
timeout/error between
INCRandEXPIRE. The two commands used to run as separate round-trips; a client-side timeout or connection error landing between them could leave a key at count 1 with no expiry — that key then persists forever, and once later requests push its count past the configured limit, that one client is rejected permanently instead of just for the current window (a transient blip degrading into a permanent fail-closed, contradicting the module’s own fail-open design). Both commands now run as a single atomic Lua script (EVAL), which also self-heals any key already leaked by the old two-round-trip code the next time it’s checked.
Fixed
- A config sourced from Kubernetes
ConduitSiteCRDs is now validated, both on startup and on every live update (issue #492). The file-based config path has always rejected a config with duplicatehost:portpairs, bad TLS config, etc. before starting or hot-swapping; the Kubernetes path swapped every update in unconditionally, with no validation at all — the initial config fromrun_kubernetesand every subsequent CRD-driven update from the live-update watcher. A rejected update now keeps the currently-serving config instead of applying the invalid one; a rejected initial config exits the process like the file-based path already did. - The Admin API’s rate-limit-cleanup and event-loop-lag-gauge background tasks now stop when the process
shuts down, instead of running until process exit regardless of what
BackgroundService::start()’s caller expects. Found while moving this code intocrates/conduit-server(issue #147) — not new to that move, but a real pre-existing gap. - A proxied response no longer takes a thread hand-off unless a script or WASM plugin can run on it (issue
#475). The response filter chain ran through Tokio’s
block_in_placeon every response, although it only edits headers unless the site configures response-phase script or WASMmiddleware. On a multi-thread runtimeblock_in_placegives the worker’s task queue to another thread and takes it back afterwards: about 30 µs of CPU per request (mostly kernel time), 11–12 threads alive under load whereglobal.workers: 1promises one worker, and a hand-off in every request’s latency. Measured on a 5950X under WSL2 (oha -c 50): with one worker 9.2k → 11.2k req/s (+22%) and 120 → 90 µs CPU per request (A/B, six runs per arm); with 4 workers +18%, with 8 workers +20%. A chain that contains a response-phase script or a WASM filter still runs throughblock_in_place(a request-phase script does not run on the response, so it does not count); a filter is assumed to be able to block unless it declares otherwise (ResponseFilter::may_block), so a new filter that forgets to say is slower, not unsafe. Passthrough throughput scales withglobal.workers(default: one worker thread); the throughput figures indocs/benchmarks.mdcould not be reproduced and are annotated, andscripts/bench/holds the scripts used to measure requests per second and CPU per request. - HMAC-signed sticky sessions now actually route to the upstream their
cookie names. After verifying the cookie against a specific upstream,
Conduit threw that result away and instead hashed the upstream’s URL
string back through
hash % len— which lands on the pinned upstream itself only by coincidence. Measured across 2–8-upstream pools, that coincidence holds about 23% of the time (i.e. chance); with exactly four upstreams it never holds. So a signed session was usually served by a different upstream than the one it was pinned to, silently. The pin is now honored directly whenever its upstream is healthy and undermaxConnectionsPerUpstream, with the previous relocate-and-self-heal behavior kept for when it isn’t. Two knock-on effects are fixed with it:strict: truewas checking the health of the pinned upstream while serving a different one, and the “capacity relocation” guard (which suppresses cookie re-signing) was firing on nearly every sticky request rather than only on real relocations. - A route with
retryconfigured no longer ignores its load-balancing strategy. The retry path bypassed strategy dispatch entirely and did plain round-robin, soipHash/consistentHash, weighted round-robin, least-conn and sticky affinity were all silently inert the momentretrywas added to a route. The first attempt now goes through the same strategy dispatch as a non-retry request, and the retry rotation is anchored to whichever upstream that produced. - Response compression now applies to the metrics endpoint and fallback
responses, not just static files.
compression’s negotiation logic (Content-Encodingselection,minBytes/typesthresholds) was fully implemented and tested but never actually wired into the/__metrics__handler or fallback (404/SPA-shell/custom-body) responses — both were always served uncompressed regardless of config. Each response type is still negotiated independently against the site’scompressionconfig, so a small response may stay uncompressed exactly as before. - A request to
/.well-known/acme-challenge/*on a build without--features acmeno longer surfaces as a 502. The path matched unconditionally regardless of the compiled feature; withoutacmethere was no handler to serve it, and the request fell through to Pingora’s proxy path with no real upstream to select. The path now only matches whenacmeis actually compiled in. healthCheck.slowStartSecsnow actually ramps traffic to a recently-recovered upstream. The field was parsed and the underlying fraction calculation existed, but nothing outside its own unit tests ever called it — a freshly-recovered upstream got 100% of its normal traffic share immediately, the exact thundering-herd scenario the feature exists to prevent (LeastConnwas the worst-affected strategy: a recovered peer’s drained connection count made it win every pick until real traffic caught it up). Every load-balance strategy now honors it exceptipHash/consistentHashand sticky sessions, which are deliberately exempt (a probabilistic ramp would break their own consistency guarantee) — configuring both together now logs a warning instead of silently doing nothing.- A
routes[]-array route withretryconfigured no longer defeats its own load-balancing strategy on the first attempt. The retry candidate list was built independently of the peer the route’s strategy actually chose, soretry.urls[0]was always the head of an unrotated list — round-robin never rotated, and per-peer stats (conn_count, EWMA, outlier detection, access logs) were attributed to the wrong upstream. retry.budgetPercentno longer self-suppresses over the life of a long-running process. The internalretry_inflightcounter incremented once per retry decision but was only ever decremented once per request — a request that took 2+ retry attempts (e.g.attempts: 3fully exhausted) leaked a permanent +1 into the counter. Enough leaked requests eventually make the budget check deny all retries sitewide, with no error or warning.- Retry attempts no longer leak a
conn_countslot on a connect-phase or proxy-phase-timeout failure. Only the 5xx-retry path correctly released the connection-capacity slot before moving to the next attempt; a connection refusal/timeout, or a read/write timeout mid-response, left the slot held forever. Once enough slots leaked pastmaxConnectionsPerUpstream, the affected route returned503permanently until process restart — the opposite of the circuit breaker’s intended behavior. Both failure modes now also feed passive health/outlier detection, which previously only the 5xx path did. - Retry attempts now actually respect
maxConnectionsPerUpstream. Capacity used to be evaluated once, at initial routing, and never re-checked as a request moved through its retry attempts — a retry could land on (and further overload) a peer already at its connection cap. Each retry attempt now forward-probes the retry candidate list for the next peer currently under the cap, skipping (not permanently removing) a saturated one — the same forward-probe shapeipHash/consistentHashalready use for capacity. Fails open to the naive rotation target if every candidate is saturated, so a request that has already spent attempts is never 503’d purely because capacity deteriorated mid-request. - The “
forwardAuth.urlpoints at the Admin API” validation error now catches what it was meant to (issue #447). It compared the URL’s host with"::1"while the URL library returns IPv6 hosts in brackets, sohttp://[::1]:2019was never rejected; it also hard-coded port 2019. The rule now classifies the parsed host (localhostand*.localhost, IPv4127.0.0.0/8,::1, IPv4-mapped IPv6, and0.0.0.0/[::], which connect to the local host on Linux and macOS), treats a URL without a port as its scheme’s default port, and follows the port ofglobal.admin.bind(2019 when it is not set). A config that pointedforwardAuthat such an address on the Admin API’s port used to load and now fails validation; a different service on port 2019 is no longer rejected onceglobal.admin.binduses another port, and a domain that merely starts with127.is no longer treated as loopback. - A site whose
hostis an IPv6 literal was never matched by its requests. The proxy cut theHostheader at its first:, so[::1]:8080became[; such a request fell through to the catch-all site (or found none) and all of them shared one cache namespace. TheallowedHostscheck (and the site-host fallback ofsecurityHeaders) cut it the same way, so it would have rejected such a request once it matched. Both now keep the bracketed literal whole ([::1]:8080→[::1], one shared function inconduit-core), sohost: "[::1]"matches and is allowed. DELETE /cache/purge?url=…with an explicit port purged nothing (issue #444).http://example.com:8080/xwas looked up under the cache namespaceexample.com:8080, while the request path stores an entry under theHostheader without its port (example.com), so the purge answered{"purged": false}and the stale entry survived. The cache key now drops a port from its host in one place, used by both, so they cannot disagree again; no stored key changes, so a persistent (disk/Redis) cache is not made cold. Still not covered: aHostheader with upper-case letters (the purge lower-cases the host) and entries cached withVary.forwardAuth.urlpointing at the address the Admin API is bound to is now rejected (issue #470). The validation rule that keepsforwardAuthaway from the Admin API flagged loopback and “this host” addresses on the admin port; with a non-loopbackglobal.admin.bindsuch as192.0.2.10:2019, that address itself was not flagged. It is now (an IP address written any way —2001:db8:0::1equals2001:db8::1, an IPv4-mapped form equals its IPv4 one — or a host name, compared case-insensitively). The message for a loopback URL is unchanged, and the admin port is taken from every bind form as before, an unbracketed IPv6 one such as::1:3000included.
Changed
- Pingora upgraded from 0.8.1 to 0.9.0. Two behaviour changes are visible
to operators:
- Response-cache keys hash differently. Pingora 0.9 removed the separate
namespaceargument ofCacheKey, so Conduit now joins the host and the rest of the key with an explicit\0boundary instead of relying on the old, ambiguous concatenation. A persistentcache.store(disk:/redis://) starts cold once after the upgrade. Redis entries expire on their TTL; olddisk:files are never read again and are not removed automatically — delete the cache directory to reclaim the space. Nodes that share one Redis store see disjoint keys across the upgrade: during a rolling upgrade old and new nodes cache separately (no collision, no corruption), and aDELETE /cache/purgeon one version does not remove the entry the other version wrote. - Hop-by-hop request headers are no longer forwarded to the upstream.
Pingora’s standard policy now drops
Keep-Alive,Proxy-Connection,Proxy-Authenticate,Proxy-Authorization,TE,Trailer,Transfer-Encoding(re-framed by Pingora),Connection,HTTP2-Settings, any header named in the client’sConnectionheader, andUpgradeunless the request is a valid WebSocket handshake (which is normalised and still forwarded). A request whoseConnectionheader nominatesHost,X-Forwarded-For,X-Forwarded-HostorX-Forwarded-Protois rejected. An HTTP/2 client talking to an HTTP/2 upstream (e.g. gRPC) is not rewritten.
The purge admin endpoint (
DELETE /cache/purge) keeps its response shape. Internally theStorage::purgeimplementations of the disk and Redis cache backends follow Pingora 0.9’sPurgeTarget/PurgeOutcomeAPI, and Conduit’s own header edits useremove_header/append_header(Pingora 0.9 no longer letsRequestHeader/ResponseHeaderbe mutated throughDerefMut). - Response-cache keys hash differently. Pingora 0.9 removed the separate
--no-default-featuresbuilds no longer contain any reverse-proxy code or its dependencies (issue #144).proxyis now a real Cargo feature: with it off, upstream selection (capacity limits, slow-start, sticky sessions), retry, traffic mirroring and the active health checks are compiled out, together withreqwest,url(and itsidna/icu_*tree) andhmac/sha2— 302 → 265 crates for--no-default-features --features static.default,standardandfullincludeproxyand are unchanged. Three config shapes change meaning in a build without it: a legacy top-levelproxyshorthand next to a site-levelstatic(the previously shadowedstaticroot becomes live), a legacyproxymap next tostatic(requests under the proxied prefixes fall through tostatic/fallbackinstead of an upstream), and aroutes[]entry with aproxyaction (it ends in the site’sfallback, never in its ownstatichalf). Each logs a startup warning naming the exact index. Seedocs/building.md.- The “
forwardAuth.urlpoints at the Admin API (127.0.0.1:2019)” validation error now applies only to builds that enforce forwardAuth (--features forward-auth, part ofstandard/full). Without the feature the wholeforwardAuthblock is ignored (and already warned about), so such a config loads with that warning instead of an error; the rule itself is unchanged wherever forwardAuth runs. DELETE /cache/purgeanswers501 Not Implementedin builds without thecachefeature. It used to answer{"status":"ok","purged":false}— for a cache such a build does not have.cacheis not part ofdefault, so a plaincargo buildis affected; the publishedstandard/fullbinaries and images are not.- The
cachefeature now impliesproxy(issue #144). The cache stores proxied responses only, so a cache build without its proxy was never meaningful, and its call sites (cache.earlyRefreshSecs,/cache/purge) need the HTTP client and URL parser thatproxybrings in.--features cachetherefore also compilesproxy;default,standardandfullare unaffected (they already include both). - Two bundles for
--no-default-featuresbuilds (issue #144):static-server(static+compression+hotreload— the default set minusproxy) andgateway(proxy+jwt+consumers+forward-auth+cache+acme+compression— thestandardset without static files and hot-reload). They add nothing to a default build. - The integration tests that proxy real traffic (
proxy,lb_strategies,rewrite,upstream_groups,websocket, and the proxy-dependent tests insidedynamic_upstreams,routes,security,upstream_health) now require theproxyfeature, socargo test --no-default-features --features static-serverruns cleanly. A build withproxyruns exactly the same tests as before. RateLimitConfigmoved to its own crate (conduit-ratelimit, issue #114/#137 slice 1) — no config shape or behavior change, this closes a code-duplication finding between the root crate andconduit-auth-consumers.- Static-file serving and fallback (404/SPA-shell/custom-body) responses
moved to their own crate (
conduit-static, issue #114/#139) behind a newstaticCargo feature. Default-on, likecompression— a plaincargo buildkeeps serving static files and fallback responses exactly like before; only--no-default-features(without re-addingstatic) now produces a build with neither capability compiled in. - Config validation moved into the crates that own each config block (issue
#316): the
rateLimit,limits,ipFilter,cors,middleware,redirects,fallback,upload,metrics,cache,tcp,proxy,jwtAuth,consumersandforwardAuthchecks, and every “configured but this build lacks the feature” warning text, now live in those crates. The messages, their order and the output ofconduit validateare unchanged. One operator-visible effect: the log lines emitted while validating a route (aslowStartSecsthat is ignored on a hash-based or sticky route) or a cache block are now logged under the targetsconduit_proxy_http::validateandconduit_cache::validateinstead ofconduit::config::validate::proxy. The defaultwarnlevel still shows them, but a filter such asRUST_LOG=conduit::config=debugno longer matches them. - The request pipeline moved into a new workspace crate,
lopatnov-conduit-runtime(issue #145): the PingoraProxyHttpimplementation,AppState, the per-request state, the request/response/logging phases, request routing, the guard and response chains, the access log and the health handler. No config shape change and no new dependency (the shipped crate set is unchanged); the root re-exports every item at its old path. The one behaviour change made alongside is the IPv6Hostfix listed under Fixed. One operator-visible effect: thetracinglog lines emitted by this code now carry the targetsconduit_runtime::proxy::…/conduit_runtime::filter::…instead ofconduit::proxy::…/conduit::filter::…, so a filter such asRUST_LOG=conduit::proxy=debugno longer matches them (the defaultwarnlevel is unaffected). Theotlp,tokio-metricsand the other feature names are unchanged. - The Admin API moved into a new workspace crate,
lopatnov-conduit-admin(issue #146): the axum server, the bearer-token layer and eleven of the twelve endpoints (everything exceptPOST /reload, which needs the root’s config validation and joins the router through its single extension point, merged before the authentication layer). No route, status code or JSON changed and every route still answers 401 without the token (now pinned by a test on all twelve). One operator-visible effect: thetracinglines from the moved code carry the targetsconduit_admin::api::…instead ofconduit::admin::api, soRUST_LOG=conduit::admin=debugno longer matches them. The crate has one feature,cache(the purge endpoint), enabled by the root’scache. - The server bootstrap, the Admin API’s background supervisor and
POST /reload, config validation, and the CLI’s subcommand dispatch moved into two new workspace crates,lopatnov-conduit-serverandlopatnov-conduit-cli(issue #147):run_server()(Pingora bootstrap, TLS/plain listener wiring, ACME procurement, Redis rate-limiter connect, TCP/redirect services),AdminApiService(the rate-limit cleanup, health probe/warmup, Redis cache connect and hot-reload watcher background tasks, plusPOST /reload),validate()/feature_warnings()and the file/Kubernetes config providers on one side;main()’s CLI subcommand dispatch and everyconduit <command>implementation on the other. No config shape, route, or CLI flag changed. Two behaviour changes rode along, listed under Fixed: the Kubernetes config path is now validated, and two Admin API background tasks now stop on shutdown. One operator-visible effect: thetracinglines from the moved code carry the targetsconduit_server::…instead ofconduit::server::…/conduit::admin::api/conduit::config::…, so a filter such asRUST_LOG=conduit::server=debugno longer matches them (the defaultwarnlevel is unaffected).clap/clap_complete/clap_mangen/dialoguerare no longer root-crate dependencies (conduit- cliowns them now);indicatif,thiserrorand the root’s directpingora-cacheedge were unused and are dropped from the workspace entirely. Ten root features (proxy,redis,consumers,cache,acme,tcp,upload,hotreload,tokio-metrics,kubernetes) now also forward intoconduit-server, andkubernetesintoconduit-clitoo — every existing feature name and bundle (standard/gateway/full/etc.) is unchanged. - The config schema (
AppConfig,SiteConfigand the types they contain) and the config-file parsing moved into a new workspace crate,lopatnov-conduit-config(issue #222). No config shape or behaviour change: the crate has no Cargo features and gates no field, and the root crate re-exports everything from the sameconfig::schema/config::parsepaths.
[1.2.0] — 2026-08-23
Security
AllowedHostsGuardis now secure by default. Previously, Host-header validation only applied whensecurityHeaders.allowedHostswas explicitly configured — a site with nosecurityHeadersblock (orallowedHostsunset) accepted anyHostheader, which is then echoed intoX-Forwarded-Hostfor the upstream. Applications that build absolute URLs (e.g. password-reset links) from that header are vulnerable to Host-header injection / poisoned-reset-link attacks. Conduit now falls back to validating the incomingHostagainst the matched site’s ownhost:config value whenallowedHostsis not set, rejecting anything else with400 Bad Request. Catch-all sites (hostunset or"*") are unaffected and continue to accept anyHost. ExplicitallowedHostsconfiguration still takes precedence when present.- JWT header-template claim spoofing on
skipPathsroutes fixed. `` header-template substitution decoded and trustedAuthorization: Bearertokens unconditionally, even onjwtAuth.skipPathsroutes whereJwtGuardnever verifies the token’s signature. An attacker could forge an unsigned token on a skipped path and have arbitrary claim values spoofed into upstream-trusted headers. - Consumer authentication silent-bypass warning added.
feature_warnings()now warns whensites[].consumersis configured but Conduit was compiled without--features consumers(consumer auth is fully disabled and every request bypasses it) or when a consumer’ssharedJwt/per-consumerjwtcredential is configured without--features jwt(those consumers are permanently unreachable) — previously silent, unlike every sibling feature. anyhowbumped1.0.102 → 1.0.104— fixes RUSTSEC-2026-0190 (unsoundness advisory).- IP filter hardening: IPv4-mapped IPv6 addresses (
::ffff:a.b.c.d) are now normalized before CIDR matching, so an IPv4-only rule correctly matches a client arriving over an IPv4-mapped IPv6 socket; the dynamic deny-list now recovers fromRwLockpoisoning instead of failing open.
Fixed
- Hostname-based upstream targets work again. Previously only IP-literal
upstream addresses were accepted — any hostname target (Docker service
names,
localhost, etc.) failed every request. global.workersis now actually applied. The setting was parsed and validated but never reached Pingora’s server construction — the proxy always ran with Pingora’s default thread count regardless of what was configured.- Circuit breaker (
healthCheck.maxConnectionsPerUpstream) now enforced for every load-balance strategy, not justLeastConn— the other 7 strategies (including the defaultRoundRobin) never checked connection load when selecting among healthy candidates. Also now enforced for theroutes[]andgroupsconfig paths, which previously had no circuit-breaker logic at all. - Passive health tracking (Outlier Detection, Peak EWMA latency, per-peer
response stats) now works for every load-balance strategy, not just
LeastConn. routes[]retry no longer rotates into an already-unhealthy peer — the retry candidate list is now health/capacity-filtered the same way the top-levelproxyrouting path already was.- TLS certificate near-expiry now warns instead of blocking startup. A
certificate within its expiry window previously hard-failed server
startup/
/reload; it now logs a warning and continues (conduit validateCLI is unchanged — still exits non-zero on any finding, by design).POST /certs/reloaddocumentation corrected: the endpoint rewrites the cert/key files on disk but a restart (not/reload) is required to activate a rotated certificate, since Pingora 0.8 has no hot-swap API. - Consumer
rateLimit.limit/windowSecsof0is now rejected at config-validation time, instead of silently locking the consumer out of every request at runtime.
1.1.0 — TBD
Security
- Upgrade
pingoraand allpingora-*crates0.8.0 → 0.8.1— mitigates HTTP/2 Bomb (CVE-2026-47774 / RUSTSEC) by bounding the default H2 server header-list size to 64 KiB and limiting concurrent streams to 100. - Upgrade
jsonwebtoken9.3.1 → 10.4.0— fixes CVE-2026-25537 (Type Confusion leading to potential authorization bypass).
Changes
- Bump GitHub Actions in CI/CD workflows (Trivy, taiki-e/install-action, codeql-action, attest-build-provenance) via Dependabot.
- Fix release workflow artifact naming: standard and full builds for the same target now use distinct artifact names, ensuring all binaries appear in the GitHub Release.
1.0.0 — 2026-06-02
This release promotes Conduit to a stable, production-ready API gateway and reverse proxy. It adds authentication, scripting, observability, reliability, and security features across every layer of the stack, and introduces a compile-time feature-flag system so the binary stays lean for simple deployments.
Security fixes
- SSRF — proxy loop prevention — Requests that would route back to Conduit
itself are rejected with
421 Misdirected Request. - SSRF — ForwardAuth URL validation —
forwardAuth.urlis validated at startup; loopback / metadata CIDR targets are rejected. - Timing-safe credential comparison — Basic Auth and API-key comparisons
use
subtle::ConstantTimeEqto eliminate timing side-channels. - X-Consumer-ID injection — Header is stripped from incoming requests before the consumer pipeline runs to prevent spoofing.
- X-Priority bypass — Untrusted
X-Priorityheader cannot raise effective priority above the configured route ceiling. - Cache poisoning via unkeyed headers — Host normalisation and scheme derivation prevent cache-key collisions across virtual hosts.
- Static-file symlink safety —
O_NOFOLLOWused on directory open; pre-compressed.br/.gzsidecar resolution rejects symlink traversal. - TOCTOU in static file handler — Path resolved once and reused; no re-stat window between permission check and open.
- Request smuggling — CRLF stripping —
\r/\ncharacters in upstream response header values are stripped before forwarding. - Blocking I/O in async context — File I/O moved to
tokio::task::spawn_blockingto prevent Tokio thread-pool starvation. - Query string redaction in logs —
logging.stripQuery: trueremoves query parameters from the logged path to prevent PII / token leakage. - reqwest connect timeout —
connect_timeoutset on ForwardAuth and JWKS clients to bound latency under DNS failure. - WASM CPU limiting — Wasmtime fuel consumption enforced per invocation; runaway plugins cannot monopolise worker threads.
- Server header suppression —
Server:header from upstream is removed by default to avoid information disclosure. - Admin API loopback-only binding — HTTP server for the Admin API binds
exclusively to
127.0.0.1; configuring a non-loopback address is rejected. - 20+ additional hardening fixes identified through systematic audit of 200+ potential vulnerability patterns (cache, auth, retry, proxy, TLS layers).
Added — Authentication & Authorisation
-
JWT Bearer token validation (
--features jwt) — HS256 (shared secret) and RS256/ES256 (JWKS URL).jwtAuth: { jwksUrl, issuer, audience, skipPaths }. JWKS cached per-URL with background refresh. 60-second leeway for clock skew.jsonwebtoken = "9". -
Consumer model (
--features consumers) — Named API clients with individual credentials (API key, Basic Auth, JWT), per-consumer rate limits, and injectedX-Consumer-IDheader.consumers.sharedJwtsupports Auth0 / Cognito / Keycloak patterns with JWKS andsubclaim identification. -
Forward Auth (
--features forward-auth) — Delegate authentication to an external HTTP service. 2xx → allow + inject response headers; 4xx/5xx → deny; unreachable → fail closed.forwardAuth: { url, requestHeaders, responseHeaders, timeoutMs, skipPaths }. -
mTLS — client certificate authentication —
tls.clientAuth: { ca, optional }. RustlsWebPkiClientVerifier; CA bundle loaded from a PEM file. Optional mode allows unauthenticated clients while still forwarding cert info. -
Admin API Bearer token auth —
global.admin.tokenprotects every Admin API endpoint; Conduit returns401for missing or invalid tokens. -
Conditional error responses —
401/403responses honourAccept:application/jsonclients get{"error":"…","status":N}; others get an empty body.
Added — Load Balancing & Routing
-
P2C — Power of Two Choices (
loadBalance: p2c) — O(1) pick via splitmix64 RNG; routes to the less-loaded of two randomly selected upstreams. Combines with Peak EWMA latency for latency-aware balancing. -
Peak EWMA latency tracking — Per-upstream
ewma_latency_us(α = 0.1) updated passively on every request inlogging(). Used by P2C. -
Sticky sessions —
proxy.*.sticky.cookie: consistent-hash keying on a named cookie value; first request sets the cookie, subsequent requests are pinned to the same upstream. -
Outlier Detection —
outlierDetection: { consecutive5xx, baseEjectionTimeSecs, maxEjectionTimeSecs, maxEjectionPercent }. Exponential ejection backoff. Maximum ejection percentage enforcement prevents full cluster removal. -
Half-open circuit breaker — When an ejection period expires the first request is allowed through as a probe. Successful probe → full recovery + reset ejection count; failed probe → re-eject at next backoff level.
-
Circuit Breaker —
healthCheck.maxConnectionsPerUpstream: when all healthy upstreams reach the connection limit Conduit returns503immediately (LocalHandler::Overloaded) rather than queuing. Works with all LB strategies. -
Service Failover —
proxy.*.backup: traffic is routed to the backup URL when all primary upstreams are unhealthy. -
Upstream slow start —
healthCheck.slowStartSecs: traffic to a recovered upstream ramps up linearly over the configured window. -
Connection pool warmup —
healthCheck.prewarmConnections(max 8): Conduit sends HEAD requests at startup to pre-establish keepalive connections. -
Header-based routing with regex —
routes[].match.headers: route on the presence or regex value of a request header. -
Cookie-based routing —
routes[].match.cookies: route on cookie presence or exact value. -
Query parameter routing —
routes[].match.query: route on query parameter presence or regex value. -
Priority routing / load shedding —
proxy.*.priority(0–100) +limits.priorityThreshold(default0.8). Wheninflight / maxInflight ≥ threshold, routes with effective priority < 50 receive503 Load Shedding. Trusted callers can raise priority via theX-Priorityrequest header.
Added — Reliability
-
Inflight request limit —
limits.maxInflightRequests: enforced byLimitsGuardbefore any auth processing; returns503when exceeded. -
Per-IP connection limit —
limits.maxConnectionsPerIp: returns429when a single client IP exceeds simultaneous open connections. -
Request body buffering for retry —
limits.maxBodyBufferBytes: body chunks accumulated inRequestCtx.body_bufferand replayed on retry (linkerd2 ReplayBody pattern). Overflow setsbody_too_large = true(retry skipped). -
Retry budget —
retry.budgetPercent: soft limit on the fraction of active requests that may be retries; prevents retry storms under mass failure. -
Per-try timeout —
timeout.perTryMs: independent deadline for each retry attempt. -
Retry exponential jitter —
retry.backoffJitter: true: applies ±50% randomness tobackoffMsso retries from concurrent failures spread out in time rather than hitting the upstream in a synchronised wave. -
Traffic Mirroring —
proxy.*.mirror: fire-and-forget copy of every request to a shadow URL viatokio::spawn+ reqwest. Primary response is unaffected.X-Mirrored-Fromheader added to the shadow copy. -
Stale-while-revalidate (RFC 5861) —
cache.staleWhileRevalidateSecs+cache.staleIfErrorSecs. Stale responses served while a background fetch refreshes the cache; stale responses on upstream 5xx. -
Cache thundering herd prevention — Pingora
CacheLock(16 shards, 10 s timeout): the first request on a cache miss takes a Write permit; all others wait for the Read permit from the same fetched copy.
Added — Extensibility
-
Rhai scripting middleware (
--features rhai) —type: "script"in the middleware array. Request phase: inspect/modify headers, abort with status. Response phase:phase: "response"— inspect upstream status and headers, set/remove response headers. Resource limits: 500 000 operations, 1 MiB string, 65 536 array elements. Configurable per-pluginconfigmap. -
WASM plugin middleware (
--features wasm) —type: "wasm"via Wasmtime. 17 host functions: read/write request headers, set response, get URI, get request ID, abort with redirect, log. Optionalon_response(status) -> i32export for response-phase plugins. Per-plugin fuel limiting (CPU cap). Module cache. Fail-open: plugins without expected exports are silently skipped. -
Request / Response Header Transforms —
requestTransform/responseTransform: { setHeaders, removeHeaders }. JWT template substitution:,, `` inrequestTransform.setHeaders. -
Fault Injection (
--features fault-injection) —faultInjection: { abort: { percent, status, body }, delay: { percent, ms } }. splitmix64 RNG. Intended for chaos / resilience testing only; not for production. -
Phase-ordered response pipeline —
ResponseFilterChainwith six phases: CrlfProtection → InjectExtraHeaders → ResponseTransform → ResponseTime → RetryOnError → ErrorMask. New response-phase behaviour is added as a new phase struct, not by editingupstream_response_filter.
Added — Observability
-
OpenTelemetry OTLP distributed tracing (
--features otlp) —global.otlp: { endpoint, serviceName, sampleRate, timeoutMs }. One span per request: method, path, status, duration, upstream URL, request ID. 5xx → span status ERROR. Compatible with Grafana Tempo, Jaeger, Honeycomb. -
Structured access log — JSON log format now includes
request_id(fromX-Request-ID),upstream(selected upstream URL), andupstream_ms(time from request forwarded to upstream response received). -
X-Request-ID injection —
XRequestIdGuard(first guard in chain): generates a UUID v4 if absent, forwards existing value. Exposed in OTLP spans and access logs. -
Per-upstream Prometheus metrics — Three new metrics per upstream URL:
conduit_upstream_requests_total{upstream,status}(counter),conduit_upstream_latency_seconds{upstream}(histogram),conduit_upstream_active_connections{upstream}(gauge). -
Additional site-level metrics —
conduit_active_connections(gauge),conduit_upstream_errors_total{route,status}(counter),conduit_retry_attempts_total{route,condition}(counter),conduit_rate_limit_rejected_total{site}(counter),conduit_cache_hits_total{route}/conduit_cache_misses_total{route}. -
Extended health endpoint —
/__health__?includeUpstreams=true(orhealthCheck.includeUpstreams: true) returns per-upstreamlatency_ms,ejectedstatus, andconsecutive_5xxcount. -
conduit status --upstream— Prints an upstream health table (URL, healthy, latency, ejected, 5xx count) sourced fromGET /upstreams. -
logging.stripQuery— Removes query string from the logged path to prevent PII or token leakage in access logs.
Added — Caching
-
Disk cache (
--features disk-cache) —cache.store: "disk:/path". Atomic write (temp → rename). Persists across restarts. -
Redis cache (
--features redis) —cache.store: "redis://..."/"rediss://..."(TLS). Shared across multiple Conduit instances. Fail-open: unreachable Redis silently disables caching for that request. -
Cache purge API —
DELETE /cache/purge?url=<url>on the Admin API. Calls Pingoraforce_expire()on the matching cache key. -
RFC 7234 compliance —
s-maxagedirective respected from upstreamCache-Control;s-maxage=0,no-store,privateprevent caching. ConfiguredttlSecscaps the upstream-supplied TTL. -
cache.varyHeaders— Vary cache key by named request headers (Accept-Language,Accept-Encoding, etc.) for content-negotiated responses. -
compression.types— Content-Type prefix allowlist for on-the-fly compression; binary content (images, video, archives) excluded by default.
Added — Networking
-
TCP proxy mode (
--features tcp) —type: "tcp"site withtcp: { targets, strategy, connectTimeoutMs }. Bidirectional relay viatokio::io::copy_bidirectional. Round-robin and random strategies. -
Zstd compression —
algorithms: [zstd]; client preference respected viaAccept-Encodingnegotiation. -
HTTP/2 cleartext (h2c) —
http2.h2c: true; allows HTTP/2 over plain TCP for internal service mesh use. -
Keepalive request limit —
limits.keepaliveRequestLimit: close and recycle connections after N requests (equivalent to nginxkeepalive_requests). -
Upstream TLS verification —
proxy.*.upstreamTls: { verify, serverName }: controls certificate and hostname verification for backend HTTPS connections. -
X-Forwarded-Host— Injected alongsideX-Forwarded-ForandX-Forwarded-Protoinupstream_request_filter.
Added — Admin API
-
POST /certs/reload— Submit new PEM cert + key pair; Conduit validates the pair (rustls cert/key match check), writes atomically to the configured paths. Full zero-downtime hot-swap awaits Pingora 0.9+. -
POST /ip-deny/DELETE /ip-deny— Add or remove CIDRs from the runtime deny-list without a config reload.IpGuardreads the dynamic list on every request alongside the staticipFilter.denyconfig. -
Admin API only starts when configured — The HTTP server binds only when
global.adminis present in config. Background tasks (health checks, rate-limiter cleanup, hot-reload watcher) always run regardless.
Added — Configuration
-
YAML config support — Auto-detects
conduit.yaml/conduit.yml;from_yaml()inparse.rs; env interpolation and version checks work identically to JSON. -
Provider pattern —
Providertrait insrc/config/provider.rs.FileProvider: one-shot load + inotify/kqueue auto-reload vianotify. DeliversAppConfigon a channel; hot-swap is driven by the existing ArcSwap mechanism. -
Kubernetes CRD provider (
--features kubernetes) —ConduitSitecustom resource viakube::CustomResource.KubernetesProvider: list + watch pattern.--kubernetes-namespaceCLI flag;"*"watches all namespaces. CRD manifest:contrib/k8s/conduitsite-crd.yaml. -
Feature flag startup warnings — When a config field requires a feature that was not compiled in (e.g.
jwtAuthwithout--features jwt), Conduit logs aWARNat startup and on every hot-reload. The/reloadresponse includes awarnings: [...]field. -
ipFilter.dryRun— Log IP-filter violations without enforcing them. Useful for auditing a deny list before enabling enforcement. -
rateLimit.dryRun— Log rate-limit violations without rejecting requests. -
healthCheck.unhealthyStatus— Status codes from the health-check probe that count as failures (e.g.[429, 500, 502, 503, 504]). -
healthCheck.unhealthyLatencyMs— Probe responses slower than this threshold count as failures even when the status code is 2xx. -
securityHeaders.permissionsPolicy— SetsPermissions-Policyheader. -
securityHeaders.allowedHosts— Rejects requests with aHostheader not in the allowlist with421 Misdirected Request. -
securityHeaders.hstsIncludeSubDomains/hstsPreload— Fine-grained HSTS directive control. -
limits.maxConnectionsPerIp— Per-client IP simultaneous connection cap. -
logging.stripQuery— Strip query string from access log path field.
Added — Build system
-
14 optional compile-time features —
jwt,consumers,forward-auth,rhai,wasm,tcp,upload,redis,cache,disk-cache,acme,fault-injection,otlp,kubernetes. Default build (default = []) is the minimal standard proxy.--features fullenables everything. Binary size reduction: ~30% smaller standard build vs full build. -
Two Docker image variants —
:latest(standard, ~14 MB, no optional features) and:latest-full(all 14 features). Multi-stage musl build,FROM scratch, runs as UID 65534. -
CI full-features builds — GitHub Actions matrix now includes a
--features fullbuild alongside the standard build for both Linux and macOS.
Added — CLI
-
conduit init --yes— Non-interactive mode; accepts--port,--proxy,--static,--tlsflags for scripted config generation. Supports YAML output. -
conduit fmt— Preserves input format: YAML files stay YAML, JSON stays JSON;--writeoverwrites in place. -
conduit probe— Parallel HEAD requests to all configured upstreams; results sorted by URL with ✓/✗ status and latency.
Added — Documentation
docs/admin.md— Complete Admin API reference with request/response examples for all endpoints.docs/rhai.md— Rhai middleware development guide.docs/wasm.md— WASM plugin development guide with examples in Rust, C, and Go.docs/configuration.md— Comprehensive reference: all config fields documented, including 14 fields that were previously missing from the reference.docs/recipes.md— 30+ configuration recipes covering common deployment patterns (SPA+API, mTLS, Auth0 JWT gateway, circuit breaker, file upload, etc.).docs/cli.md— Build features overview table; per-feature usage sections.examples/— 40+ JSON and YAML config examples for every major feature.
Changed
-
conduit init— Now generates YAML by default;--jsonflag outputs JSON. -
Hot vs cold reload classification — Port, TLS cert/key/versions/ciphers, workers, backlog, admin address → cold reload (returns error). Everything else → hot reload via ArcSwap without dropping connections.
-
GET /status— Response enriched with runtime stats: inflight count, uptime, config path, feature flags enabled. -
GET /upstreams— Response includeslatency_ms,ejectedstatus,consecutive_5xx,half_openflag,ewma_latency_us, andconn_countper upstream entry. -
conduit validate— Now also callsfeature_warnings()and includes warnings in output for configs that reference disabled features.
Fixed
WeightedRoundRobintargets validated asWeightedTargetobjects, not strings.FallbackConfigdoes not accept aredirectfield (was silently ignored before).conduit fmtwith--writenow handles concurrent reload correctly.- TCP proxy port conflict detection added to
conduit validate.
0.3.0 — 2026-05-26
Added
-
Two-level load balancing (
groups) — Route to named upstream groups via an outergroupStrategy, then distribute within each group via its ownstrategy. Enables geographic (region-based), tiered (canary/stable), or any topology that benefits from a two-level hierarchy. Supports all seven load-balancing strategies at both levels. -
Path rewrite (
rewrite) — Regex-based path transformation rules applied afterstripPrefix. First matching rule wins. Capture groups ($1,$2, …) are supported. -
Advanced route table (
routes) — Explicit ordered route array with full match criteria: glob path, HTTP method list, header regex, query regex. Backward-compatible with existing top-levelproxyandstaticfields (auto-normalized at parse time). -
Shell completions —
conduit completions <bash|zsh|fish|powershell|elvish>prints completion script for the given shell. -
Man page —
conduit manprints a troff-formatted man page to stdout. Pipe toman -l -or install withconduit man > /usr/share/man/man1/conduit.1. -
GET /upstreamsenriched — Admin API response now includes aroutesarray showing per-route strategy, target weights, health, latency, and runtime-override flag. -
Contrib assets —
contrib/Dockerfile(multi-stage musl +FROM scratch),contrib/docker-compose.yml(conduit + Node.js backend example),contrib/conduit.service(hardened systemd unit withProtectSystem,NoNewPrivileges). -
New config examples —
examples/path-rewrite.json,examples/upstream-groups.json. -
JSON Schema — Added
RouteConfig,MatchConfig,UpstreamGroup,RewriteRuledefinitions;routesfield onSiteConfig;rewrite/groups/groupStrategyonProxyRouteConfig;targetsno longer required whengroupsis set.
Changed
-
ProxyRouteConfig.targets— No longer required in the JSON config whengroupsis configured. Previously the absence oftargetscaused a parse error. -
conduit validate— Emptytargetsis now allowed whengroupsis set. Each group is validated to contain at least one target.
0.2.0 — 2026-05-24
Added
-
Prometheus metrics (
/__metrics__) —conduit_requests_total(CounterVec) andconduit_request_duration_seconds(HistogramVec). Optional Bearer token auth. -
Upstream health checks — Background HTTP probes with
unhealthyThreshold/healthyThreshold. Unhealthy upstreams are excluded from load balancing. -
least-connstrategy — Tracks active connections per upstream with atomic counters. -
randomstrategy — Uniform random upstream selection. -
Dynamic upstream management —
POST /upstreams/add|remove|weight(Admin API) and matchingconduit upstreams add/remove/weightCLI subcommands. Changes survive untilconduit reload. -
Proxy cache — In-memory response cache via
pingora-cache. Configurable TTL,skipIfCookie,skipPaths, allowed HTTP methods. CVE-2026-2836 mitigated via custom cache key (host + scheme + path + query). -
Hot config reload —
POST /reload(Admin API) /conduit reload. Hot fields reload without dropping connections; cold fields (port, TLS cert, workers) return an error listing what changed. -
Auto-TLS via ACME —
tls.acmefield;instant-acme+rcgen+ HTTP-01 challenge handler. Background renewal 30 days before expiry. -
File upload — Axum loopback server on
127.0.0.1:0. UUID filenames, MIME allowlist, per-file and total size limits. -
Browser hot-reload — SSE endpoint +
notifyfile watcher + debounce. Injects/__hot-reload__/client.jsautomatically. -
Pre-compressed static files — When
staticOptions.preCompressed: true, Conduit serves.br/.gzsidecar files without on-the-fly compression. -
SNI / multi-cert TLS — Multiple TLS certificates per server via SNI.
-
WebSocket proxying — Transparent
Connection: Upgrade/101 Switching Protocolstunnel through the proxy layer. -
CORS — Preflight
OPTIONShandling, per-origin response headers, credentials mode,Vary: Origin, configurable max age. -
Security headers — X-Content-Type-Options, X-Frame-Options, Referrer-Policy, X-XSS-Protection; HSTS and CSP via object form.
-
conduit init— Interactive wizard (dialoguer) that generates a starter config. -
conduit probe— HEAD each configured upstream and display a latency table withindicatifprogress bar.
Changed
GET /upstreamsnow returns live health status, latency, and inflight connection count for every upstream tracked by the health registry.
0.1.0 — 2026-05-23
Added
-
Core proxy pipeline — Pingora-based HTTP/1.1 + HTTP/2 reverse proxy with full request/response filter pipeline.
-
Static file server — ETag, Last-Modified, Cache-Control, Range requests, dotfile control,
indexfile list. -
TLS — rustls via Pingora;
tls.httpRedirectPortfor HTTP → HTTPS redirect. -
IP filtering — CIDR allowlist / denylist,
trustProxyforX-Forwarded-For. -
Request limits —
maxBodyBytes(413),maxHeaderBytes(431),timeoutSecs. -
Rate limiting — Token-bucket algorithm, per-IP or per-header keying, path exclusions.
-
Basic Auth — RFC 7617
Authorization: Basic, WWW-Authenticate challenge. -
API key auth — Custom header (
X-API-Keydefault), path exclusions. -
Redirect rules —
:paramcapture, 301/302/307/308, query string preserved. -
Virtual hosting —
hostfield, catch-all*, duplicate detection. -
Admin API (
127.0.0.1:2019) —GET /status,POST /reload,POST /shutdown,GET /upstreams. -
Access logging — five formats:
combined,common,dev,short,json. File output with atomic switch on reload. -
Compression — on-the-fly gzip and Brotli (
Accept-Encoding); streaming one-chunk-ahead buffering; Range requests bypass compression. -
X-Response-Time — millisecond precision, configurable decimal digits.
-
Proxy retries — configurable attempts,
connection_error/5xx/timeoutconditions, backoff in milliseconds. -
conduit validate— exits 0 when config is valid, 1 with error list otherwise. -
conduit fmt— pretty-prints the config to stdout;--writeoverwrites in place. -
JSON Schema (
schema/conduit.schema.json) — covers the full config surface. -
Config examples —
minimal.json,spa-with-api.json,multi-site.json,tls-h2.json,tls-acme.json,load-balanced.json,with-cache.json,dev-hot-reload.json. -
CI — GitHub Actions matrix: ubuntu / macos / windows, fmt + clippy + test.
-
Release pipeline —
cross-compiled binaries for six targets; Docker image (musl +FROM scratch); npm wrapper (npx conduit); crates.io publish.