Skip to content

Enforce provider opt-outs and legacy EID expiry on Fastly and Axum - #1626

Draft
prk-Jr wants to merge 1 commit into
feat/axum-identity-providersfrom
fix/1555-provider-eid-opt-outs
Draft

prk-Jr wants to merge 1 commit into
feat/axum-identity-providersfrom
fix/1555-provider-eid-opt-outs

Conversation

@prk-Jr

@prk-Jr prk-Jr commented Nov 18, 2026 •

Copy link
Copy Markdown
Collaborator

Stacked on #1566 (feat/axum-identity-providers), with the focused diff based on 3d62f4dd7efb1192a15be7da0011511b1ee316a7. The dependency order is #1488 → #1566 → this PR. #1566 currently conflicts with #1488. Keep this PR in draft until the dependency stack is refreshed and the resulting revisions are revalidated. Default Axum EC activation also remains blocked by its missing geolocation service; controlled application services verify the identity route behavior below.

Summary

  • Withhold ts-eids cookie and /auction body IDs from bidders while an enabled source owner has a remembered opt-out, across Fastly and Axum initial-page, direct and page-bids auctions.
  • Immediately stop serving legacy single-UID records while an enabled provider owns their source. Preserve unowned records and live provider-written IDs under their existing expiry rules.
  • Enforce opt-outs on accepted auctions even when browser classification suppresses normal identity access. These reads remain limited to policy checks; they do not enable identity generation, stored-ID enrichment, provider collection, KV writes or completeness-marker writes.

Changes

File Change
crates/trusted-server-adapter-axum/src/app.rs Supply the separate policy graph to initial-page, page-bids and direct auction handlers.
crates/trusted-server-adapter-axum/src/identity.rs Retain read-only auction policy access for requests with an unrecognized User-Agent, without widening identity lifecycle permissions.
crates/trusted-server-adapter-axum/src/identity_tests.rs Exercise unknown-browser cookie/body controls, a vendor response creating remembered opt-out state, repeated requests and legacy stored-row behavior through the real router.
crates/trusted-server-adapter-fastly/src/app.rs Retain equivalent policy access when browser signals are unavailable; preserve normal finalization and enrichment gates.
crates/trusted-server-core/src/auction/endpoints.rs Filter client EIDs using enabled ownership and the matching EC row's active opt-outs before bidder dispatch; preserve consent and degraded-read behavior.
crates/trusted-server-core/src/ec/admin.rs Explain provider opt-outs and legacy-record expiry in the stored auction preview.
crates/trusted-server-core/src/ec/eids.rs Withhold opted-out sources and legacy single-UID records in provider-owned sources during stored EID reads.
crates/trusted-server-core/src/ec/identify.rs Apply the same stored-record policy to partner identify responses.
crates/trusted-server-core/src/ec/mod.rs Carry a one-way policy-only restriction; keep policy snapshots outside ordinary finalization state.
crates/trusted-server-core/src/ec/pull_sync.rs Update the partner test fixture for ownership metadata.
crates/trusted-server-core/src/ec/registry.rs Retain enabled owner IDs per source and honor any active owner opt-out, with normalized lookup and exact expiry-boundary tests.
crates/trusted-server-core/src/publisher.rs Apply the shared client policy to initial-page and page-bids targeting; preserve admission gates, read counts and finalization behavior.
docs/guide/api-reference.md Correct Axum identify, batch-sync and EC diagnostic support descriptions.
docs/guide/axum-dev.md Describe the process-local store and native geolocation limitation, separating default-binary behavior from injected application services.
docs/guide/configuration.md Document remembered opt-outs, immediate legacy read-time expiry, supported adapters and accurate startup/consent behavior.
docs/superpowers/plans/2026-11-18-provider-eid-opt-outs.md Record implementation, adapter scope and verification tasks.
docs/superpowers/specs/2026-11-18-provider-eid-opt-outs-design.md Record ownership policy, compatibility, review decisions and runtime qualification limits.

Closes

Closes #1555

Spec

Bug fix; no configuration or persisted-schema changes.

