Project

General

Profile

Actions

Refactor #23300

closed

Do not use string interpolation when composing SQL queries.

Added by Martin Povolny about 6 years ago. Updated over 2 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
Rails
Target version:
-
Difficulty:
Triaged:
No
Fixed in Releases:
Found in Releases:

Description

Using string interpolation when composing SQL queries is just one step away from creating a security issue. It's against the Rails best practices to do so. Doing so actually results into Brakeman complaining loudly.

Task: replace string interpolation with use of parameterization of queries and/or AREL.


Related issues 5 (0 open5 closed)

Related to Foreman - Tracker #21834: Rails 5.2 upgrade tasksClosed

Actions
Related to Foreman - Refactor #23234: remove friendly_id <5.0 workaroundsClosedTomer BriskerActions
Related to Foreman - Tracker #24837: Rails 6.0 TrackerClosed

Actions
Related to Foreman - Refactor #29520: Wrap sql in Arel.sql() where neededClosedActions
Blocks Foreman - Tracker #28570: Rails 6.1 TrackerClosed

Actions
Actions

Also available in: Atom PDF