CVE-2026-17347 is a command injection vulnerability in pgAdmin's MASTER_PASSWORD_HOOK feature. The flaw occurs because %u (the username placeholder) gets interpolated into the command string before it reaches subprocess.Popen with shell=True, allowing shell metacharacter injection from the username field.
What matters most: exploitation is deployment-dependent, not universal. A pgAdmin instance using local authentication with no %u placeholder in the hook string was never vulnerable. The same codebase behind SAML or OIDC with username claims containing special characters is exploitable—the username in this context can originate from external identity providers that pgAdmin doesn't control, including OAuth claims, Kerberos principals, or REMOTE_USER headers. The EPSS score of 0.00296 likely reflects that many current deployments use local auth, but this will shift as OAuth/OIDC adoption grows.
The fix reorders operations: tokenize the hook command first, then substitute the username into the resulting argv array rather than a pre-interpolated string. This mechanically closes the injection vector but introduces a breaking change—if your hook string contained shell features like pipes, redirection, or variable expansion, that logic must now live inside the invoked script.
What to do: audit all MASTER_PASSWORD_HOOK configurations for %u usage, identify which authentication sources feed the username, treat any username from external identity providers as untrusted, and scan pgAdmin for other %u-equivalent interpolation patterns that could surface similar issues. Monitor the patch for second-order parsing edge cases; the tokenize-then-substitute pattern has produced follow-on CVEs in other contexts when shlex encounters unexpected characters.