Skip to content

feat(policy): permit a pinned private endpoint for policy egress - #1260

Merged
shaneutt merged 1 commit into
praxis-proxy:mainfrom
hexfusion:feat/policy-egress-pinned-endpoints
Sep 25, 2026
Merged

shaneutt merged 1 commit into
praxis-proxy:mainfrom
hexfusion:feat/policy-egress-pinned-endpoints

Conversation

@hexfusion

@hexfusion hexfusion commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

What does this PR do?

Adds a per-target private-endpoint allowlist to the policy filter's outbound HTTP transport.

Policy egress refuses a callout that resolves only to non-public addresses (#1127). The one override, allow_private_idp, opens the whole policy callout pool to private space. This adds a narrower alternative: a trusted_private_endpoints list on the policy filter. A callout gets a private or loopback address only when its target host matches an entry; every other callout stays public-only, so the guard is narrowed per-target, not disabled.

A matched host is still refuses a link-local address, so a pin cannot reach cloud metadata. The link-local test reads the reason from ppe-core private_address_reason rather than re-deriving it, so the IPv4-mapped and NAT64 embedded IPv6 forms stay covered. allow_private_idp is unchanged and remains the coarse escape hatch.

This is the address-guard axis of reaching a cluster-internal policy IdP. It composes with #1157 (CA and client-certificate trust): #1157 makes the endpoint's certificate verifiable, this makes its address reachable at all. It is separate from #1156, which is cert verification for an IP-literal target (IP-SAN); this change gates on a DNS host name and does no certificate verification. Concrete consumer: the api-key resolver in praxis-proxy/policy#125, whose HTTP backend validates against a cluster-internal maas-api key-validation URL.

Which issue(s) does this relate to?

Fixes #1259

Relates to #1157 (composes with it) and #1127. Separate from #1156 (IP-SAN).

Checklist

  • Signed off all commits (git commit -s)
  • Tests added or updated
  • Documentation updated (if applicable)
  • make lint && make test && make test-integration passes locally

Does this introduce a breaking change?

No. trusted_private_endpoints defaults to empty, so existing configs behave exactly as before.

@hexfusion
hexfusion requested review from a team September 24, 2026 16:30
@hexfusion
hexfusion requested a review from shaneutt as a code owner September 24, 2026 16:30
@shaneutt shaneutt self-assigned this Sep 24, 2026
@shaneutt shaneutt added this to the v0.8.0 milestone Sep 24, 2026
@shaneutt shaneutt moved this to Review in Core Proxy Sep 24, 2026
shaneutt
shaneutt previously approved these changes Sep 25, 2026

@shaneutt shaneutt left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All my comments are pretty minor. Once they are resolved, 👍

Comment thread docs/filters/http/security/policy.md Resolved
Policy egress refuses a callout that resolves only to non-public
addresses; the one override, allow_private_idp, opens the whole callout
pool to private space. Add a trusted_private_endpoints allowlist on the
policy filter so a single in-cluster host can be reached at a private
address while every other callout stays public-only.

A matched host is still refused a link-local address, classified via
ppe-core's private_address_reason rather than re-derived, so the
IPv4-mapped and NAT64 embedded IPv6 forms stay covered. allow_private_idp
is unchanged.

Signed-off-by: Sam Batschelet <sbatsche@redhat.com>
@shaneutt
shaneutt merged commit ef05370 into praxis-proxy:main Sep 25, 2026
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

policy: permit a pinned private endpoint for policy egress

2 participants