Skip to content

Redact Sensitive Log at src/core/receive/v1/mod.rs:215 #911

Closed

Description

@0xZaddyy

This log exposes the previous_output field, which includes both a transaction ID (txid) and an output index (vout). These identifiers can be used to trace a user’s UTXO, linking transactions or leaking wallet structure. Even though it’s under a warn! level, this may appear in production logs and should be sanitized.

Activity

  1. zealsham commented on Jul 30, 2025

    @zealsham
    Collaborator

    This log entry is emitted when a previously seen input is detected, suggesting that the receiver already has the corresponding transaction information persisted in their database. I currently lack full visibility into the logging pipeline and how it's exposed, so my question is: who has access to these logs?

    My assumption is that any actor with sufficient access to observe this log likely operates within a privileged environment, and would therefore also have access to the underlying database, making the log itself redundant from a sensitivity standpoint — unless logs are being forwarded externally or processed in a less secure context.

  2. 0xZaddyy commented on Jul 30, 2025

    @0xZaddyy
    ContributorAuthor

    You're right this log usually appears in a privileged context where the receiver already has internal state (like a cache or DB), so looking at this way, the privacy risk seems low.
    But there are still good reasons to redact or limit it:

    • Logs can leak: They often end up in places they weren't meant to be making it possible for log aggregators to collect them, be in CI logs, or shared during support and debugging. That means someone without access to the internal DB could still see sensitive data.

    • txid:vout is a wallet fingerprint: Even if the receiver already knows it, logging it in plaintext makes it easier to link UTXOs on-chain and trace user behavior. That weakens Payjoin’s privacy guarantees.

  3. nothingmuch commented on Aug 3, 2025

    @nothingmuch
    Contributor

    Something to keep in mind is that at least my main motivation for opening #821 was so that we can have clear guidelines for what is safe vs. not safe for users to submit as part of bug reports. I think a good guideline is that all logs up to debug level should not require manual redaction in order to be safely shared (e.g. on a bug report) by either a user or wallet developer who might not fully understand the privacy implications.

    So to answer "who has access to these logs" - typically just the user, but potentially they might be made public on this repository, and we should aim to keep users' information safe if that were to happen.

    In specific cases where the information is insufficient and we can't replicate an issue, then we can request trace level logs and instruct on how to redact them or allow them to be submitted privately if the user chooses to.

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions