Rucio SQL Injection Vulnerability in PostgreSQL Metadata Plugin

Vulnerability

A SQL injection vulnerability has been identified in Rucio versions 1.30.0 and later, prior to 35.8.5, 38.5.5, 39.4.2, and 40.1.1. The vulnerability exists in the 'FilterEngine.create_postgres_query()' function, allowing authenticated Rucio users to execute arbitrary SQL against the PostgreSQL metadata database. This exploitation occurs through the DID search endpoint ('GET /dids/<scope>/dids/search') when the 'postgres_meta' metadata plugin is active. Attacker-controlled filter keys and values are directly interpolated into SQL strings using Python's string format method, then processed by 'psycopg3' in a way that treats them as trusted SQL. Depending on the database privileges of the service account, this vulnerability could lead to unauthorized access to sensitive tables, modification or deletion of metadata, access to server-side files, or even code execution via PostgreSQL features like 'COPY ... FROM PROGRAM'.

Impact

Exploitation of this vulnerability allows for arbitrary SQL execution, with potential impacts including unauthorized data access, data modification, and remote code execution, particularly if the database user has elevated privileges.

Remediation

Users can upgrade to Rucio versions 35.8.5, 38.5.5, 39.4.2, or 40.1.1 to address this vulnerability.

Added: May 6, 2026, 6:26 PM
Updated: May 6, 2026, 6:26 PM

Vulnerability Rating

Custom Algorithm
spread
0.0
impact
10.0
exploitability
4.8
remediation
0.0
relevance
7.6
threat
0.0
urgency
2.9
incentive
0.0

Our algorithm analyzes dozens of metrics to generate these 8 key vulnerability categories, which are then combined to calculate the overall risk score.