PatchSiren

PatchSiren cyber security CVE debrief

CVE-2026-17347 pgadmin.org CVE debrief

The CVE-2026-17347 vulnerability affects pgAdmin 4 versions 7.2 to 9.17, allowing an authenticated user to execute arbitrary commands as the pgAdmin service account by providing a username with shell metacharacters. This issue arises from the previous implementation of the MASTER_PASSWORD_HOOK setting, which substituted the username directly into the command string and executed the result with subprocess.Popen(..., shell=True). The fix tokenizes the administrator-configured hook string into an argument vector, substitutes the untrusted username into individual argv elements, and executes with shell=False. To address this vulnerability, administrators should review and update the MASTER_PASSWORD_HOOK setting to ensure it uses the fixed tokenization and execution approach. Additionally, they should restrict the execution of arbitrary commands as the pgAdmin service account and monitor for potential exploitation attempts.

Vendor
pgadmin.org
Product
pgAdmin 4
CVSS
HIGH 7.7
CISA KEV
Not listed in stored evidence
Original CVE published
2026-07-31
Original CVE updated
2026-08-07
Advisory published
2026-07-31
Advisory updated
2026-08-07

Who should care

pgAdmin 4 administrators and users, especially those with external authentication sources (OAuth/OIDC claims, Kerberos, webserver auth) and customized MASTER_PASSWORD_HOOK settings, should be aware of this vulnerability and take necessary actions to address it. They should review and update the MASTER_PASSWORD_HOOK setting, restrict the execution of arbitrary commands, and monitor for potential exploitation attempts. Additionally, they should ensure that their systems are updated to a version of pgAdmin 4 that is not affected by this vulnerability.

Technical summary

The MASTER_PASSWORD_HOOK setting in pgAdmin 4, versions 7.2 to 9.17, allows an authenticated user to execute arbitrary commands as the pgAdmin service account by providing a username with shell metacharacters. The issue arises from the previous implementation substituting the username directly into the command string and executing the result with subprocess.Popen(..., shell=True). The fix tokenizes the administrator-configured hook string into an argument vector, substitutes the untrusted username into individual argv elements, and executes with shell=False.

Defensive priority

Authenticated users with specially crafted usernames can execute arbitrary commands as the pgAdmin service account.

Recommended defensive actions

  • Review and update the MASTER_PASSWORD_HOOK setting in pgAdmin 4 to ensure it uses the fixed tokenization and execution approach.
  • Restrict the execution of arbitrary commands as the pgAdmin service account.
  • Monitor for and respond to potential exploitation attempts.
  • Confirm whether affected product deployments exist in managed environments and assign an owner for follow-up.
  • Review the supplied official advisory or CVE record to validate affected scope, severity, and vendor guidance.
  • Plan vendor-supported updates or mitigations through normal change control where exposure is confirmed.
  • Review compensating controls for exposed systems while remediation is scheduled and verified.

Evidence notes

The issue arises from the MASTER_PASSWORD_HOOK setting in pgAdmin 4, versions 7.2 to 9.17. An authenticated user can execute arbitrary commands as the pgAdmin service account by providing a username with shell metacharacters. The fix tokenizes the administrator-configured hook string into an argument vector, substitutes the untrusted username into individual argv elements, and executes with shell=False.

Sources and references

Verified primary and authoritative sources

  • CVE-2026-17347 CVE Program record

    Publisher, destination, and source semantics verified

    URL: https://www.cve.org/CVERecord?id=CVE-2026-17347

    CVE Program - Official CVE Program record with source-provided CVE metadata.

  • CVE-2026-17347 NVD vulnerability detail

    Publisher, destination, and source semantics verified

    URL: https://nvd.nist.gov/vuln/detail/CVE-2026-17347

    NIST National Vulnerability Database - Official NIST NVD detail page and source-specific vulnerability assessment.

Supplemental references

  • Source reference

    Unverified legacy reference

    URL: https://github.com/pgadmin-org/pgadmin4/commit/e7a85767314e7b0fe0b35fe80b9c1af38f48dff6

    f86ef6dc-4d3a-42ad-8f28-e6d5547a5007

  • Source reference

    Unverified legacy reference

    URL: https://github.com/pgadmin-org/pgadmin4/commit/ea7e798aac27174d2bacee1d6e136bed76a95e23

    f86ef6dc-4d3a-42ad-8f28-e6d5547a5007

  • Source reference

    Unverified legacy reference

    URL: https://github.com/pgadmin-org/pgadmin4/issues/10191

    f86ef6dc-4d3a-42ad-8f28-e6d5547a5007

Methodology and review provenance

AI-assisted synthesis based on stored public vulnerability evidence. System validation, approval state, and publication status do not by themselves establish human review of this revision. PatchSiren helps prioritize defensive review and does not prove exposure or remediation on any system.