The SentinelOne Annual Threat Report - A Defenders Guide from the FrontlinesThe SentinelOne Annual Threat ReportGet the Report
Experiencing a Breach?Blog
Get StartedContact Us
SentinelOne
  • Platform
    Platform Overview
    • Singularity Platform
      Welcome to Integrated Enterprise Security
    • AI for Security
      Leading the Way in AI-Powered Security Solutions
    • Securing AI
      Accelerate AI Adoption with Secure AI Tools, Apps, and Agents.
    • How It Works
      The Singularity XDR Difference
    • Singularity Marketplace
      One-Click Integrations to Unlock the Power of XDR
    • Pricing & Packaging
      Comparisons and Guidance at a Glance
    Data & AI
    • Purple AI
      Accelerate SecOps with Generative AI
    • Singularity Hyperautomation
      Easily Automate Security Processes
    • AI-SIEM
      The AI SIEM for the Autonomous SOC
    • Singularity Data Lake
      AI-Powered, Unified Data Lake
    • Singularity Data Lake for Log Analytics
      Seamlessly Ingest Data from On-Prem, Cloud or Hybrid Environments
    Endpoint Security
    • Singularity Endpoint
      Autonomous Prevention, Detection, and Response
    • Singularity XDR
      Native & Open Protection, Detection, and Response
    • Singularity RemoteOps Forensics
      Orchestrate Forensics at Scale
    • Singularity Threat Intelligence
      Comprehensive Adversary Intelligence
    • Singularity Vulnerability Management
      Application & OS Vulnerability Management
    • Singularity Identity
      Identity Threat Detection and Response
    Cloud Security
    • Singularity Cloud Security
      Block Attacks with an AI-Powered CNAPP
    • Singularity Cloud Native Security
      Secure Cloud and Development Resources
    • Singularity Cloud Workload Security
      Real-Time Cloud Workload Protection Platform
    • Singularity Cloud Data Security
      AI-Powered Threat Detection for Cloud Storage
    • Singularity Cloud Security Posture Management
      Detect and Remediate Cloud Misconfigurations
    Securing AI
    • Prompt Security
      Secure AI Tools Across Your Enterprise
  • Why SentinelOne?
    Why SentinelOne?
    • Why SentinelOne?
      Cybersecurity Built for What’s Next
    • Our Customers
      Trusted by the World’s Leading Enterprises
    • Industry Recognition
      Tested and Proven by the Experts
    • About Us
      The Industry Leader in Autonomous Cybersecurity
    Compare SentinelOne
    • Arctic Wolf
    • Broadcom
    • CrowdStrike
    • Cybereason
    • Microsoft
    • Palo Alto Networks
    • Sophos
    • Splunk
    • Trellix
    • Trend Micro
    • Wiz
    Verticals
    • Energy
    • Federal Government
    • Finance
    • Healthcare
    • Higher Education
    • K-12 Education
    • Manufacturing
    • Retail
    • State and Local Government
  • Services
    Managed Services
    • Managed Services Overview
      Wayfinder Threat Detection & Response
    • Threat Hunting
      World-Class Expertise and Threat Intelligence
    • Managed Detection & Response
      24/7/365 Expert MDR Across Your Entire Environment
    • Incident Readiness & Response
      DFIR, Breach Readiness, & Compromise Assessments
    Support, Deployment, & Health
    • Technical Account Management
      Customer Success with Personalized Service
    • SentinelOne GO
      Guided Onboarding & Deployment Advisory
    • SentinelOne University
      Live and On-Demand Training
    • Services Overview
      Comprehensive Solutions for Seamless Security Operations
    • SentinelOne Community
      Community Login
  • Partners
    Our Network
    • MSSP Partners
      Succeed Faster with SentinelOne
    • Singularity Marketplace
      Extend the Power of S1 Technology
    • Cyber Risk Partners
      Enlist Pro Response and Advisory Teams
    • Technology Alliances
      Integrated, Enterprise-Scale Solutions
    • SentinelOne for AWS
      Hosted in AWS Regions Around the World
    • Channel Partners
      Deliver the Right Solutions, Together
    • SentinelOne for Google Cloud
      Unified, Autonomous Security Giving Defenders the Advantage at Global Scale
    • Partner Locator
      Your Go-to Source for Our Top Partners in Your Region
    Partner Portal→
  • Resources
    Resource Center
    • Case Studies
    • Data Sheets
    • eBooks
    • Reports
    • Videos
    • Webinars
    • Whitepapers
    • Events
    View All Resources→
    Blog
    • Feature Spotlight
    • For CISO/CIO
    • From the Front Lines
    • Identity
    • Cloud
    • macOS
    • SentinelOne Blog
    Blog→
    Tech Resources
    • SentinelLABS
    • Ransomware Anthology
    • Cybersecurity 101
  • About
    About SentinelOne
    • About SentinelOne
      The Industry Leader in Cybersecurity
    • Investor Relations
      Financial Information & Events
    • SentinelLABS
      Threat Research for the Modern Threat Hunter
    • Careers
      The Latest Job Opportunities
    • Press & News
      Company Announcements
    • Cybersecurity Blog
      The Latest Cybersecurity Threats, News, & More
    • FAQ
      Get Answers to Our Most Frequently Asked Questions
    • DataSet
      The Live Data Platform
    • S Foundation
      Securing a Safer Future for All
    • S Ventures
      Investing in the Next Generation of Security, Data and AI
  • Pricing
