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

EcosystemPackageVulnerableFirst fixed
Gogithub.com/prest/prest/v2< 2.0.0-rc2none listed
VendorProductAffected versions (per CVE record)
prestprest< 2.0.0-rc3

Severity scores

Scored byCVSSScoreVector
GitHub_M4.09.3 CriticalCVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
GitHub4.09.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

  1. GitHub Advisory GHSA-p46v-f2x8-qp98 github.com
  2. CVE.org record CVE-2025-58450 cve.org
  3. NVD entry CVE-2025-58450 nvd.nist.gov

Other references from the CVE record and advisory

  1. github.com github.com
  2. github.com github.com

Critical Go advisories · Today’s Security Digest