FreeBSD : PostgreSQL -- PostgreSQL quoting APIs miss neutralizing quoting syntax in text that fails encoding validation (fadf3b41-ea19-11ef-a540-6cc21735f730)

high Nessus Plugin ID 216251

Language:

Synopsis

The remote FreeBSD host is missing one or more security-related updates.

Description

The version of FreeBSD installed on the remote host is prior to tested version. It is, therefore, affected by a vulnerability as referenced in the fadf3b41-ea19-11ef-a540-6cc21735f730 advisory.

The PostgreSQL Project reports:

Improper neutralization of quoting syntax in PostgreSQL libpq functions PQescapeLiteral(), PQescapeIdentifier(), PQescapeString(), and PQescapeStringConn() allows a database input provider to achieve SQL injection in certain usage patterns. Specifically, SQL injection requires the application to use the function result to construct input to psql, the PostgreSQL interactive terminal. Similarly, improper neutralization of quoting syntax in PostgreSQL command line utility programs allows a source of command line arguments to achieve SQL injection when client_encoding is BIG5 and server_encoding is one of EUC_TW or MULE_INTERNAL.
Versions before PostgreSQL 17.3, 16.7, 15.11, 14.16, and 13.19 are affected.


Tenable has extracted the preceding description block directly from the FreeBSD security advisory.

Note that Nessus has not tested for this issue but has instead relied only on the application's self-reported version number.

Solution

Update the affected packages.

See Also

https://www.postgresql.org/support/security/CVE-2025-1094/

http://www.nessus.org/u?7e0e44d4

Plugin Details

Severity: High

ID: 216251

File Name: freebsd_pkg_fadf3b41ea1911efa5406cc21735f730.nasl

Version: 1.2

Type: local

Published: 2/13/2025

Updated: 2/19/2025

Supported Sensors: Nessus

Risk Information

VPR

Risk Factor: Critical

Score: 9.2

CVSS v2

Risk Factor: High

Base Score: 7.6

Temporal Score: 6.3

Vector: CVSS2#AV:N/AC:H/Au:N/C:C/I:C/A:C

CVSS Score Source: CVE-2025-1094

CVSS v3

Risk Factor: High

Base Score: 8.1

Temporal Score: 7.5

Vector: CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H

Temporal Vector: CVSS:3.0/E:F/RL:O/RC:C

Vulnerability Information

CPE: p-cpe:/a:freebsd:freebsd:postgresql14-client, p-cpe:/a:freebsd:freebsd:postgresql17-client, p-cpe:/a:freebsd:freebsd:postgresql15-client, p-cpe:/a:freebsd:freebsd:postgresql13-client, cpe:/o:freebsd:freebsd, p-cpe:/a:freebsd:freebsd:postgresql16-client

Required KB Items: Host/local_checks_enabled, Host/FreeBSD/release, Host/FreeBSD/pkg_info

Exploit Available: true

Exploit Ease: Exploits are available

Patch Publication Date: 2/13/2025

Vulnerability Publication Date: 2/13/2025

Exploitable With

Metasploit (BeyondTrust Privileged Remote Access (PRA) and Remote Support (RS) unauthenticated Remote Code Execution)

Reference Information

CVE: CVE-2025-1094