Vulnerabilities in pkg:pypi/DIRAC

PACKAGE
Advisory Summary

GHSA-7xw9-549r-8jrc is a HIGH (CVSS 8.5) sql injection vulnerability (CWE-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection')) affecting DIRAC libraries in the PyPI ecosystem. The issue involves sql injection and lack of access control in pilotmanager service. Remediation is available by upgrading affected packages to version 8.0.79, 9.0.22, 9.1.10.

6 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:pypi/DIRAC

6 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:pypi/DIRAC. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-7xw9-549r-8jrc - HIGH DIRAC: SQL injection and lack of access control in PilotManager service
GHSA-vg99-gr89-qhw9 CVE-2026-61668 HIGH DIRAC: Pilot code downloaded over unverified HTTPS connection
GHSA-m4m7-4cw8-62j6 CVE-2026-61667 CRITICAL DIRAC is vulnerable to RCE in FileCatalog DatasetManager via SQL injection + eval
GHSA-9jpv-c7p4-997x CVE-2026-45579 CRITICAL DIRAC is vulnerable to RCE in RequestManager due to eval on untrusted input
GHSA-v6f3-gh5h-mqwx CVE-2024-29905 HIGH DIRAC: Unauthorized users can read proxy contents during generation
GHSA-59qj-jcjv-662j CVE-2024-24825 CRITICAL DIRAC's TokenManager does not check permissions on cached tokens

GHSA-7xw9-549r-8jrc at a Glance

CVE Identifier N/A
GHSA Identifier GHSA-7xw9-549r-8jrc
Severity HIGH
CVSS v3.1 Base Score 8.5
CWE Classification CWE-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection')
Affected Product DIRAC
Package Ecosystem PyPI
Published Date
Last Updated

Security Impact

CVSS: 8.5

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:H/A:N).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Changed (S:C)
Confidentiality Low (C:L)
Integrity High (I:H)
Availability None (A:N)

How to Fix GHSA-7xw9-549r-8jrc

To remediate this vulnerability, upgrade all affected DIRAC dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

DIRAC fixed: 8.0.79
pip install DIRAC>=8.0.79
DIRAC fixed: 9.0.22
pip install DIRAC>=9.0.22
DIRAC fixed: 9.1.10
pip install DIRAC>=9.1.10
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

pip show DIRAC

How to Check if You Are Affected

To determine whether your Python environment is affected by GHSA-7xw9-549r-8jrc, inspect your installed packages using pip:

pip show DIRAC

Analyze the terminal output to locate any version of DIRAC in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 8.0.79), your application is affected.

Note: The pip show DIRAC command checks currently installed packages in your active Python environment.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection'), where the product constructs all or part of an sql command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended sql command when it is sent to a downstream component. without sufficient removal or quoting of sql syntax in user-controllable inputs, the generated sql query can cause those inputs to be interpreted as sql instead of ordinary user data. In DIRAC, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Details A number of the functions in PilotManager pass parameters directly through to the database layer, which then does not do any escaping on the parameters. For example setPilotStatus: https://github.com/DIRACGrid/DIRAC/blob/1738e7c6d2f31d26f1364255d9d2e87b4896c922/src/DIRAC/WorkloadManagementSystem/Service/PilotManagerHandler.py#L343-L349 https://github.com/DIRACGrid/DIRAC/blob/1738e7c6d2f31d26f1364255d9d2e87b4896c922/src/DIRAC/WorkloadManagementSystem/DB/PilotAgentsDB.py#L117 This won't accept multiple statements separated by a semicolon, but a carefully crafted set of parameters containing SQL escapes would likely be able to change or return other database entries. Further to this, the PilotManager access control is only set to "authenticated"; this allows these functions to be called by any user. This allows any user to manage (e.g. delete, read output of) any pilot pilot job: https://github.com/DIRACGrid/DIRAC/blob/1738e7c6d2f31d26f1364255d9d2e87b4896c922/src/DIRAC/WorkloadManagementSystem/ConfigTemplate.cfg#L111-L118 This is fixed by changing the SQL statements to use proper parameter substitution and providing a suitable set of access rules for the exported pilot management functions. ### Patched versions: https://pypi.org/project/DIRAC/8.0.79/ https://pypi.org/project/DIRAC/9.0.22/ https://pypi.org/project/DIRAC/9.1.10/

GHSA-7xw9-549r-8jrc Affected DIRAC Versions

3 component(s)
Fixed Versions:
8.0.799.0.229.1.10
Product / Package Ecosystem Affected Versions Fixed Version
DIRAC
PyPI
≥ 6
< 8.0.79
8.0.79
DIRAC
PyPI
≥ 8.1.0a1
< 9.0.22
9.0.22
DIRAC
PyPI
≥ 9.1.0
< 9.1.10
9.1.10

