Skip to content

[TRIVIAL] Redact IPFS auth_token in debug#4325

Merged
jmg-duarte merged 2 commits intomainfrom
jmgd/fix/4310
Apr 10, 2026
Merged

[TRIVIAL] Redact IPFS auth_token in debug#4325
jmg-duarte merged 2 commits intomainfrom
jmgd/fix/4310

Conversation

@jmg-duarte
Copy link
Copy Markdown
Contributor

@jmg-duarte jmg-duarte commented Apr 10, 2026

Description

Fixes #4310

This fixes the leakage by redacting the IPFS secret in the Debug implementation.

Changes

  • Manually implement debug to redact IPFS token

How to test

Added a test to ensure it doesn't break without us noticing

@jmg-duarte jmg-duarte requested a review from a team as a code owner April 10, 2026 09:32
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request implements a manual Debug trait for IpfsConfig to redact the auth_token field and adds a corresponding test case. The review feedback highlights that the current implementation incorrectly redacts the token even when it is None, potentially leading to misleading debug logs. It is recommended to preserve the Option structure in the Debug output and update the tests to verify both the redacted token and the None case.

@jmg-duarte jmg-duarte added this pull request to the merge queue Apr 10, 2026
Merged via the queue into main with commit d0073a2 Apr 10, 2026
20 checks passed
@jmg-duarte jmg-duarte deleted the jmgd/fix/4310 branch April 10, 2026 10:03
@github-actions github-actions bot locked and limited conversation to collaborators Apr 10, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

bug: missing manual Debug impl for IpfsConfig in configs crate (secret leakage)

2 participants