fix: resolve open CodeQL security alerts - #9505
Conversation
- adapter/oauth.py: stop logging request headers on user-info fetch failure; they carry the Bearer access token (py/clear-text-logging-sensitive-data) - adapter/base.py: drop the email value from the invalid-email warning log (py/clear-text-logging-sensitive-data) - provider/oauth/github.py: stop logging organization id / user login on org-membership failure (py/clear-text-logging-sensitive-data) - editor custom-link: rewrite the C0-control strip regex with escaped, non-overlapping ranges instead of raw control bytes overlapping \s (js/overly-large-range); also fixes the file being detected as binary
|
React Doctor found no issues. 🎉
|
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
📝 WalkthroughWalkthroughAuthentication logs now omit sensitive and identifying values. Custom-link URL normalization uses explicit escaped control-character ranges before dangerous-protocol detection. ChangesAuthentication logging updates
Custom-link URL normalization
Estimated code review effort: 2 (Simple) | ~10 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches 💡 1📝 Generate docstrings 💡
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Summary
Fixes all 4 open CodeQL code-scanning alerts:
py/clear-text-logging-sensitive-data): stopped logging request headers when the user-info fetch fails — the headers carry the Bearer access token, so every OAuth failure was writing a live token to the logs.py/clear-text-logging-sensitive-data): dropped the email value from the invalid-email warning log.py/clear-text-logging-sensitive-data): stopped logging the organization id / user login on org-membership failure.js/overly-large-range): the C0-control strip regex was written with raw 0x00/0x1F bytes, producing a range that overlaps\s. Rewritten with escaped, non-overlapping ranges covering exactly the C0 controls not already matched by\s(tab/CR/LF etc. are covered by\sitself). This also fixes the file being detected as binary data instead of UTF-8 text.Verification
oxlint(0 warnings/errors) andoxfmt --checkpass on the changed file; pre-commit hooks ran clean.py_compileandruff checkpass on all three Python files.Summary by CodeRabbit
Security & Privacy
Bug Fixes