Cyber Resilience

CVE-2022-4223

RCE in Pgadmin 4 ≤ 6.17

Published
13 December 2022
Modified
14 April 2025
CVSS Score v3.1 8.8
Click a component to see what it means
Raw vectorCVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H
EPSS Score 0.80 99.6th percentile
Risk Priority 87 floored blend · peak EPSS

Summary

CVE-2022-4223 is a high-severity Code Injection (CWE-94) vulnerability in Pgadmin Pgadmin 4. Its CVSS base score is 8.8 (High).

Operationally, ranked in the top 0.4% of CVEs by exploit likelihood; it is not currently listed in the CISA KEV catalog.

The strongest mitigations our analysis identified map to AC-3 (Access Enforcement) and IA-2 (Identification and Authentication (Organizational Users)) — see the control section below for these in your framework.

Deeper analysis AI-assisted summary

Synthesised by an AI model from the NVD description and linked references — a reading aid, not an authoritative source.

The vulnerability affects the pgAdmin server in versions prior to 6.17. An HTTP API intended only for validating paths to external PostgreSQL utilities such as pg_dump and pg_restore was insufficiently secured. The server invokes the named utility to identify its PostgreSQL version, but the API accepted arbitrary paths supplied by callers, including UNC paths pointing to attacker-controlled locations on Windows systems.

An unauthenticated remote attacker can invoke the API with a malicious path containing an appropriately named executable. Successful exploitation results in the pgAdmin server executing attacker-supplied code, yielding remote code execution with the privileges of the pgAdmin process. The issue is tracked under CWE-94 and CWE-862 and carries a CVSS 3.1 base score of 8.8.

Public references, including the pgAdmin GitHub issue tracker and Fedora package-announce lists, document the flaw and point to the availability of patched builds beginning with version 6.17. The current EPSS score of 0.8701 (peak 0.8898) indicates sustained exploitation interest after disclosure.

OWASP Top 10 for Web (2025)

EU & UK References

Vulnerability Data

The pgAdmin server includes an HTTP API that is intended to be used to validate the path a user selects to external PostgreSQL utilities such as pg_dump and pg_restore. The utility is executed by the server to determine what PostgreSQL…

more

version it is from. Versions of pgAdmin prior to 6.17 failed to properly secure this API, which could allow an unauthenticated user to call it with a path of their choosing, such as a UNC path to a server they control on a Windows machine. This would cause an appropriately named executable in the target path to be executed by the pgAdmin server.

CWE(s)

Related Threats

Likely ATT&CK TechniquesAI

Techniques this vulnerability likely enables, inferred from its description, weakness type, and attributed-actor tradecraft. Confidence is per-technique.

T1190 Exploit Public-Facing Application Initial Accessconfidence: HIGH
The unauthenticated HTTP API flaw allows remote attackers to supply arbitrary paths that the server executes, directly enabling exploitation of a public-facing application.
T1059 Command and Scripting Interpreter Executionconfidence: HIGH
Successful exploitation results in the pgAdmin server executing attacker-supplied code, enabling arbitrary command execution.
T1068 Exploitation for Privilege Escalation Privilege Escalationconfidence: MEDIUM
RCE yields code execution with the privileges of the pgAdmin process, which may facilitate privilege escalation depending on the deployment context.
inferred from description + CWE · MITRE ATT&CK Enterprise v19.0

CVEs Like This One

CVE-2025-12762Same product: Pgadmin Pgadmin 4
CVE-2025-13780Same product: Pgadmin Pgadmin 4
CVE-2025-2945Same product: Pgadmin Pgadmin 4
CVE-2023-51797Same product: Fedoraproject Fedora
CVE-2024-25713Same product: Fedoraproject Fedora
CVE-2023-29402Same product: Fedoraproject Fedora
CVE-2023-28333Same product: Fedoraproject Fedora
CVE-2026-35093Same product: Fedoraproject Fedora
CVE-2024-5834Same product: Fedoraproject Fedora
CVE-2023-29404Same product: Fedoraproject Fedora

Affected Assets

pgadmin
pgadmin 4
≤ 6.17
fedoraproject
fedora
37

Mitigating Controls

Control response

Prevent
Stop it (NIST 800-53)
  • AC-3 Access Enforcement
  • IA-2 Identification and Authentication (Organizational Users)
  • SI-10 Information Input Validation
Detect
Catch it (NIST detect / respond)

Harden
Shrink the surface (DISA STIG)
  • 5 hardening rules · 3 OS baselines
Validate
Prove the fix (OWASP ASVS)
  • V1.3.1

Mitigating Controls (NIST 800-53 r5) AI

prevent

Enforces authorization checks on the path-validation HTTP API so that only authenticated, authorized callers may invoke it, directly blocking the unauthenticated RCE vector.

prevent

Requires identification and authentication before any access to the pgAdmin server API, eliminating the unauthenticated entry point used by the exploit.

prevent

Validates that supplied paths reference only approved PostgreSQL utilities and locations, preventing arbitrary executable paths from being accepted and executed.

Mitigating Controls (NIST CSF 2.0) AI

Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→CSF cross-walk (authority under review) — links open the control.

PR.AA-05 full match
prevents

Explicitly requires defining, enforcing, and reviewing authorizations and least privilege, directly preventing missing authorization checks.

PR.PS-06 mostly match
prevents

PR.PS-06's SDLC practices directly target injection flaws via secure coding and testing (mostly), yet as a single broad outcome it leaves many code-generation specifics unaddressed (partial).

PR.DS-10 none match
prevents

PR.DS-10 protects runtime data confidentiality/integrity but has no bearing on neutralizing externally influenced input during code generation, so neither direction shows any preventive effect.

Mitigating Controls (ISO/IEC 27001:2022 Annex A) AI

Derived directly from the weakness types (CWEs) cited in the NVD entry via our AI-authored CWE→ISO cross-walk (authority under review) — links open the control.

prevents

Requiring authentication and credentials before any access occurs eliminates the absence of authorization checks that would otherwise allow an unauthenticated actor to reach protected resources.

prevents

Requiring formal authorization of every access request before rights are granted ensures that checks for required permissions are performed, preventing missing authorization checks from being introduced.

prevents

Mandatory authorization checks and central records of granted rights ensure that every access attempt is preceded by an explicit decision rather than relying on missing checks.

mitigates

Segregating the approval of access rights from their implementation provides an independent check that reduces the impact of missing authorization checks in the resulting system configuration.

detects

By requiring competent outsiders to verify that every function enforces the need-to-know principle, the control lowers the likelihood that missing authorization checks persist undetected.

prevents

Defining authorization responsibilities and reviewing risk-treatment progress throughout the project lifecycle catches missing authorization checks before the system is deployed.

References