Join the Cyber Forum: Threat Intel on May 12, 2026 to learn how AI is reshaping threat defense.Join the Virtual Cyber Forum: Threat IntelRegister Now
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
    • AI Data Pipelines
      Security Data Pipeline for AI SIEM and Data Optimization
    • 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-31480

CVE-2025-31480: PostgreSQL aiven-extras Escalation Flaw

CVE-2025-31480 is a privilege escalation vulnerability in the PostgreSQL aiven-extras extension that allows attackers to elevate to superuser privileges. This article covers technical details, affected versions, and mitigation.

Updated: January 22, 2026

CVE-2025-31480 Overview

CVE-2025-31480 is a privilege escalation vulnerability affecting the aiven-extras PostgreSQL extension. This vulnerability allows attackers to elevate their privileges to superuser within PostgreSQL databases that use the aiven-extras package. The flaw exists because the format function is not schema-prefixed, enabling attackers to exploit untrusted search path issues (CWE-426) to achieve unauthorized privilege escalation.

Critical Impact

Attackers with high privileges can escalate to superuser status within PostgreSQL databases, potentially compromising database integrity, accessing sensitive data across tenants, and executing arbitrary database operations with elevated permissions.

Affected Products

  • aiven-extras PostgreSQL extension versions prior to 1.1.16
  • PostgreSQL databases utilizing the aiven-extras package
  • Aiven managed database services running vulnerable extension versions

Discovery Timeline

  • 2025-04-04 - CVE-2025-31480 published to NVD
  • 2025-04-07 - Last updated in NVD database

Technical Details for CVE-2025-31480

Vulnerability Analysis

This privilege escalation vulnerability arises from an untrusted search path issue within the aiven-extras PostgreSQL extension. The core problem lies in the use of the format function without proper schema qualification. When PostgreSQL functions are invoked without explicitly specifying their schema, the database engine resolves the function name using the current search_path setting. An attacker who can manipulate the search path can inject a malicious function with the same name in a schema that takes precedence, effectively hijacking the function call.

In the context of aiven-extras, this allows an attacker with existing database privileges to create a trojan format function in a schema positioned earlier in the search path. When legitimate extension code subsequently calls format(), the attacker's malicious version executes instead, running in the security context of the extension—which typically has superuser privileges.

Root Cause

The root cause is classified under CWE-426 (Untrusted Search Path). The aiven-extras extension failed to use schema-qualified function calls (e.g., pg_catalog.format() instead of just format()), leaving it vulnerable to search path manipulation attacks. This oversight allows attackers to shadow built-in PostgreSQL functions with malicious implementations.

Attack Vector

The attack is network-accessible and requires high privileges as a prerequisite. An attacker must have the ability to create functions within a database schema and manipulate the search path. Once positioned, the attacker creates a malicious function matching the unqualified function name used by aiven-extras. When the extension's code executes, the malicious function is invoked with elevated privileges, allowing the attacker to escalate to superuser.

The attack scope is changed (S:C in the CVSS vector), meaning successful exploitation can impact resources beyond the vulnerable component itself—potentially affecting other databases or tenants on the same PostgreSQL instance.

text
-short_ver = 1.1.15
-last_ver = 1.1.14
+short_ver = 1.1.16
+last_ver = 1.1.15
 long_ver = $(shell git describe --long 2>/dev/null || echo $(short_ver)-0-unknown-g`git describe --always`)
 generated = aiven_extras.control \
 			sql/aiven_extras--$(short_ver).sql \

Source: GitHub Commit Update

Detection Methods for CVE-2025-31480

Indicators of Compromise

  • Unexpected user-defined functions named format in non-system schemas
  • Modified or suspicious search_path configurations in database sessions
  • Unusual privilege escalation events or new superuser accounts appearing in PostgreSQL logs
  • Database objects created by users who should not have superuser access

Detection Strategies

  • Query pg_proc and pg_namespace to identify any user-created functions shadowing built-in PostgreSQL functions like format
  • Monitor PostgreSQL logs for ALTER ROLE or GRANT statements that elevate user privileges unexpectedly
  • Implement database activity monitoring to detect search path manipulations
  • Review the installed version of aiven-extras using SELECT * FROM pg_available_extensions WHERE name = 'aiven_extras';

Monitoring Recommendations

  • Enable detailed PostgreSQL logging with log_statement = 'ddl' to capture function creation and privilege changes
  • Configure alerts for any CREATE FUNCTION statements in databases with aiven-extras installed
  • Periodically audit database roles and their privilege assignments to detect unauthorized superuser accounts
  • Monitor for connections with manipulated search_path session variables

How to Mitigate CVE-2025-31480

Immediate Actions Required

  • Upgrade aiven-extras to version 1.1.16 immediately across all affected PostgreSQL instances
  • Execute ALTER EXTENSION aiven_extras UPDATE TO '1.1.16' in each database where the extension is installed
  • Audit all databases for suspicious user-defined functions that may shadow built-in functions
  • Review and restrict privileges for database users to limit who can create functions

Patch Information

Aiven has released version 1.1.16 of the aiven-extras extension to address this vulnerability. The fix ensures that function calls are properly schema-prefixed to prevent search path manipulation attacks. Users should download the update and apply it to all databases using the extension.

For detailed information, refer to the GitHub Security Advisory GHSA-33xh-jqgf-6627 and the security patch commit.

Workarounds

  • Restrict function creation privileges using REVOKE CREATE ON SCHEMA public FROM PUBLIC; and similar commands
  • Manually audit and remove any suspicious user-defined functions that could shadow PostgreSQL built-ins
  • Configure search_path at the database level to prioritize pg_catalog schema
  • Limit database access to trusted users until the patch can be applied
bash
# Update aiven-extras extension in each affected database
psql -d your_database -c "ALTER EXTENSION aiven_extras UPDATE TO '1.1.16';"

# Verify the installed version
psql -d your_database -c "SELECT extversion FROM pg_extension WHERE extname = 'aiven_extras';"

# Audit for suspicious format functions outside pg_catalog
psql -d your_database -c "SELECT n.nspname, p.proname FROM pg_proc p JOIN pg_namespace n ON p.pronamespace = n.oid WHERE p.proname = 'format' AND n.nspname != 'pg_catalog';"

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

  • Vulnerability Details
  • TypePrivilege Escalation

  • Vendor/TechAiven Extras

  • SeverityCRITICAL

  • CVSS Score9.1

  • EPSS Probability0.10%

  • Known ExploitedNo
  • CVSS Vector
  • CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:C/C:H/I:H/A:H
  • Impact Assessment
  • ConfidentialityLow
  • IntegrityNone
  • AvailabilityHigh
  • CWE References
  • CWE-426
  • Technical References
  • GitHub Commit Update

  • GitHub Security Advisory GHSA-33xh-jqgf-6627
  • Latest CVEs
  • CVE-2025-49454: TinySalt Path Traversal Vulnerability

  • CVE-2025-48261: MultiVendorX Information Disclosure Flaw

  • CVE-2025-32119: CardGate WooCommerce SQL Injection Flaw

  • CVE-2025-26879: s2Member Plugin Reflected XSS Vulnerability
Default Legacy - Prefooter | 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