Security mailing lists by PureSourceCode

CVE-2024-27289

HIGH 8.1CVSS 3.1

pgx SQL Injection via Line Comment Creation

pgx is a PostgreSQL driver and toolkit for Go. Prior to version 4.18.2, SQL injection can occur when all of the following conditions are met: the non-default simple protocol is used; a placeholder for a numeric value must be immediately preceded by a minus; there must be a second placeholder for a string value after the first placeholder; both must be on the same line; and both parameter values must be user-controlled. The problem is resolved in v4.18.2. As a workaround, do not use the simple protocol or do not place a minus directly before a placeholder.

Published
6 Mar 2024
Last modified
10 Sep 2026
Assigned by
security-advisories@github.com
NVD status
Analyzed
Weakness
CWE-89
Also known as
GHSA-m7wr-2xf7-cm9pGO-2024-2605
Sources
NVDJSONOSV GHSA-m7wr-2xf7-cm9pJSONOSV GO-2024-2605JSON

Scores

SourceScored byVersionScoreVector / decision
OSV GitHub CVSS 4.0 CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N
NVD security-advisories@github.com (Secondary) CVSS 3.1 HIGH 8.1 CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
OSV GitHub CVSS 3.1 HIGH 8.1 CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H

Affected

SourceVendor / ecosystemProduct / packageAffected versionsFixed in
NVD jackc pgx
cpe:2.3:a:jackc:pgx:*:*:*:*:*:go:*:*
< 4.18.2 4.18.2
OSV Go github.com/jackc/pgx < 4.18.2 4.18.2
OSV Go github.com/jackc/pgx/v4 < 4.18.2 4.18.2
OSV Go github.com/jackc/pgx all versions

References

History

  • 25 Nov 2026 20:55 UTC · NVD: first stored (published 6 Mar 2024)
  • 25 Nov 2026 20:14 UTC · OSV: first stored (published 11 Mar 2024)
  • 25 Nov 2026 20:13 UTC · OSV: first stored (published 4 Mar 2024)
An unhandled error has occurred. Reload ×

Rejoining the server...

Rejoin failed... trying again in seconds.

Failed to rejoin.
Please retry or reload the page.

The session has been paused by the server.

Failed to resume the session.
Please retry or reload the page.