Spec: Provider opt-out enforcement for client EIDs

Plan: Provider opt-out enforcement implementation plan

An opt-out applies only while its end time is greater than the request time and only for an enabled owner of that source. Client EIDs cannot clear it. Missing, failed or mismatched row snapshots retain existing degraded behavior. Legacy expiry occurs on reads, with no migration or invented timestamp; rollback can resume serving those legacy records. No-provider output and existing vendor/global consent gates remain covered.

Test plan

All local gates below passed for the source tree committed as ee7a11031. JavaScript tests used two workers with unchanged time limits. Final runtime artifacts omit debug symbols; tool versions remain pinned.

  • cargo test-fastly && cargo test-fastly-reuse && cargo test-axum && cargo test-cloudflare && cargo test-spin
  • All target-matched clippy aliases, including native CLI/codegen and native core build-digest lint.
  • cargo fmt --all -- --check
  • JS tests, build and format.
  • Docs and remaining Markdown format.
  • Native core build-digest tests, adapter parity and required HTML EOF tests/lints.
  • Fastly release WASM build and remaining adapter builds.
  • Axum/Fastly HTML EOF and auction runtime controls.
  • Deadline runtime fixtures, Wasm clock lint, changed-line URL-host lint, Node pin guard, documentation proposal checks and release producer checks.
  • Fresh Fastly WASM: 178 bidder-capture cases passed after real TOML strict validation and ts config push --adapter fastly --local: 88 cases on stock Viceroy and 90 on an explicitly synthetic TLS-fingerprint emulator. The latter includes two same-visitor provider-cookie opt-back-in controls. Controlled local backend mappings deliver requests to an owned bidder fixture. Cases cover initial-page/page-bids/direct auctions, cookie/body inputs, active/expired opt-outs, legacy/live/expired provider records, no-provider controls, repeated visitors and policy-only read/write preservation.
  • 18 controlled Axum socket cases passed using real TOML strict validation, ts config push --adapter axum --local, the documented envelope environment bridge, the actual settings loader and full application router. Explicit fixtures supply country DE and redirect ID5/PBS transport to owned local peers. An ID5 opt-out response creates stored memory; repeated same-visitor requests suppress forged IDs without retrying the provider, while unrelated IDs survive. Opt-back-in restores delivery, and a short-lived ConnectID demonstrates live-to-expired behavior.
  • The unchanged normal Axum executable was separately started through the same TOML/local-push/environment-bridge path and returned the publisher origin sentinel. Full normal-binary EC workflows remain blocked: its native geolocation service returns no country, leaving consent jurisdiction unknown and identity use denied even with a TC string. The controlled-service socket cases do not establish default-binary EC activation.

These are local controlled-runtime results. They do not establish live-vendor, deployed-edge or real-browser behavior. The draft remains subject to dependency refresh and the default Axum geolocation qualification above. Hosted CI is checked separately on the published revision.

Checklist

  • Bug fix; supporting spec and plan linked above.
  • Changes follow AGENTS.md conventions, with final checks completed.
  • No unwrap() added in production code.
  • Uses log macros.
  • New behavior has regression tests.
  • No secrets or credentials committed.

@prk-Jr prk-Jr self-assigned this Nov 18, 2026
@prk-Jr prk-Jr linked an issue Nov 18, 2026 that may be closed by this pull request
3 tasks
@prk-Jr prk-Jr changed the title Enforce provider opt-outs for client and legacy EIDs Enforce provider opt-outs and legacy EID expiry on Fastly and Axum Nov 18, 2026
@prk-Jr
prk-Jr changed the base branch from feat/s2s-eid-vendors to feat/axum-identity-providers November 18, 2026 15:19
@prk-Jr
prk-Jr force-pushed the fix/1555-provider-eid-opt-outs branch from 7ac8b5e to ee7a110 Compare November 18, 2026 15:19
@prk-Jr
prk-Jr added this pull request to stack #1629 November 18, 2026 16:25

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Client and browser EIDs for provider-owned sources after a provider opt-out

1 participant