π‘οΈ Sentinel: [CRITICAL] Fix TOTP privilege escalation#363
π‘οΈ Sentinel: [CRITICAL] Fix TOTP privilege escalation#363arumes31 wants to merge 3 commits into
Conversation
Co-authored-by: arumes31 <114224498+arumes31@users.noreply.github.com>
|
π Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a π emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the βοΈ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
β¨ 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 |
π¨ Severity: CRITICAL π‘ Vulnerability: Privilege Escalation (CWE-269) - Missing authorization checks in `ChangeAdminTOTP` and `GetQR` handlers allowed any user with `manage_admins` permission to reset or retrieve the TOTP secret of the main system admin (`GUIAdmin`). Additionally, fixed Go standard library CVEs by updating the Go toolchain to 1.26.5 and patched an infinite loop vulnerability in `golang.org/x/text`. π― Impact: Account takeover of the primary system administrative account, potentially leading to full system compromise. Unpatched CVEs exposed the application to potential denial of service via standard library or text manipulation. π§ Fix: Implemented strict authorization checks in both handlers to return a `403 Forbidden` if the target username matches the configured `GUIAdmin`. Upgraded `golang.org/x/text` and Go toolchain version in `go.mod`, `Dockerfile`, and GitHub Action workflows. β Verification: Tested locally via `go test -short ./...` and manual review of the handler logic. Also verified the fix passes `govulncheck`. Co-authored-by: arumes31 <114224498+arumes31@users.noreply.github.com>
π¨ Severity: CRITICAL π‘ Vulnerability: Privilege Escalation (CWE-269) - Missing authorization checks in `ChangeAdminTOTP` and `GetQR` handlers allowed any user with `manage_admins` permission to reset or retrieve the TOTP secret of the main system admin (`GUIAdmin`). Additionally, fixed Go standard library CVEs by updating the Go toolchain to 1.26.5 across the repository (including Dockerfile and CI configurations) and patched an infinite loop vulnerability in `golang.org/x/text`. π― Impact: Account takeover of the primary system administrative account, potentially leading to full system compromise. Unpatched CVEs exposed the application to potential denial of service via standard library or text manipulation, which also caused CI pipeline failures during govulncheck scans. π§ Fix: Implemented strict authorization checks in both handlers to return a `403 Forbidden` if the target username matches the configured `GUIAdmin`. Upgraded `golang.org/x/text` and Go toolchain version (to 1.26.5) in `go.mod`, `Dockerfile`, and GitHub Action workflows to resolve CI issues. β Verification: Tested locally via `go test -short ./...` and manual review of the handler logic. Also verified the fix passes `govulncheck`. Co-authored-by: arumes31 <114224498+arumes31@users.noreply.github.com>
π¨ Severity: CRITICAL
π‘ Vulnerability: Privilege Escalation (CWE-269) - Missing authorization checks in
ChangeAdminTOTPandGetQRhandlers allowed any user withmanage_adminspermission to reset or retrieve the TOTP secret of the main system admin (GUIAdmin).π― Impact: Account takeover of the primary system administrative account, potentially leading to full system compromise.
π§ Fix: Implemented strict authorization checks in both handlers to return a
403 Forbiddenif the target username matches the configuredGUIAdmin.β Verification: Tested locally via
go test ./...and manual review of the handler logic.PR created automatically by Jules for task 226371566722958546 started by @arumes31