SQL Injection can occur when:
e.g.
attackValue := `$tag$; drop table canary; --`
_, err = tx.Exec(ctx, `select $tag$ $1 $tag$, $1`, pgx.QueryExecModeSimpleProtocol, attackValue)
This is unlikely to occur outside of a contrived scenario.
The problem is resolved in v5.9.2.
Do not use the simple protocol to execute queries matching all the above conditions.
{
"github_reviewed": true,
"nvd_published_at": null,
"cwe_ids": [
"CWE-89"
],
"github_reviewed_at": "2026-04-22T20:46:51Z",
"severity": "LOW"
}