Get StartedContact Us
CVE Vulnerability Database
Vulnerability Database/CVE-2025-2945

CVE-2025-2945: pgAdmin 4 Remote Code Execution Vulnerability

CVE-2025-2945 is a remote code execution vulnerability in pgAdmin 4 affecting the Query Tool and Cloud Deployment modules. Attackers can exploit unsafe eval() usage to execute arbitrary code. This article covers affected versions, impact, and mitigation.

Updated: January 22, 2026

CVE-2025-2945 Overview

CVE-2025-2945 is a Remote Code Execution (RCE) vulnerability affecting pgAdmin 4, a popular open-source administration and management platform for PostgreSQL databases. The vulnerability exists in two critical POST endpoints within the Query Tool and Cloud Deployment modules, where user-controlled input is unsafely passed to Python's eval() function, enabling arbitrary code execution on the server.

The flaw specifically impacts the /sqleditor/query_tool/download endpoint via the query_commited parameter and the /cloud/deploy endpoint via the high_availability parameter. Authenticated attackers can exploit these endpoints to execute arbitrary Python code with the privileges of the pgAdmin web server process, potentially leading to complete system compromise.

Critical Impact

Authenticated attackers can achieve remote code execution on pgAdmin 4 servers by exploiting unsafe eval() function calls in the Query Tool and Cloud Deployment modules, potentially compromising database infrastructure and sensitive data.

Affected Products

  • pgAdmin 4 versions prior to 9.2
  • pgAdmin 4 for PostgreSQL (all platforms)
  • pgAdmin 4 web server deployments

Discovery Timeline

  • 2025-04-03 - CVE-2025-2945 published to NVD
  • 2025-09-17 - Last updated in NVD database

Technical Details for CVE-2025-2945

Vulnerability Analysis

This vulnerability represents a classic Code Injection flaw (CWE-94) stemming from the dangerous use of Python's eval() function on untrusted user input. The vulnerability affects two distinct endpoints in pgAdmin 4's web interface, both of which accept POST requests and process parameters without adequate sanitization before passing them to eval().

The attack requires network access and low-privilege authentication to the pgAdmin 4 interface. Once authenticated, an attacker can craft malicious payloads that, when processed by the vulnerable endpoints, result in arbitrary Python code execution on the underlying server. This can lead to complete confidentiality, integrity, and availability compromise of the affected system.

Given the typical deployment context of pgAdmin 4 as a database administration tool, successful exploitation could provide attackers with direct access to PostgreSQL database servers, credentials, and sensitive data managed through the platform.

Root Cause

The root cause of CVE-2025-2945 is the unsafe use of Python's eval() function to process user-supplied input. The eval() function dynamically executes arbitrary Python expressions, and when called with untrusted data, it creates a direct code injection vector.

In the vulnerable pgAdmin 4 code paths, the query_commited parameter in the Query Tool download functionality and the high_availability parameter in the Cloud Deployment module are passed directly to eval() without proper input validation, sanitization, or the use of safer alternatives like ast.literal_eval() or explicit type parsing.

Attack Vector

The attack vector for CVE-2025-2945 is network-based, requiring an authenticated session to the pgAdmin 4 web interface. An attacker with valid credentials (even low-privilege access) can exploit the vulnerability through the following attack flow:

  1. Authenticate to the pgAdmin 4 web interface
  2. Craft a malicious POST request to either /sqleditor/query_tool/download or /cloud/deploy
  3. Include Python code injection payload in the query_commited or high_availability parameter respectively
  4. The server-side code passes the malicious input to eval(), executing the attacker's code
  5. Achieve arbitrary command execution with the privileges of the pgAdmin web server process

The vulnerability allows exploitation without user interaction once authenticated, and the attack complexity is low as it only requires crafting a simple HTTP POST request with the malicious payload.

For detailed technical information regarding the vulnerable code paths and exploitation mechanics, refer to the GitHub Issue Discussion for this vulnerability.

Detection Methods for CVE-2025-2945

Indicators of Compromise

  • Unusual POST requests to /sqleditor/query_tool/download or /cloud/deploy endpoints containing Python code syntax in parameters
  • Web server logs showing requests with suspicious strings like __import__, exec, os.system, or subprocess in POST data
  • Unexpected child processes spawned by the pgAdmin web server process
  • Anomalous network connections originating from the pgAdmin server to external hosts
  • Unauthorized file modifications or new files created in pgAdmin server directories

