CVE-2019-7164

SQLAlchemy through 1.2.17 and 1.3.x through 1.3.0b2 allows SQL Injection via the order_by parameter

published February 20, 2019

CVSS
—
EPSS
4%
Percentile
89.2
In the wild
Unconfirmed
What it is

⚠️ An attacker can manipulate the order_by parameter to execute SQL queries they choose! This sneaky SQL injection in SQLAlchemy affects versions up to 1.3.0b2. 🔥 Think of it like a restaurant's menu — a mischievous diner could change their order to something completely off-menu if the waiter doesn't check the request carefully. If the system blindly accepts the input, it’s serving up more than just spaghetti! This vulnerability could allow an attacker to query or modify the database in ways they shouldn't be able to, leading to unauthorized data access or even data corruption. It's like letting someone in the kitchen who has no business cooking!

Put simply

Think of it like a restaurant's menu — a mischievous diner could change their order to something completely off-menu if the waiter doesn't check the request carefully. If the system blindly accepts the input, it’s serving up more than just spaghetti! The SQL injection vulnerability in SQLAlchemy arises when the order_by parameter is not properly validated, allowing for malicious SQL commands to be executed alongside legitimate requests.

What to do

This vulnerability could allow an attacker to query or modify the database in ways they shouldn't be able to, leading to unauthorized data access or even data corruption. It's like letting someone in the kitchen who has no business cooking! To mitigate this risk, developers should update SQLAlchemy to at least version 1.3.1, where the issue is addressed. Also, ensure to employ prepared statements and validate inputs wherever possible to guard against SQL injections. You've got this! By following these steps, you'll keep your application safe and sound. 🛡️

The record
Technical detail
CVSS
Not scored
CVSS v4.0
Not supplied
EPSS
0.03525 · 89.2th percentile
Published
2019-02-20T00:00Z
EPSS history
Timeline
  • 20 FEB 00:00Z
    SQLAlchemy through 1.2.17 and 1.3.x through 1.3.0b2 allows SQL Injection via the order_by parameter
    cvelistv5