Skip to content

ref(security): Stop accepting Expect-CT, HPKP, and Expect-Staple reports#6230

Draft
mrduncan wants to merge 1 commit into
masterfrom
ref/remove-expect-ct-hpkp-expect-staple-reports
Draft

ref(security): Stop accepting Expect-CT, HPKP, and Expect-Staple reports#6230
mrduncan wants to merge 1 commit into
masterfrom
ref/remove-expect-ct-hpkp-expect-staple-reports

Conversation

@mrduncan

@mrduncan mrduncan commented Jul 14, 2026

Copy link
Copy Markdown
Member

HPKP, Expect-CT, and Expect-Staple are dead in all shipping browsers, so these report types can no longer be produced. Relay now rejects them at ingest: the security report classifier no longer recognizes them, and the dedicated expect-ct-report / expect-staple-report content types are refused at the endpoint.

This is the ~simplest change so that we stop accepting these reports and keep this PR manageable. The remaining cleanup should be straightforward as a follow up.

Refs getsentry/sentry#119638

HPKP, Expect-CT, and Expect-Staple are dead in all shipping browsers, so these
report types can no longer be produced. Relay now rejects them at ingest: the
security report classifier no longer recognizes them, and the dedicated
expect-ct-report / expect-staple-report content types are refused at the endpoint.

The interface types, EventType variants, and Event fields are intentionally
retained for a later full-removal PR that coordinates with the Sentry backend.

Refs getsentry/sentry#119638
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

@jjbayer jjbayer 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.

Looks reasonable to me. We'll have to remove the sentry-side relay_integration tests in order for CI to pass.

@Dav1dde

Dav1dde commented Jul 15, 2026

Copy link
Copy Markdown
Member

This is the ~simplest change so that we stop accepting these reports and keep this PR manageable. The remaining cleanup should be straightforward as a follow up.

To fully stop ingestion we'll also have to remove it from the EventType enum and ideally also the fields on the Event schema:

    /// HPKP (security) reports.
    #[metastructure(pii = "true", legacy_alias = "sentry.interfaces.Hpkp")]
    #[metastructure(omit_from_schema)] // we only document error events for now
    pub hpkp: Annotated<Hpkp>,

    /// ExpectCT (security) reports.
    #[metastructure(pii = "true", legacy_alias = "sentry.interfaces.ExpectCT")]
    #[metastructure(omit_from_schema)] // we only document error events for now
    pub expectct: Annotated<ExpectCt>,

    /// ExpectStaple (security) reports.
    #[metastructure(pii = "true", legacy_alias = "sentry.interfaces.ExpectStaple")]
    #[metastructure(omit_from_schema)] // we only document error events for now
    pub expectstaple: Annotated<ExpectStaple>,

Can be done in a follow-up, but maybe easier to do it in one sweep. Without making these changes, outdated customer hosted Relays and custom clients can still send these reports.

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.

3 participants