Skip to content

prevent sensitive header value being logged#289

Open
daddykotex wants to merge 1 commit intopython-hyper:masterfrom
daddykotex:dfrancoeur/sensitive-headers
Open

prevent sensitive header value being logged#289
daddykotex wants to merge 1 commit intopython-hyper:masterfrom
daddykotex:dfrancoeur/sensitive-headers

Conversation

@daddykotex
Copy link

@daddykotex daddykotex commented Mar 13, 2026

See #288


When sensitive is True, the header value will be redacted in debug logs
and logged as "SENSITIVE_REDACTED" to prevent accidental exposure of
sensitive information.
Copy link
Member

Choose a reason for hiding this comment

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

Please mention that this flag has a specific meaning also in the RFC. Currently an unaware user might read this sentence and assume this setting is only for logging - while in fact it has a more specific meaning on the protocol level as well.

Copy link
Author

Choose a reason for hiding this comment

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

re-written as:

        When sensitive is True, the header will not be added to the header table,
        furthermore, the header value will be redacted in debug logs, as "SENSITIVE_REDACTED",
        to prevent accidental exposure of sensitive information.

@Kriechi
Copy link
Member

Kriechi commented Mar 14, 2026

Would you mind adding a changelog entry and tests to cover the new behaviour? Thanks!

@daddykotex daddykotex force-pushed the dfrancoeur/sensitive-headers branch from 63513fa to b7a31bc Compare March 14, 2026 18:27
@daddykotex daddykotex force-pushed the dfrancoeur/sensitive-headers branch from b7a31bc to 6b99d12 Compare March 14, 2026 18:34
@daddykotex
Copy link
Author

Would you mind adding a changelog entry and tests to cover the new behaviour? Thanks!

Done!

@daddykotex daddykotex marked this pull request as ready for review March 14, 2026 18:35
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.

2 participants