{"cve":"CVE-2026-7820","nvd":{"published":"2026-05-11T16:17:39.497","modified":"2026-10-26T18:10:00.173","status":"Analyzed","description":"Improper restriction of excessive authentication attempts (CWE-307) in pgAdmin 4.\n\npgAdmin enforces MAX_LOGIN_ATTEMPTS only inside its custom /authenticate/login view. Flask-Security's default /login view, which is registered automatically by security.init_app() and is reachable on every server, never consulted the User.locked field: pgAdmin's User model relied on Flask-Security's UserMixin.is_locked() (which always returns 'not locked') and Flask-Login's is_active (which only checks the active column, not locked). An attacker who triggered an account lockout via /authenticate/login could therefore obtain a session by re-submitting valid credentials directly to /login, defeating the brute-force-protection control for accounts using the INTERNAL authentication source. The same bypass also means that login attempts via /login are never rate-limited, so an attacker can perform an unbounded online password-guessing attack against INTERNAL accounts regardless of MAX_LOGIN_ATTEMPTS.\n\nFix overrides User.is_active and User.is_locked() so the locked column is enforced on every authentication path. LDAP, OAuth2, Kerberos, and Webserver users are not reachable by this bypass because they have no local password and are rejected by Flask-Security's LoginForm.validate before the locked check; the lockout itself is also internal-only (the /authenticate/login view filters by auth_source=INTERNAL).\n\nThis issue affects pgAdmin 4: before 9.15.","cvss_v4":{"vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N","score":6.9},"cvss_v3":{"version":"3.1","vector":"CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:L/I:L/A:N","score":6.5},"cwes":["CWE-307"],"references":["https://github.com/pgadmin-org/pgadmin4/issues/9904"],"products":["pgadmin:pgadmin_4"],"source":"nvd","synced_at":"2026-10-26T18:27:13.530666824+00:00"},"epss":{"cve":"CVE-2026-7820","score":0.00211,"percentile":0.11215,"date":"2026-10-26"},"kev":null,"osv":[{"id":"GHSA-hv9p-2pqf-r5w3","url":"https://osv.dev/vulnerability/GHSA-hv9p-2pqf-r5w3","summary":"pgAdmin 4: Improper restriction of excessive authentication attempts","modified":"2026-09-10T03:51:06.027640951Z","packages":[{"ecosystem":"PyPI","name":"pgadmin4","purl":"pkg:pypi/pgadmin4","ranges":["<9.15"],"fixed":["9.15"]}]},{"id":"PYSEC-2026-2869","url":"https://osv.dev/vulnerability/PYSEC-2026-2869","summary":"pgAdmin 4: Improper restriction of excessive authentication attempts","modified":"2026-07-13T16:32:56.120891202Z","packages":[{"ecosystem":"PyPI","name":"pgadmin4","purl":"pkg:pypi/pgadmin4","ranges":["<9.15"],"fixed":["9.15"]}]}],"attribution":["This product uses the NVD API but is not endorsed or certified by the NVD.","EPSS scores: FIRST Exploit Prediction Scoring System, https://www.first.org/epss","Known exploited vulnerabilities: CISA Known Exploited Vulnerabilities Catalog, https://www.cisa.gov/known-exploited-vulnerabilities-catalog","Package advisories: OSV (https://osv.dev), from the GitHub Advisory Database, PyPA, Go, RustSec and other ecosystem databases, under CC-BY 4.0 or CC0","CVE records: the CVE Program's CVE List (https://www.cve.org), under its terms of use (https://www.cve.org/Legal/TermsOfUse). CVE is a registered trademark of The MITRE Corporation; this product is not affiliated with the CVE Program."]}