Security Digest · Vulnerability record
CVE-2025-58450: pREST has a Systemic SQL Injection Vulnerability
pREST (PostgreSQL REST), is an API that delivers an application on top of a Postgres database.
CVSS 9.3 Critical EPSS 0.4% · p37
Should you act?
Critical and remotely reachable
No known exploitation yet, but it is network-reachable without credentials. This signal is computed from CISA KEV, EPSS and CVSS data; it is not an editorial verdict.
- Not in CISA KEV, but CISA’s SSVC assessment records a public proof-of-concept, so attack code exists.
- EPSS 0.4%, percentile 37: FIRST’s model estimates a 0.4% chance of exploitation activity in the next 30 days, higher than 37% of all scored CVEs (low). EPSS is a probability, not a verdict.
- Remotely reachable with no login and no user interaction. If the vulnerable service is exposed to the internet, prioritize it.
- Only applies if your dependency tree includes
github.com/prest/prest/v2(Go) < 2.0.0-rc2, no fixed version listed. Check your lockfile, including transitive dependencies.
What it is
pREST (PostgreSQL REST), is an API that delivers an application on top of a Postgres database. SQL injection is possible in versions prior to 2.0.0-rc3. The validation present in versions prior to 2.0.0-rc3 does not provide adequate protection from injection attempts. Version 2.0.0-rc3 contains a patch to mitigate such attempts.
From the GitHub advisory
Summary pREST provides a simple way for users to expose access their database via a REST-full API. The project is implemented using the Go programming language and is designed to expose access to Postgres database tables.
During an independent review of the project, Doyensec engineers found that SQL injection is a systemic problem in the current implementation (version v2.0.0-rc2). Even though there are several instances of attempts to sanitize user input and mitigate injection attempts, we have found that on most code-paths, the protection is faulty or non-existent.
Core Endpoints The main functionality providing REST operations on the data stored in the Postgres database is exposed via the following endpoints: - GET /{database}/{schema}/{table} - POST /{database}/{schema}/{table} - PUT|PATCH /{database}/{schema}/{table} - DELETE /{database}/{schema}/{table}
Handlers for the above endpoints execute very similar logic. At a high-level they: 1. Perform authentication and authorization 2. Build the SQL query based on the incoming request 3. Execute the query on the database 4. Return the data to the user
The query construction logic uses data from the request (e.g query, body or path parameters) and incorporates them in the SQL query.
Weakness type: CWE-89.
Product: github.com/prest/prest/v2 (Go) · Assigned by: GitHub_M · Published: 2025-09-08
Affected and fixed versions
| Ecosystem | Package | Vulnerable | First fixed |
|---|---|---|---|
| Go | github.com/prest/prest/v2 | < 2.0.0-rc2 | none listed |
| Vendor | Product | Affected versions (per CVE record) |
|---|---|---|
| prest | prest | < 2.0.0-rc3 |
Severity scores
| Scored by | CVSS | Score | Vector |
|---|---|---|---|
| GitHub_M | 4.0 | 9.3 Critical | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N |
| GitHub | 4.0 | 9.3 | CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N |
- Attack vector: network (remotely reachable)
- Attack complexity: low
- Attack requirements: none
- Privileges required: none (no login)
- User interaction: none
CVSS measures how bad a flaw is if exploited, not how likely exploitation is. Read it next to the exploitation data below.
Exploitation and urgency
- CISA KEV: not listed (no confirmed in-the-wild exploitation known to CISA).
- CISA SSVC assessment: exploitation poc, automatable yes, technical impact total.
- FIRST EPSS (model of 2026-10-21): 0.44% probability of exploitation activity in the next 30 days; percentile 37.
Timeline
- — CVE record published by GitHub_M
- — GitHub-reviewed advisory GHSA-p46v-f2x8-qp98 published (critical)
- — CVE record last updated
Sources and references
Original sources first. Version and fix details should always be confirmed against the vendor or project advisory.
Vulnerability records
- GitHub Advisory GHSA-p46v-f2x8-qp98 github.com
- CVE.org record CVE-2025-58450 cve.org
- NVD entry CVE-2025-58450 nvd.nist.gov
Other references from the CVE record and advisory
- github.com github.com
- github.com github.com