Detection Strategies

  • Implement Web Application Firewall (WAF) rules to detect and block requests containing Python code injection patterns targeting pgAdmin endpoints
  • Monitor pgAdmin web server access logs for suspicious POST requests to the vulnerable endpoints with unusual parameter values
  • Deploy endpoint detection solutions to identify anomalous process execution chains originating from the pgAdmin service
  • Configure intrusion detection systems (IDS) to alert on network traffic patterns indicative of post-exploitation activity from pgAdmin servers

Monitoring Recommendations

  • Enable detailed logging for all pgAdmin POST requests, particularly to /sqleditor/query_tool/download and /cloud/deploy endpoints
  • Implement file integrity monitoring on pgAdmin installation directories to detect unauthorized modifications
  • Monitor system process trees for unexpected child processes spawned by the pgAdmin web server
  • Set up alerts for outbound connections from pgAdmin servers to unusual destinations or ports
  • Review authentication logs for unusual login patterns or access from unexpected IP addresses

How to Mitigate CVE-2025-2945

Immediate Actions Required

  • Upgrade pgAdmin 4 to version 9.2 or later immediately to remediate the vulnerability
  • Restrict network access to pgAdmin interfaces using firewall rules, limiting access to trusted IP addresses only
  • Review and audit all pgAdmin user accounts, removing unnecessary access and enforcing strong authentication
  • Implement network segmentation to isolate pgAdmin servers from critical infrastructure
  • Enable comprehensive logging and monitoring on pgAdmin deployments pending upgrade

Patch Information

The vulnerability is addressed in pgAdmin 4 version 9.2. Organizations should upgrade to this version or later to fully remediate CVE-2025-2945. The fix involves proper input validation and the removal of unsafe eval() calls on user-controlled parameters.

For additional details on the vulnerability and remediation, consult the GitHub Issue Discussion.

Workarounds

  • Implement a reverse proxy or WAF in front of pgAdmin to filter malicious requests targeting the vulnerable endpoints
  • Restrict access to pgAdmin interfaces to trusted networks only using firewall rules or VPN requirements
  • Disable or restrict access to the Cloud Deployment module if not required for operations
  • Consider temporarily disabling pgAdmin web access and using command-line tools for critical database administration tasks until patching is complete
bash
# Example: Restrict pgAdmin access to trusted network using iptables
iptables -A INPUT -p tcp --dport 5050 -s 10.0.0.0/24 -j ACCEPT
iptables -A INPUT -p tcp --dport 5050 -j DROP

# Example: Configure nginx reverse proxy with basic request filtering
location /sqleditor/query_tool/download {
    # Block requests with suspicious patterns
    if ($request_body ~* "(__|import|exec|eval|os\.|subprocess)") {
        return 403;
    }
    proxy_pass http://pgadmin_backend;
}

Disclaimer: This content was generated using AI. While we strive for accuracy, please verify critical information with official sources.

  • Vulnerability Details
  • TypeRCE

  • Vendor/TechPgadmin

  • SeverityHIGH

  • CVSS Score8.8

  • EPSS Probability63.37%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityNone
  • AvailabilityHigh
  • CWE References
  • CWE-94
  • Technical References
  • GitHub Issue Discussion
  • Related CVEs
  • CVE-2025-13780: pgAdmin 4 RCE Vulnerability

  • CVE-2025-12762: Pgadmin 4 RCE Vulnerability

  • CVE-2024-2044: pgAdmin 4 RCE Vulnerability

  • CVE-2024-3116: pgAdmin 4 Remote Code Execution Vulnerability
Experience the World’s Most Advanced Cybersecurity Platform

Experience the World’s Most Advanced Cybersecurity Platform

See how our intelligent, autonomous cybersecurity platform can protect your organization now and into the future.

Try SentinelOne
  • Get Started
  • Get a Demo
  • Product Tour
  • Why SentinelOne
  • Pricing & Packaging
  • FAQ
  • Contact
  • Contact Us
  • Customer Support
  • SentinelOne Status
  • Language
  • Platform
  • Singularity Platform
  • Singularity Endpoint
  • Singularity Cloud
  • Singularity AI-SIEM
  • Singularity Identity
  • Singularity Marketplace
  • Purple AI
  • Services
  • Wayfinder TDR
  • SentinelOne GO
  • Technical Account Management
  • Support Services
  • Verticals
  • Energy
  • Federal Government
  • Finance
  • Healthcare
  • Higher Education
  • K-12 Education
  • Manufacturing
  • Retail
  • State and Local Government
  • Cybersecurity for SMB
  • Resources
  • Blog
  • Labs
  • Case Studies
  • Videos
  • Product Tours
  • Events
  • Cybersecurity 101
  • eBooks
  • Webinars
  • Whitepapers
  • Press
  • News
  • Ransomware Anthology
  • Company
  • About Us
  • Our Customers
  • Careers
  • Partners
  • Legal & Compliance
  • Security & Compliance
  • Investor Relations
  • S Foundation
  • S Ventures

©2026 SentinelOne, All Rights Reserved.

Privacy Notice Terms of Use

English