Skip to content

fix(logging): preserve redaction on telemetry fallback and recurse JSON body redaction - #342

Draft
tbarbugli wants to merge 1 commit into
mainfrom
tommaso/sec-2524-log-redaction
Draft

tbarbugli wants to merge 1 commit into
mainfrom
tommaso/sec-2524-log-redaction

Conversation

@tbarbugli

@tbarbugli tbarbugli commented Nov 24, 2026 •

Copy link
Copy Markdown
Member

Linear: SEC-2524

Summary

  • Capture the redacted payload before json.dumps in telemetry.safe_dump so fallback stringification preserves redaction when a payload contains non-JSON-serializable values (such as datetime), and match configured REDACT_KEYS across compound key names.
  • Make redact_json_body in getstream/logging_utils.py recurse into nested dicts and lists and redact common sensitive field patterns.
  • Add unit tests in tests/test_logging.py.

Testing

  • make lint && make test (ruff check/format clean, 538 pytest unit tests passing)

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.

1 participant