Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection')
CVE-2022-35942
Summary
Improper input validation on the "contains" loopback filter may allow for arbitrary SQL Injection. When the extended filter property "contains" is permitted to be interpreted by the Postgres connector, it is possible to inject arbitrary SQL, which may affect the confidentiality and integrity of data stored on the connected database. This affects users who do any of the following: - Connect to the database via the DataSource with the "allowExtendedProperties: true" setting OR - Use the connector's CRUD methods directly OR - Use the connector's other methods to interpret the loopback filter. Users who are unable to upgrade should do the following if applicable: Remove the "allowExtendedProperties: true" DataSource setting and add the "allowExtendedProperties: false" DataSource setting. When passing directly to the connector functions, manually sanitize the user input for the "contains" loopback filter beforehand. This vulnerability affects loopback-connector-postgresql versions prior to 5.5.1.
- LOW
- NETWORK
- HIGH
- CHANGED
- NONE
- NONE
- HIGH
- HIGH
CWE-89 - SQL Injection
Structured Query Language (SQL) injection attacks are one of the most common types of vulnerabilities. They exploit weaknesses in vulnerable applications to gain unauthorized access to backend databases. This often occurs when an attacker enters unexpected SQL syntax in an input field. The resulting SQL statement behaves in the background in an unintended manner, which allows the possibility of unauthorized data retrieval, data modification, execution of database administration operations, and execution of commands on the operating system.
References
Advisory Timeline
- Published