References

Frequently Asked Questions

What is GHSA-7xw9-549r-8jrc?
GHSA-7xw9-549r-8jrc is a security vulnerability in DIRAC involving SQL injection and lack of access control in PilotManager service under CWE-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection').
Which DIRAC versions are affected?
Affected versions include releases prior to 8.0.79, 9.0.22, 9.1.10 across affected packages: DIRAC.
What version fixes GHSA-7xw9-549r-8jrc?
Upgrading to 8.0.79, 9.0.22, 9.1.10 (or the latest patched release for your respective branch) resolves the vulnerability.
Is DIRAC affected?
Yes, DIRAC is affected in releases prior to 8.0.79, 9.0.22, 9.1.10. Upgrade your dependency to 8.0.79, 9.0.22, 9.1.10 or later.
What is the CVSS score of GHSA-7xw9-549r-8jrc?
GHSA-7xw9-549r-8jrc has a CVSS v3.1 base score of 8.5 (HIGH) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:H/A:N.
What CWE is associated with GHSA-7xw9-549r-8jrc?
GHSA-7xw9-549r-8jrc is classified under CWE-89: Improper Neutralization of Special Elements used in an SQL Command ('SQL Injection') (The product constructs all or part of an SQL command using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the intended SQL command when it is sent to a downstream component. Without sufficient removal or quoting of SQL syntax in user-controllable inputs, the generated SQL query can cause those inputs to be interpreted as SQL instead of ordinary user data.).
How can I check PyPI dependencies for GHSA-7xw9-549r-8jrc?
Run the dependency tree command: 'pip show DIRAC'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-7xw9-549r-8jrc",
  "modified" : "2026-07-13T18:38:13Z",
  "published" : "2026-07-13T18:38:13Z",
  "aliases" : [ ],
  "summary" : "DIRAC: SQL injection and lack of access control in PilotManager service",
  "details" : "### Details\nA number of the functions in PilotManager pass parameters directly through to the database layer, which then does not do any escaping on the parameters. For example setPilotStatus:\nhttps://github.com/DIRACGrid/DIRAC/blob/1738e7c6d2f31d26f1364255d9d2e87b4896c922/src/DIRAC/WorkloadManagementSystem/Service/PilotManagerHandler.py#L343-L349\n\nhttps://github.com/DIRACGrid/DIRAC/blob/1738e7c6d2f31d26f1364255d9d2e87b4896c922/src/DIRAC/WorkloadManagementSystem/DB/PilotAgentsDB.py#L117\n\nThis won't accept multiple statements separated by a semicolon, but a carefully crafted set of parameters containing SQL escapes would likely be able to change or return other database entries.\n\nFurther to this, the PilotManager access control is only set to \"authenticated\"; this allows these functions to be called by any user. This allows any user to manage (e.g. delete, read output of) any pilot pilot job:\nhttps://github.com/DIRACGrid/DIRAC/blob/1738e7c6d2f31d26f1364255d9d2e87b4896c922/src/DIRAC/WorkloadManagementSystem/ConfigTemplate.cfg#L111-L118\n\nThis is fixed by changing the SQL statements to use proper parameter substitution and providing a suitable set of access rules for the exported pilot management functions.\n\n### Patched versions:\nhttps://pypi.org/project/DIRAC/8.0.79/\nhttps://pypi.org/project/DIRAC/9.0.22/\nhttps://pypi.org/project/DIRAC/9.1.10/",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:H/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "DIRAC"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "6"
      }, {
        "fixed" : "8.0.79"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "DIRAC"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "8.1.0a1"
      }, {
        "fixed" : "9.0.22"
      } ]
    } ]
  }, {
    "package" : {
      "ecosystem" : "PyPI",
      "name" : "DIRAC"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "9.1.0"
      }, {
        "fixed" : "9.1.10"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/DIRACGrid/DIRAC/security/advisories/GHSA-7xw9-549r-8jrc"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/DIRACGrid/DIRAC"
  }, {
    "type" : "WEB",
    "url" : "https://pypi.org/project/DIRAC/8.0.79"
  }, {
    "type" : "WEB",
    "url" : "https://pypi.org/project/DIRAC/9.0.22"
  }, {
    "type" : "WEB",
    "url" : "https://pypi.org/project/DIRAC/9.1.10"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-284", "CWE-89" ],
    "severity" : "HIGH",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-07-13T18:38:13Z",
    "nvd_published_at" : null
  }
}