GHSA-hx5x-49mm-vmhw SQL Injection in sails-mysql
Attackers can inject SQL via the sort parameter in sails-mysql, allowing arbitrary query execution and potential data access or modification.
- Exploited in the wild
- Not known
- Login needed
- Not stated
- Attackable
- Over the internet
- Victim action needed
- Not needed
- Fix
- Available
What is GHSA-hx5x-49mm-vmhw?
GHSA-hx5x-49mm-vmhw is a SQL injection vulnerability in sails-mysql, published on 3 Sep 2020. It can be exploited over the network, with no action from the victim.
Official description
Versions of sails-mysql prior to 0.10.8 are vulnerable to SQL Injection. The sort keyword is not properly sanitized and may allow attackers to inject SQL statements and execute arbitrary SQL queries
Recommendation
Upgrade to version 0.10.8 or later.
Which versions are affected by GHSA-hx5x-49mm-vmhw?
2 open source packages ship an affected version, including sails-mysql.
| Package | Affected | Fixed in |
|---|---|---|
sails-mysql npm | All versions | 0.10.8 |
sails-mysql npm | All versions | 0.10.8 |
How do I fix GHSA-hx5x-49mm-vmhw?
Upgrade sails-mysql to 0.10.8 or later.
Use parameterised queries everywhere and never build SQL by joining strings. Upgrade affected software first; a web application firewall only buys time. More about SQL injection.
Is GHSA-hx5x-49mm-vmhw being exploited?
There is no known exploitation of GHSA-hx5x-49mm-vmhw in the wild and no public exploit code.