# CVE-2026-7815: pgAdmin 4: SQL injection in Maintenance tool option values leading to remote code execution

- Severity: High 8.7 (CVSS:4.0, scored by PostgreSQL) `CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`
- Known to be exploited: not in CISA's catalogue, which lists only what CISA has confirmed
- Likelihood of exploitation in the next 30 days (EPSS): 0.46%, higher than 41% of CVEs (2026-12-01)
- Published: 2026-05-11T14:35:50.081Z
- Modified: 2026-10-26T18:10:00.173Z
- Also known as: GHSA-hp84-p2gq-6fvr, PYSEC-2026-2867
- Weaknesses: CWE-89
- SSVC (CISA-ADP): exploitation none, automatable no, technical impact total
- Assigned by: PostgreSQL

## Description

SQL injection vulnerability in pgAdmin 4 Maintenance Tool.

Four user-supplied JSON fields (buffer_usage_limit, vacuum_parallel, vacuum_index_cleanup, reindex_tablespace) were concatenated directly into the rendered VACUUM/ANALYZE/REINDEX command and passed to psql --command. An authenticated user with the tools_maintenance permission could break out of the option syntax and execute arbitrary SQL on the connected PostgreSQL server. The injected SQL could in turn invoke COPY ... TO PROGRAM to escalate to operating-system command execution on the database host.

Fix introduces server-side allow-listing of all four fields and switches reindex_tablespace from manual quoting to the qtIdent filter.

This issue affects pgAdmin 4: before 9.15.

(As written by CVE List.)

## Affected

- pgadmin.org pgAdmin 4: from 7.6 before 9.15
- pgadmin4 (PyPI): before 9.15
- pgadmin pgadmin_4: from 7.6 before 9.15

## Every score

- PostgreSQL: CVSS:3.1 8.8 High `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- PostgreSQL: CVSS:4.0 8.7 High `CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`
- GitHub: CVSS:3.1 8.8 High `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- GitHub: CVSS:4.0 High `CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`
- PyPA Advisory Database: CVSS:3.1 8.8 High `CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H`
- PyPA Advisory Database: CVSS:4.0 `CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N`

## References

- <https://github.com/pgadmin-org/pgadmin4/issues/9898> (issue-tracking, patch, vendor-advisory, web)
- <https://nvd.nist.gov/vuln/detail/CVE-2026-7815> (advisory)
- <https://github.com/pgadmin-org/pgadmin4/commit/cf53953d9> (web)
- <https://github.com/pgadmin-org/pgadmin4> (package)
- <https://pypi.org/project/pgadmin4> (package)
- <https://github.com/advisories/GHSA-hp84-p2gq-6fvr> (advisory)

## Sources

- CVE List: [CVE-2026-7815](https://www.cve.org/CVERecord?id=CVE-2026-7815), CVE Terms of Use, modified 2026-05-11
- GitHub Advisory Database: [GHSA-hp84-p2gq-6fvr](https://github.com/advisories/GHSA-hp84-p2gq-6fvr), CC-BY-4.0, modified 2026-09-10
- NVD: [CVE-2026-7815](https://nvd.nist.gov/vuln/detail/CVE-2026-7815), Public domain, modified 2026-10-26
- PyPA Advisory Database: [PYSEC-2026-2867](https://osv.dev/vulnerability/PYSEC-2026-2867), CC-BY-4.0, modified 2026-07-13

---

Page: https://cve.day/CVE-2026-7815 · Whole record: https://cve.day/CVE-2026-7815.json · Rebuilt by cve.day 2026-11-25T22:59:21.205Z
