Skip to content

Security: Prevent account takeover via users#updated_ajax by unifying target-user lookup and authorization#1185

Merged
texpert merged 2 commits into
masterfrom
fix/vulnerability-account-takeover-updated-ajax
Jun 1, 2026
Merged

Security: Prevent account takeover via users#updated_ajax by unifying target-user lookup and authorization#1185
texpert merged 2 commits into
masterfrom
fix/vulnerability-account-takeover-updated-ajax

Conversation

@texpert

@texpert texpert commented May 31, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Fixes an authorization bypass in Admin::UsersController#updated_ajax by resolving the target user from a single canonical param (user_id_param) in both validate_role and the action, so authorization is applied to the actual record being modified.

Changes

  • Use user_id_param consistently in validate_role and updated_ajax.
  • Add request spec that reproduces the bypass attempt and asserts it is denied.

Impact

  • No public API changes. Legitimate self-password updates behave the same; session/token handling is unchanged by this PR.

Acknowledgements

  • Reported by Lukman Azri.

…ller#updated_ajax

Co-authored-by: Junie <junie@jetbrains.com>
@texpert texpert changed the title Fix: Prevent account takeover via updated_ajax (auth token/session handling) Security: Prevent account takeover via users#updated_ajax (session & auth token handling) May 31, 2026
… and thanks [skip ci]

Co-authored-by: Junie <junie@jetbrains.com>
@texpert texpert self-assigned this May 31, 2026
@texpert texpert changed the title Security: Prevent account takeover via users#updated_ajax (session & auth token handling) Security: Prevent account takeover via users#updated_ajax by unifying target-user lookup and authorization May 31, 2026
@texpert texpert requested review from brian-kephart and owen2345 May 31, 2026 22:20
@texpert texpert merged commit 2634503 into master Jun 1, 2026
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