Access Lists#

Access lists control who can reach a proxy host using IP-based allowlisting / blocklisting.

Creating an access list#

Edit Access List form with an allow rule for the documentation range 192.0.2.0/24

A saved example access list in the real Admin UI. The documentation range shown is illustrative; use your own client network.

The editor includes match modes and feeds on builds containing the access-list feeds feature.

  1. Open Security → Access Lists as an administrator
  2. Click + Add Access List
  3. Give the list a Name
  4. Choose Client identity or Connection source under Match
  5. Add Manual IP rules with Add Rule, or add a feed as described below
  6. Review the rules and click Create (or Save Changes when editing)

Which IP should the list match?#

MatchAddress checkedTypical use
Client identity (default)Verified visitor IP, honoring the server’s trusted proxiesOffice allowlists or visitor blocklists
Connection sourceImmediate socket peer, regardless of forwarded headersRestricting an origin to a CDN or WAF

Existing lists retain Client identity matching after upgrade. Configure Trusted Proxies on the host’s server when visitor rules need to work behind a proxy. Selecting Connection source does not change the visitor identity used for rate limits or forwarded headers.

Client rules (IP rules)#

Each manual rule has an address and a directive:

FieldDescription
AddressIPv4/IPv6 address or CIDR range (e.g. 10.0.0.0/8, 192.168.1.50)
Directiveallow or deny

Explicit deny rules are enforced first (those IPs are always blocked). If any allow rules are present, they form an allowlist: any client not in the allowlist receives 403 Forbidden.

A deny-only list allows addresses that do not match a deny rule. An empty list with no feed ranges allows all traffic. Reordering rules does not override deny precedence. Feed ranges and manual rules participate in the same policy.

Provider presets and URL feeds#

Feeds populate a list with ranges from an external source while keeping manual rules separate. Only administrators can change lists or feeds.

Access List editor using Connection source and an unsaved Cloudflare allow feed

Unsaved Cloudflare origin-access example showing the range count, as-of date, preset controls and URL feed input.

Add from preset#

Under Feeds → Add from preset, choose Cloudflare, AWS CloudFront, Google Cloud or Fastly. Click Use snapshot for a provider with a shipped snapshot, or Refresh from source to fetch its current published list. Providers marked refresh only have no offline snapshot. Presets add allow ranges; select Connection source when using them to restrict origin access.

Add from URL#

Under Add from URL, enter an HTTPS URL, choose Allow or Deny, then click Preview URL. The endpoint must return plain-text CIDRs, one per line; blank lines and # comments are supported. For example:

# Example partner network; replace with your actual ranges.
192.0.2.0/24
2001:db8::/32

The controller refuses private/internal destinations and redirects to them. Redirects must remain HTTPS. Invalid CIDRs, all-address /0 ranges and feeds over 10,000 ranges are rejected.

Review and maintain feeds#

Each feed shows its source, directive, range count and as of date. Adding a feed or clicking Refresh previews its ranges; a refresh of a saved feed also shows counts added and removed. Click Create or Save Changes to persist the preview. Cancel discards unsaved changes.

Refreshing replaces only that feed’s ranges and preserves manual rules and other feeds. Remove removes that feed and its ranges when you save. There is no automatic refresh: a stale feed keeps its saved ranges, and a failed fetch does not remove the saved rules. Review dates and changes regularly.

Removing the last allow rule or allow feed leaves a deny-only policy, or an empty policy that permits all traffic. Review the effective rules before saving.

Example: restrict an origin to Cloudflare#

  1. Create a list with Connection source matching.
  2. Add the Cloudflare preset as an allow feed and review its ranges/date.
  3. Acknowledge I understand this allow list denies every other connection and save. Incomplete ranges can block legitimate CDN traffic.
  4. Assign the list to the proxy host and confirm configuration application.
  5. Separately configure Cloudflare under Security → Trusted Proxies for the host’s server to recover the visitor IP for rate limits and forwarding.
  6. Verify that traffic through the intended CDN succeeds and a direct request from outside the allowed ranges receives 403 Forbidden.

A host uses one list and one match mode; this does not combine separate visitor and peer policies on a single host. A CDN network allowlist also does not identify your provider account. Retain origin TLS and the origin protections described in Security Hardening.

Example: allow internal network only#

Use Client identity matching for visitor-network restrictions:

AddressDirective
10.0.0.0/8allow
172.16.0.0/12allow
192.168.0.0/16allow

With these allow rules, any address outside the listed ranges is denied.

Assigning an access list to a proxy host#

  1. Open the Add/Edit Proxy Host modal
  2. Select the access list from the Access List dropdown on the basic host form, or on the SSL tab

A proxy host can only be assigned one access list at a time. Access lists can be reused across multiple proxy hosts.

How it works in Caddy#

Client identity uses Caddy client_ip matchers. Connection source uses remote_ip matchers. Denied requests receive a 403 Forbidden response before reaching the upstream. Deny rules run first. Any allow rule turns the list into an allowlist that denies everyone else. Feed ranges use the feed’s own allow or deny directive.

Notes#

  • Client identity uses the verified visitor address. With no trusted proxy, that is the immediate connection peer. Behind a proxy, set the per-server ranges on the Trusted Proxies page under Security. Management POSTERNPROXY_TRUSTED_PROXIES remains separate.
  • Deleting an access list assigned to one or more proxy hosts will succeed — the database clears the host association (ON DELETE SET NULL) and reconciliation removes the restriction. Review affected hosts before deleting a list.

Not yet available#

HTTP Basic Authentication (username/password protection) on access lists is planned but not yet implemented; access lists currently enforce IP rules only.

PosternProxyQuick start →