{"id":"CVE-2025-2946","kind":"vulnerability","aliases":["CVE-2025-2946","GHSA-2rrx-pphc-qfv9"],"related":[],"title":"pgAdmin 4 Vulnerable to Cross-Site Scripting (XSS) via Query Result Rendering","description":"pgAdmin <= 9.1 is affected by a security vulnerability with Cross-Site Scripting(XSS). If attackers execute any arbitrary HTML/JavaScript in a user's browser through query result rendering, then HTML/JavaScript runs on the browser.","summary":"pgAdmin 4 versions 9.1 and earlier do not sanitize query result output, so attacker-supplied HTML and JavaScript runs in the browser of a user who views those results. The result is cross-site scripting that can act with the logged-in user's session in pgAdmin.","severity":"critical","cvss":9.1,"epss":0.00329,"exploited":false,"exploited_at":null,"products":[{"name":"pgadmin4","fixed":["9.2"],"affected":"< 9.2","ecosystem":"pypi"},{"name":"pgadmin 4","fixed":[],"affected":"<= 9.1","ecosystem":"vendor"}],"ecosystems":["pypi","vendor"],"tags":["cwe-79","package","pgadmin4","postgresql","python","web-ui"],"not_affected_if":["version-9.2-or-later"],"how_to_check":"- Check the installed pgAdmin version with `pip show pgadmin4` for the PyPI install, or the version shown in the pgAdmin About dialog.\n- Confirm whether the installed version is below `9.2`.","fix":"- pgAdmin 4 (pypi `pgadmin4`): move to `9.2`.","status":"open","published_at":"2025-04-03T13:15:43+00:00","first_seen_at":"2026-11-16T15:53:11+00:00","triaged_at":"2026-11-16T15:54:27+00:00","updated_at":"2026-11-16T16:08:50+00:00","category":"package","confidence":0.7,"triage":{"at":"2026-11-16T15:54:27Z","model":"claude-haiku-5-5","output":{"fix":"- pgAdmin 4 (pypi `pgadmin4`): move to `9.2`.","reach":"network","title":"pgAdmin 4: query results render attacker HTML and JavaScript in the browser","impact":"medium","summary":"pgAdmin 4 versions 9.1 and earlier do not sanitize query result output, so attacker-supplied HTML and JavaScript runs in the browser of a user who views those results. The result is cross-site scripting that can act with the logged-in user's session in pgAdmin.","audience":"developers","category":"package","nicknames":[],"who_cares":["pgadmin4","python","postgresql","web-ui"],"confidence":0.7,"fix_status":"available","needs_auth":"yes","worst_case":"script runs in user's browser with pgAdmin session access","analyst_note":"how_to_check and needs_auth rest on the GHSA text alone; the patch page could confirm the exact trigger.","how_to_check":"- Check the installed pgAdmin version with `pip show pgadmin4` for the PyPI install, or the version shown in the pgAdmin About dialog.\n- Confirm whether the installed version is below `9.2`.","plain_action":"","product_name":"","needs_analyst":false,"not_affected_if":["version-9.2-or-later"],"who_is_affected":"Teams running pgAdmin 4 versions 9.1 and earlier, including the PyPI pgadmin4 package, where users view query results from databases they do not fully trust. Installations that only run the latest release or that are not used to view untrusted query output are less exposed. The sources do not describe further preconditions.","user_interaction":"yes","product_ecosystem":"","needs_special_setup":"unknown","severity_if_unknown":"unknown"},"cost_usd":0.000754,"input_tokens":4614,"output_tokens":586,"severity_before":"critical"},"analyst_status":null,"analyst_note":null,"search":"'-2025':15A,23A '-2946':16A,24A '-79':29B '2rrx':19A '4':2A,27A,38B '9.1':40B,88C 'act':76B 'affect':90C 'arbitrari':105C 'attack':51B,102C 'attacker-suppli':50B 'browser':59B,111C,121C 'cross':6A,71B,97C 'cross-sit':5A,70B,96C 'cve':14A,22A 'cwe':28B 'earlier':42B 'execut':103C 'ghsa':18A 'ghsa-2rrx-pphc-qfv9':17A 'html':53B 'html/javascript':106C,117C 'javascript':55B 'log':80B 'logged-in':79B 'output':48B 'packag':30B 'pgadmin':1A,26A,37B,86B,87C 'pgadmin4':25A,31B 'postgresql':32B 'pphc':20A 'python':33B 'qfv9':21A 'queri':11A,46B,113C 'render':13A,115C 'result':12A,47B,66B,68B,114C 'run':56B,118C 'sanit':45B 'script':8A,73B,99C 'secur':93C 'session':84B 'site':7A,72B,98C 'suppli':52B 'ui':36B 'user':62B,82B,109C 'version':39B 'via':10A 'view':64B 'vulner':3A,94C 'web':35B 'web-ui':34B 'xss':9A,100C","nicknames":[],"mitigations":[],"who_affected":"Teams running pgAdmin 4 versions 9.1 and earlier, including the PyPI pgadmin4 package, where users view query results from databases they do not fully trust. Installations that only run the latest release or that are not used to view untrusted query output are less exposed. The sources do not describe further preconditions.","tier":"B","verified":{},"analyst_revisit_at":null,"fix_status":"available","audience":"developers","plain_action":null,"pkeys":["4","pgadmin4"],"ptokens":["pgadmin","pgadmin4"],"labels":["critical","cwe79","package","pgadmin4","postgresql","pypi","python","vendor","webui"],"campaign_type":null,"search_a":"'-2025':15A,23A '-2946':16A,24A '2rrx':19A '4':2A,27A 'cross':6A 'cross-sit':5A 'cve':14A,22A 'ghsa':18A 'ghsa-2rrx-pphc-qfv9':17A 'pgadmin':1A,26A 'pgadmin4':25A 'pphc':20A 'qfv9':21A 'queri':11A 'render':13A 'result':12A 'script':8A 'site':7A 'via':10A 'vulner':3A 'xss':9A","search_b":"'-79':29B '4':38B '9.1':40B 'act':76B 'attack':51B 'attacker-suppli':50B 'browser':59B 'cross':71B 'cross-sit':70B 'cwe':28B 'earlier':42B 'html':53B 'javascript':55B 'log':80B 'logged-in':79B 'output':48B 'packag':30B 'pgadmin':37B,86B 'pgadmin4':31B 'postgresql':32B 'python':33B 'queri':46B 'result':47B,66B,68B 'run':56B 'sanit':45B 'script':73B 'session':84B 'site':72B 'suppli':52B 'ui':36B 'user':62B,82B 'version':39B 'view':64B 'web':35B 'web-ui':34B","search_c":"'9.1':88C 'affect':90C 'arbitrari':105C 'attack':102C 'browser':111C,121C 'cross':97C 'cross-sit':96C 'execut':103C 'html/javascript':106C,117C 'pgadmin':87C 'queri':113C 'render':115C 'result':114C 'run':118C 'script':99C 'secur':93C 'site':98C 'user':109C 'vulner':94C 'xss':100C","cause_entry":null,"cause_path":null,"disclosures_checked_at":null,"first_public_at":"2025-04-03T13:15:43+00:00","kev":null,"cvss_vector":"CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:L/I:L/A:H","cvss_by":"GitHub","poc_count":0,"sources":[{"source":"ghsa","external_id":"GHSA-2rrx-pphc-qfv9","url":"https://github.com/advisories/GHSA-2rrx-pphc-qfv9","severity":"critical","published_at":"2025-04-03T15:31:13+00:00","modified_at":"2026-11-16T15:51:08+00:00","first_seen_at":"2026-11-16T15:53:11+00:00","fetched_at":"2026-11-16T15:56:53+00:00","note":null},{"source":"nvd","external_id":"CVE-2025-2946","url":"https://nvd.nist.gov/vuln/detail/CVE-2025-2946","severity":null,"published_at":"2025-04-03T13:15:43+00:00","modified_at":"2026-06-17T09:07:53+00:00","first_seen_at":"2026-11-16T16:08:50+00:00","fetched_at":"2026-11-16T16:08:50+00:00","note":null}],"documents":[{"id":170807,"url":"https://github.com/pgadmin-org/pgadmin4/commit/1305d9910beefd0d6b4c7eb4f111f86edb1d356b","title":"Patch: github.com","kind":"other","source":"ghsa","publisher":"vendor","text":null,"published_at":null,"relation":"fix","confidence":null,"note":"Patch: github.com"}],"disclosures":[],"exploit_sources":[{"type":"epss","score":0.00329,"url":"https://api.first.org/data/v1/epss?cve=CVE-2025-2946"}],"notice":"Free to read, with fair use of about 60 pages a minute. For higher limits or API access: sales@infrastack.ai"}