fix: harden setup.sh credential handling (security + robustness)#33
fix: harden setup.sh credential handling (security + robustness)#33marcusquinn merged 1 commit intomainfrom
Conversation
Address all 3 medium-severity findings from Gemini review on PR #25: 1. Mask sensitive input: use read -rs for API Key and Application ID to prevent shoulder-surfing and terminal log exposure. Show only last 4 chars of existing values as hints (****XXXX). 2. Eliminate file permission race condition: use umask 077 in a subshell when writing credentials.json so the file is created with 600 permissions atomically, instead of creating with default perms then chmod after. 3. Prefer jq for JSON parsing: use jq when available for robust credential file reading, with grep/sed fallback and a warning when jq is not installed. Closes #32
|
Warning You have reached your daily quota limit. Please wait up to 24 hours and I will start processing your requests again! |
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
✨ Finishing Touches🧪 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 |
|
|
This PR appears orphaned — no active worker process found and no activity for 6+ hours. The linked issue is already closed. Flagging for review. If work is still in progress, remove the |
|
@coderabbitai review |
✅ Actions performedReview triggered.
|



Summary
Addresses all 3 medium-severity findings from Gemini code review on PR #25 (
setup.sh).read -rs(silent mode) to prevent shoulder-surfing and terminal scrollback exposure. Existing values show only last 4 chars as masked hints (****XXXX) instead of the full credential.umask 077subshell, so it's created with 600 permissions atomically — no window where the file exists with default (644) permissions.jqwhen available for robust credential file reading, withgrep/sedfallback and a warning whenjqis not installed. Consistent withjqusage elsewhere in the script.Verification
Closes #32