Network egress
Everything the platform sends outbound (webhooks, integration calls, plugin HTTP, workflow script requests, repository fetches) passes through one shared guard. This page states what it blocks, what it cannot block, and how an operator opens a hole deliberately. The contributor rule is every outbound client is guarded.
What the guard refuses
Deny-by-default, in this order:
- Non-HTTP(S) schemes.
- URLs carrying embedded credentials.
- Private destinations, checked at TCP connect time after DNS resolution: loopback, unspecified,
link-local, cloud-metadata, carrier-grade-NAT, multicast and broadcast, RFC 1918, unique-local, site-local and the
reserved
240.0.0.0/4ranges. An address is judged by its bits: a zone index (::1%1) is dropped, and an IPv6 form that embeds an IPv4 address (IPv4-mapped, IPv4-compatible, NAT6464:ff9b::/96and64:ff9b:1::/96, 6to42002::/16) is judged as that IPv4 address, so a private IPv4 address cannot be smuggled in by wrapping it. Other network-specific NAT64 prefixes, including the /48, /56 and /64 layouts inside64:ff9b:1::/48, are not recognised: such an address is judged as the IPv6 address it is. Plugin egress follows its own address rule, in plugin egress to the LAN.
User- and admin-supplied URLs are also validated at the API boundary, the hostname checked against the live operator allowlist first, so a hostile value is refused when it is saved rather than only when it is dialled. Connect-time IP checking is the part that matters: a URL-time check alone is defeated by DNS rebinding, because the name that resolved publicly at validation can resolve privately at connect.
While the operator allowlist holds a Host entry, the URL check also rejects every host that matches none of them.
PrivateHost and IpAddress entries open addresses at connect time and restrict nothing. Neither a Host nor a
PrivateHost entry opens a link-local or cloud-metadata address, for core clients or plugins; only an exact
IpAddress entry does. The built-in repository hosts (github.com, gitlab.com, raw.githubusercontent.com,
ghcr.io), the hosts added with Repositories:AllowedHosts and the registries listed in
Repositories:PlainHttpRegistries are exempt from the private-address block.
With HTTP_PROXY/HTTPS_PROXY set, core egress (webhooks, workflow HTTP, OIDC, blueprints, error reporting)
is checked against the proxy's address, not the target; the proxy then decides what is reachable, including
link-local metadata. Plugin egress ignores the proxy (see below).
The OIDC back-channel (the discovery document, the signing keys and the token endpoint) is a guarded client
attributed as core:oidc, so a jwks_uri or token_endpoint that the provider's discovery document names is
checked at connect like the configured addresses. Authentication:Oidc:AllowPrivateMetadata opens LAN and loopback
addresses for this client only; link-local, cloud-metadata, carrier-grade-NAT, multicast and unspecified addresses
stay closed to it.
The guarded handler
- Every guarded client carries an overall request timeout.
- The handler is pooled across workflow runs, webhooks and plugins, so it keeps no cookie jar
(
UseCookies = false): aSet-Cookieis never replayed to another caller. A caller's explicitCookieheader is sent as written. - Only
Authorizationis stripped automatically on a redirect, so a client that sends a credential in any other header must disable automatic redirects. - A block on any redirect hop is attributed to the caller. Connect-time blocks arrive wrapped in an
HttpRequestException; boundary refusals arrive bare. - An
SsrfBlockedExceptionmessage is safe to show to the caller. Its structured reason, host, port and resolved address are internal attribution only, and only the reason's name is persisted.
Redirects
The inner handler never follows redirects automatically, for any method. A safe wrapper follows GET 3xx responses only; a non-GET 3xx is handed back raw and the caller decides whether to re-issue.
The per-plugin host allowlist is re-checked at every hop. A chain from an allowed host to another allowed host to a disallowed one is refused at the second hop, even though the first two hops are individually permitted.
A redirect from HTTPS to HTTP is not followed: the 3xx is handed back to the caller, so neither a credential nor the response (an OIDC key set, a blueprint) travels in cleartext. A redirect is deny-by-default across a host or port boundary: only an allow-list of safe headers is forwarded and everything else is dropped, so no credential crosses. A hop inherits the redaction mark of the request that started the chain, because a handler below the logging handler never passes back through it.
The operator allowlist
The effective allowlist has one source, chosen when the host starts. By default it is the enabled database
rows, read per request, so a change takes effect without a restart; rows can be added, enabled, disabled,
annotated and deleted. When the deployment declares Managed:Egress, the allowlist is that section alone: the
rows are ignored, the interface lists the section's entries with the source config, and every write answers
409 feature_managed (a caller without egress.manage still receives 403). The section is polled and applied
without a restart on every replica; see managed configuration.
Entries match case-insensitively, so unblocking example.com reuses an existing Example.com row,
and an update always advances its modification time, so a note-only change is stamped. Hosts the operator
allowlisted may resolve to private or loopback ranges at connect time; that is the escape hatch for
on-premises servers. A host entry never opens a link-local or cloud-metadata address, and for plugin egress it does
not open any of the always-closed networks; only an exact address entry (IpAddress) of the allowlist does. An IpAddress entry takes an exact address; a CIDR range is
refused.
A Host or PrivateHost entry is a host pattern. An entry that breaks the grammar is refused:
the panel answers 400 with the rule, and a Managed:Egress section that holds one is refused with a
configuration.invalid alert while the last valid list stays in force. A stored row the grammar no longer accepts
is skipped and admits nothing, but it still counts as a Host entry, so the list stays strict rather than opening.
Repository syncs and registry pulls follow Repositories:AllowedHosts
(configuration), not this list. Plugin, widget
and blueprint repository syncs, resource index syncs and OCI registry pulls are not checked against the Host
entries, so narrowing the list does not stop them; they still pass the connect-time address check. Adding a blueprint
or widget repository or a resource index is checked against the list: while it holds a Host entry, the repository's
host must match one.
Private-host entries match host only. A port suffix on such an entry is ignored: naming a host opens every port on it. Do not write a port expecting it to narrow the grant.
Reading the allowlist and the block log needs egress.view; changing them needs egress.manage.
Plugin egress to the LAN
Plugin egress, the vended HTTP client and the broker connection of mqtt.outbound, is checked once per resolved
address, after DNS, at TCP connect. The plugin's own host allowlist decides which names it may
dial; the address rule decides where those names may land:
| Address class | Ranges (IPv4-mapped forms included) | Plugin egress |
|---|---|---|
| Always closed | loopback 127.0.0.0/8, ::1; unspecified 0.0.0.0/8, ::; link-local 169.254.0.0/16, fe80::/10; the cloud metadata addresses outside link-local (192.0.0.192, Azure 168.63.129.16, AWS fd00:ec2::254, Google Cloud fd20:ce::254, Oracle Cloud fd00:c1::a9fe:a9fe, Akamai fd00:a9fe:a9fe::1); carrier-grade NAT 100.64.0.0/10; multicast 224.0.0.0/4, ff00::/8, and broadcast 255.255.255.255 |
Refused, whatever the grant and the operator host lists say |
| LAN | RFC 1918 10.0.0.0/8, 172.16.0.0/12, 192.168.0.0/16; reserved 240.0.0.0/4; unique-local fc00::/7 other than the metadata addresses; deprecated site-local fec0::/10 |
Open for any granted host, unless the tightening below is on |
| Everything else | public addresses | Open for any granted host |
The only way through an always-closed address is an exact address entry (IpAddress) in the operator
allowlist. A host entry on the private-host list does not open it for plugins.
Of the Reeve host's own addresses only loopback is closed. The backend's pod or container address, the
node's address, the Docker bridge gateway on Compose, and every in-cluster Service and pod address are LAN
addresses: a plugin granted "*", or a granted name that resolves there, reaches them. A service there that
must stay out of plugins' reach needs its own authentication or a network policy. The tightening below keeps
fixed manifest names off the LAN; it does not narrow a "*" grant.
The vended HTTP client ignores the system proxy (HTTP_PROXY, HTTPS_PROXY) and never negotiates HTTP/3,
so the check always sees the address that is actually dialled; a plugin request for HTTP/3 is sent over
HTTP/2 or HTTP/1.1.
Reeve runs no broker of its own, so a broker connection under mqtt.outbound always names its broker, is admitted
only when the broker is on the plugin's granted hosts, and then passes the address rule above. A broker receives only the credentials the plugin supplied. A refused broker logs Blocked egress with the host and resolved address on every attempt, and
the connection retries on its reconnect backoff, logging its first five failures and then every twentieth. An MQTT
refusal writes no row to the blocked-egress log. A broker dialled through the check must accept the TCP connection
within SsrfGuard:ConnectTimeout, or the attempt fails and is retried.
Tightening. With Plugins:Egress:LanOnlyThroughOwnerAddresses on (off by default), a LAN address is
reached only when one of these admits it:
- the plugin's grant is
"*"; - the allowlist entry that admits the host was typed by the owner into an instance's configuration through a config host token, not fixed in the manifest;
- the host is on the operator's private-host list;
- the address is on the operator's address list.
A fixed manifest name that resolves to a LAN address is then refused, which closes DNS rebinding of a public name onto the LAN. A refusal logs the resolved host and its address, never a configuration value. The setting is in configuration.
A plugin's OAuth token exchange
The host exchanges the authorization code of a plugin's OAuth step itself, through the plugin's egress. The token
endpoint has to be admitted by the hosts the plugin requests, the grant its configuration flow runs under (a
config: host token does not count, because the owner's values are not part of that grant): an
endpoint outside them is refused with oauth_token_endpoint_not_granted when the authorization URL is built, and
the callback refuses it again before dialling. The connect follows the address rule above, the POST is not
redirected, and a refusal is recorded in the blocked-egress log against the plugin and its pending instance. The
token refresh that follows runs on the core guard (core:oauth-refresh), which closes every private address.
Host patterns
Operator Host and PrivateHost entries and a plugin's fixed hosts share one grammar, [pattern][:port]:
- Labels are separated by dots. A label is 1 to 63 ASCII letters, digits,
-or_, and does not start or end with-; an internationalised label is accepted when its punycode form follows that rule. One trailing dot is ignored, and case never matters. *matches exactly one label and**one or more. A wildcard is a whole label, only the first one, and is followed by at least one other label (*.example.com,**.example.com).:portis 1 to 65535 in digits, or:*; an omitted port means any port.- An IPv6 address is written in brackets,
[fd00::20]or[fd00::20]:8443, without a zone index. An IPv4 address is written as it is, since its labels are digits. Either then matches a URL that names that address. - A scheme (
https://), a path, a query, user information, a space or an unbracketed IPv6 address is refused. - An internationalised name may be written in Unicode or in punycode: both are kept in punycode and match a host given in either form, at URL time and at connect time.
A Host entry naming an address is what lets a URL with that address through a strict list. An IpAddress entry
does not; it only opens the connect-time private-address block.
Clients that do not use the guard
The camera proxy client and the media-plane control, WHEP and remux clients are built without the guard. The guard blocks RFC 1918 addresses at connect, and a Kubernetes ClusterIP is one; these clients exist to reach a plugin's workload or the operator's media plane, both in-cluster. The camera proxy's origin is named by the owning plugin; the media plane's address is the operator's own configuration. Each client disables redirects, so the request goes only to the origin as named, and each has a bounded connect timeout. The residual risk, a plugin that controls its camera origin reaching internal addresses, is in known limitations.
Some clients reach an address only an administrator sets and are not guarded, because that address is usually
on the LAN or in the cluster: the S3 object-storage endpoint (from configuration or the storage administration
page), a Vault or OpenBao address (from configuration), and the external gateway URL the workload gateway's upgrade
probe dials. The GitHub repository client reaches GitHub's hosts only, through a host allowlist rather than the
address check. A C# script block that sets GuardEgress = false on its client opts out of the guard on purpose.
Addresses supplied by other callers
- Blueprint repositories. Repository URLs and the raw-URL template are SSRF-validated when they are
added, so a hostile template host, such as a link-local metadata address, cannot be persisted. The
repository token is attached to a raw fetch only over https and only when the request host belongs to
the repository's provider: GitHub's API, raw and archive hosts, or a GitLab repository's own host and
project path. A GitLab repository URL that names no project path cannot be given a credential. A
self-hosted GitLab is inferred from the hostname and read through the REST raw-file endpoint with
PRIVATE-TOKENand%2F-encoded paths, because the web raw route redirects token requests to the sign-in page. - Device onboarding. A device's network location is validated before the provider is touched. It must
be an IP literal that round-trips to its canonical form (no hostnames, URLs,
ip:portor lax numeric forms) in RFC 1918, link-local or IPv6 unique-local space; an IPv4-mapped address is unwrapped and re-checked; public, loopback, unspecified, multicast and carrier-grade-NAT addresses are refused. A narrowing check also refuses link-local and scope-id addresses, because the commissioner runs in another network namespace where they name no interface; that refusal is terminal and names setup-code pairing as what works.
The blocked-egress log
Every refusal is recorded: host, port, reason, subsystem, resolved address, and the attributed plugin instance or workflow execution. A visible block log turns "the integration silently does nothing" into a diagnosable event.
Recording never blocks the request: observations go through a bounded channel that drops the oldest entry under sustained overflow. The writer coalesces identical signals into one row per flush window and caps rows per host, so a noisy host cannot flood the table. An over-long text field is truncated to its column, and an unparsed URL gets a stand-in host, so the attempt still has a row. Drops and cap sheds are logged as deltas per flush.
Each coalesced row also raises an egress.denied alert for that subject, host and port, and the same
subject's next allowed call to that host and port clears it (see alerts). The
clear is queued and never runs in the request, and a denial recorded after the allowed call stays open.
Rows are paginated, filterable, exportable and pruned after a retention window. The CSV export streams only
after the egress.view check passes. One-click unblock adds the host to the allowlist; unblocking a private
address requires an explicit confirmation, because it is the usual pivot of a server-side request forgery.
Not every refusal can be unblocked that way. A refusal attributed to a plugin's host allowlist is fixed by granting that host to that plugin, not by an operator allowlist entry. Scheme, embedded-credential and DNS refusals cannot be fixed by allowlisting at all.
Successful calls are logged too
Outbound calls from vended plugin clients and from workflow script blocks record the URL, sanitised with secrets and authorization headers stripped, and the response status, visible in the plugin call log and the workflow execution log.
TLS trust for a private CA
Tls__TrustedCaCertificates adds CA roots to the host's own outbound TLS, after the system roots: a
certificate the system roots accept is accepted, a host name mismatch or a missing certificate is never
rescued, and with no list nothing changes. The list is read once at start. Every IHttpClientFactory
client gets this trust after its own configuration, and only when its primary handler sets no validation
callback or chain policy of its own.
It is trusted by the guarded clients above (including a plugin's HTTP egress and its OAuth token exchange, and
the OIDC back-channel), the other IHttpClientFactory clients (GitHub, camera and media plane), the OTLP trace
and metric exporters, the S3 object-storage client, Vault and OpenBao (together with the provider's own
CaBundle), the gateway upgrade probe, and MQTT connections that set no CaFilePath, including a
plugin's. A plugin that opens its own TLS can ask for IHostTlsTrust.
It does not cover:
- Npgsql and Redis, which keep the trust settings of their connection strings, and the Kubernetes and Docker clients, which trust the cluster CA or a socket.
- The Serilog Grafana Loki sink, built from configuration outside the host's dependency injection.
- An OTLP exporter configured with its own mTLS options (
OTEL_EXPORTER_OTLP_CERTIFICATE, client certificate): it validates against that CA and bypasses the list. - A pinned plugin host, an MQTT
CaFilePath, and any client that sets its own validation: each is an explicit narrowing that the list does not widen. ACaFilePathreplaces the system roots with that one CA; intermediates the broker presents complete the chain to it but never become an anchor, and the broker certificate must still name the broker's host and carry the server-authentication usage. - Plugin code that builds its own client without
IHostTlsTrust, and workloads, which receive the list as an environment value instead.
The listed-CA check does no revocation check. On MQTT that differs from the platform verdict: a revoked broker certificate issued by a listed CA is accepted.
Certificate pinning
Pinning is per host: an exact allowlist of leaf SHA-256 thumbprints, where chain and name errors are ignored (the point of pinning a self-signed LAN device) and every other certificate is refused. Unpinned hosts keep normal validation. A pinned host completes its handshake inside the connect callback and returns the negotiated stream, the one place the handshake can be controlled, so it never reaches the host trust list.
No TLS session resumption
The Reeve.Api process never resumes a TLS session: it runs with System.Net.Security.DisableTlsResume,
and the clients the host builds also turn resumption off in their own options
(constraint). A resumed session is
validated against the leaf cached in the session, not the one the server currently serves, and the
process-wide ticket cache passes it on, so a server that reloads a short-lived leaf at each renewal (such as
OpenBao) would be refused with NotTimeValid once the cached leaf expired. The runtime switch also covers
MQTTnet, plugins that open their own TLS and library clients. Each new connection costs a full handshake,
and inbound resumption in Kestrel is lost too, which matters little behind an ingress. A plugin workload
container or a test host is a different process and is not covered.
Certificate rejection alerts
A rejected server certificate raises tls.certificate_rejected. The report never blocks or alters the
verdict. The rejection text names only the chain status left after the operator's roots were tried, so a private
CA's PartialChain does not appear. Log lines are throttled to one per subsystem and host per interval,
while the alert is raised on every rejection; a container without an alert store only logs.
The alert is cleared by the next accepted handshake of the same subsystem to the same host, whatever issuer the accepted certificate names, and on every replica. The usual cause is a replaced certificate (a renewed leaf, a new intermediate), after which the old rejection describes nothing that still happens. A plugin instance is its own subsystem, so one instance's success never clears another's rejection.
Limits, stated plainly
A native plugin that constructs its own HTTP client bypasses the guard and the block log entirely. Such a call is neither blocked nor recorded. Containing it is an infrastructure concern (a Kubernetes network policy or an egress firewall), and interception in the application layer is deliberately not attempted, because a half-scoped version would create false confidence. The hard boundary for untrusted code is the sandboxed plugin lane; see plugin trust and the constraint.
Rules for contributors
- Register every new outbound HTTP client with the shared guarded handler. A bare client registration silently opts out of every egress control and out of the block log. A client that must reach in-cluster addresses, as the camera and media-plane clients do, disables redirects and is listed in known limitations.
- Do not add a redirect-following handler of your own; use the safe wrapper.
- Do not relax the connect-time check to make a test pass. Point the test at a documentation-range address or use the allowlist the same way an operator would.
Failure modes
| Symptom | Cause |
|---|---|
| An integration silently reaches nothing | A private or loopback target refused at connect time. Read the blocked-egress log. |
| A plugin cannot reach a service on the Reeve host's loopback | Loopback is always closed to plugins. Only an exact IpAddress entry of the allowlist opens it. |
| A plugin's HTTP calls bypass the deployment's HTTP proxy | The vended client never uses the system proxy, so the address check sees the real target. |
A plugin's OAuth step fails with oauth_token_endpoint_not_granted |
The token endpoint's host is not among the hosts the plugin requests. The plugin has to request it. |
| OIDC sign-in fails against an identity provider on the LAN | The back-channel refuses private addresses unless Authentication:Oidc:AllowPrivateMetadata is on or the provider's host is on the private-host list. Read the blocked-egress log for core:oidc. |
| A plugin cannot reach a LAN service under a fixed manifest name | Plugins:Egress:LanOnlyThroughOwnerAddresses is on. The address has to come from the owner, or the host has to be on the operator's private-host list. |
| One-click unblock refuses | The refusal was attributed to a plugin's host allowlist, or it was a scheme, credential or DNS refusal, none of which an operator allowlist can fix. |
| An allowlist entry with a port does not narrow anything | Private-host entries match host only; the port is ignored. |
| A redirect chain fails partway | The allowlist is re-checked at every hop; a later hop was not granted. |
A secret provider or broker fails with NotTimeValid after its certificate was renewed |
A client outside the Reeve.Api process resumed a TLS session against the old leaf. |
tls.certificate_rejected for a private-CA host |
The CA is not in Tls__TrustedCaCertificates, or the client sets its own validation and the list does not apply. |