CVE-2026-142187: GORM SQL Injection
Published 2026-12-02 · Updated 2026-12-04 · Source disclosure@vulncheck.com
Not known to be exploited · medium severity — apply the vendor fix or mitigation on your normal schedule.
What to do
- The advisory lists versions through 1.31.2 as affected and does not name a fixed release. Check the references below for a newer version of GORM or a vendor mitigation.
- Until it is patched, do not leave GORM reachable from the internet or other untrusted networks; restrict access by firewall, VPN or allow-list.
- Put WAF rules in front of the affected parameters, and make sure the application's database account holds only the privileges it needs.
Affected and fixed versions
| Product | Affected | Fixed in |
|---|---|---|
| GORM | ≤ 1.31.2 | Not stated in the advisory |
Derived by HackerFeeds from the advisory text, CVSS vector and weakness class. Confirm versions against the vendor advisory before acting.
How it can be exploited
It can be exploited remotely over the network; the attacker does not need an account, and no action by a victim is required. Attack complexity is high, so exploitation depends on conditions the attacker does not control. The impact on confidentiality is rated high, and on integrity low.
| Attack vector | Network | It can be exploited remotely over the network. |
|---|---|---|
| Attack complexity | High | Success depends on conditions outside the attacker's control. |
| Privileges required | None | The attacker does not need an account. |
| User interaction | None | No action by a victim is needed. |
| Confidentiality | High | Total loss of confidentiality. |
| Integrity | Low | Partial loss of integrity. |
| Availability | None | No effect on availability. |
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:L/A:N
Weakness: SQL Injection
Attacker-controlled input changes the structure of a database query, which can expose, modify or delete data and sometimes leads to code execution on the database host.
Classified as CWE-89.
Description
GORM through 1.31.2 contains an sql injection vulnerability in Migrator.CreateView that allows attackers to inject SQL by supplying bound subquery values containing backslashes. Because logger.ExplainSQL inlines values without escaping backslashes, a backslash-quote sequence terminates the literal early, letting attackers alter view definitions to expose columns like password hashes.
Advisory text as published in the NVD record.