Skip to content

fix(security): replace params.permit! with explicit param allowlist#392

Merged
natsuki615 merged 1 commit intomasterfrom
fix/brakeman-mass-assignment
Mar 6, 2026
Merged

fix(security): replace params.permit! with explicit param allowlist#392
natsuki615 merged 1 commit intomasterfrom
fix/brakeman-mass-assignment

Conversation

@merichar
Copy link
Copy Markdown
Member

@merichar merichar commented Mar 2, 2026

  • Fixes the one Brakeman mass assignment warning (medium confidence)
  • params.permit! in tools#index was used solely to build
    @json_url for AJAX pagination — not for model mass assignment
  • Replace with params.permit(:type, :page, :size) scoped to just
    the keys that actually appear in the URL

params.permit! in tools#index was used only to build a pagination
URL via url_for; replace with params.permit(:type, :page, :size)
to avoid allowing arbitrary params through
@natsuki615 natsuki615 merged commit 07416d0 into master Mar 6, 2026
1 check failed
@merichar merichar deleted the fix/brakeman-mass-assignment branch March 19, 2026 20:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants