Skip to navigation

Threat reportVulnerabilityTL-2026-6439

Database RCE PoCs Affecting PostgreSQL (CVE-2026-116331), MySQL (CVE-2026-101786), Oracle Database/ORDS (CVE-2026-114819, CVE-2026-91609) and ClickHouse

criticalMONITORING

Researcher Zheng Yu (Depthfirst) published proof-of-concept remote code execution chains for PostgreSQL, MySQL, ClickHouse and an unauthenticated Oracle Database chain (Oracle Text + ORDS GraphQL). The PostgreSQL, MySQL and Oracle flaws are patched; no in-the-wild exploitation has been reported, and ClickHouse has no CVE or confirmed fixed version. First disclosed .

Key facts

IdentifiersTL-2026-6439, CVE-2026-116331, CVE-2026-101786, CVE-2026-114819, CVE-2026-91609
Also known asNarrow Grants, Wide Engines
SeverityCRITICAL
CVSS9.9
First disclosed
Affected productsPostgreSQL Global Development Group PostgreSQL; Oracle MySQL Server and MySQL Cluster; Oracle Oracle Database (Oracle Text); Oracle Oracle REST Data Services (ORDS); ClickHouse ClickHouse
MITRE ATT&CK techniquesT1059 Command and Scripting Interpreter, T1059.004 Command and Scripting Interpreter: Unix Shell, T1078 Valid Accounts, T1190 Exploit Public-Facing Application, T1203 Exploitation for Client Execution, T1587.004 Develop Capabilities: Exploits
MotivationUNKNOWN
Target sectorstechnology, finance, government administration, health, enterprise
Target regionsGlobal
Detection rules9 (1 shown free)
Sources6 cited sources

Detection coverage

As of 2026-11-19, Threadlinqs Intelligence publishes 9 detection rule(s) for TL-2026-6439 across Splunk SPL, Microsoft KQL and Sigma, covering 6 indicator(s) of compromise. The whole corpus is readable without an account. Every threat comes with one complete detection in Splunk SPL, Microsoft KQL and Sigma, free for everyone; a free account adds daily TL Creds to unlock the rest. Paid plans add a larger daily allowance, correlation and the MCP server. Threadlinqs MCP server · View plans.

Free detection: Database Server Process Spawning Shell (PostgreSQL/MySQL/ClickHouse RCE) - Post-Exploitation

Detects postgres, mysqld or clickhouse-server spawning a shell. All three Depthfirst chains (CVE-2026-116331 via system(), CVE-2026-101786, and the ClickHouse RowBinary overflow) end with command execution as the database service account, so a shell child of the engine is the highest-fidelity post-exploitation signal.

  • Languages: Splunk SPL, Microsoft KQL, Sigma
  • ATT&CK: T1059, T1059.004, T1068, T1203
  • Data sources: sysmon_for_linux, auditd, DeviceProcessEvents
  • Severity: critical
  • Confidence: high

Splunk SPL

index=linux sourcetype="sysmon:linux" EventCode=1
| where match(ParentImage,"(?i)/(postgres|postmaster|mysqld|clickhouse-server|clickhouse)$") AND match(Image,"(?i)/(sh|bash|dash|zsh|ksh|csh)$")
| stats count min(_time) as first_seen max(_time) as last_seen values(CommandLine) as commands by host User ParentImage Image
| convert ctime(first_seen) ctime(last_seen)

Microsoft KQL

DeviceProcessEvents
| where Timestamp > ago(24h)
| where InitiatingProcessFileName in~ ("postgres", "postmaster", "mysqld", "clickhouse-server", "clickhouse")
| where FileName in~ ("sh", "bash", "dash", "zsh", "ksh", "csh")
| project Timestamp, DeviceName, AccountName, InitiatingProcessFileName, InitiatingProcessCommandLine, FileName, ProcessCommandLine

Sigma

title: Database Server Process Spawning Shell
id: 6b1f2a40-7c1e-4d52-9a31-0f6d8e5c1a02
status: experimental
description: Detects PostgreSQL, MySQL or ClickHouse server processes spawning a shell, the end state of the Narrow Grants Wide Engines RCE chains.
references:
    - https://depthfirst.com/research/narrow-grants-wide-engines
    - https://thehackernews.com/2026/11/researcher-demonstrates-database-rce.html
author: Threadlinqs Team
date: 2026/11/19
tags:
    - attack.execution
    - attack.t1059
    - attack.t1059.004
    - attack.privilege-escalation
    - attack.t1068
    - attack.t1203
    - cve.2026-116331
    - cve.2026-101786
logsource:
    category: process_creation
    product: linux
detection:
    selection_parent:
        ParentImage|endswith:
            - '/postgres'
            - '/postmaster'
            - '/mysqld'
            - '/clickhouse-server'
            - '/clickhouse'
    selection_child:
        Image|endswith:
            - '/sh'
            - '/bash'
            - '/dash'
            - '/zsh'
            - '/ksh'
            - '/csh'
    condition: selection_parent and selection_child
falsepositives:
    - PostgreSQL archive_command or restore_command or COPY PROGRAM configured by administrators
    - ClickHouse executable user-defined functions or dictionaries that invoke scripts
level: critical

Known false positives:

  • archive_command / restore_command / COPY PROGRAM used by DBAs
  • ClickHouse executable UDFs or MySQL backup wrappers invoked from the service

Tuning notes: Allowlist exact CommandLine values for archive_command and backup scripts. Require ParentImage to be the database binary path. Enrich with User to confirm the service account.

8 more detection rules (Splunk SPL, Microsoft KQL, Sigma) · unlock with TL Creds. Sign up free to unlock the detection rules or query them with the Threadlinqs MCP server (Purple)
  • ClickHouse HTTP Request Setting format_binary_max_string_size=0 - Exploitation · unlock with TL Creds
  • Oracle Database or ORDS Process Spawning Shell or Download Tool (CVE-2026-114819 / CVE-2026-91609) - Post-Exploitation · unlock with TL Creds
  • Reverse Shell Command Line Run by Database Service Account - C2 · unlock with TL Creds
  • MySQL Windowed BIT_OR Abuse and Oversized-Operand Rejection (CVE-2026-101786) - Exploitation · unlock with TL Creds
  • Database Engine Backend Crash by Memory-Corruption Signal - Post-Exploitation / Failed Exploitation · unlock with TL Creds
  • External Access to Oracle ORDS GraphQL Endpoint (CVE-2026-91609 + CVE-2026-114819 pre-auth chain) · unlock with TL Creds
  • PostgreSQL CREATE AGGREGATE with SORTOP by Non-Admin Role (CVE-2026-116331) - Exploitation · unlock with TL Creds
  • Database Service Account Outbound Connection to Public IP (Reverse Shell / C2) - C2 · unlock with TL Creds

Indicators of compromise

As of 2026-11-19, Threadlinqs Intelligence tracks 6 indicators of compromise for TL-2026-6439.

6 indicators of compromise · unlock with TL Creds. Compare plans

Technical analysis

Depthfirst researcher Zheng Yu showed that session-scoped database privileges, which are commonly treated as harmless, are enough to reach memory-corruption bugs in native engine code and turn them into operating-system command execution as the database service account. The research ("Narrow grants, wide engines") was published around 2026-11-18 and covered by The Hacker News on 2026-11-19. The article states that no in-the-wild exploitation has been seen and that the full chains were not independently reproduced by the reporter.

PostgreSQL (CVE-2026-116331): a type confusion in the min/max aggregate optimization. A user-defined aggregate created with the SORTOP option makes the planner rewrite the aggregate into a B-tree index lookup and skip FINALFUNC, so the caller reads a raw value with the wrong type (pass-by-value vs pass-by-reference confusion on 64-bit builds). Per Depthfirst the chain yields an information leak, an ASLR bypass and a control-flow hijack through an expanded-object method table leading to system(). It needs only the default TEMPORARY privilege on the database, working entirely inside the role's own pg_temp schema without touching application data. The PostgreSQL advisory rates it CVSS 8.8 (AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H), affecting all versions before 18.7, 17.12, 16.16, 15.20 and 14.25; fixes were released 2026-11-12.

MySQL (CVE-2026-101786, Server: Optimizer, MySQL Server and Cluster 26.7.0-26.7.1): an out-of-bounds write in windowed BIT_OR. Item_sum_bit::resolve_type() sizes the counter array for a 511-byte binary value at prepare time, while add_bits() trusts the longer runtime value and its only bounds check is a debug assert. Depthfirst reached code execution as the mysql service account on the official 26.7.0 image with an account holding only CREATE TEMPORARY TABLES ON *.* and no SELECT on application tables. Oracle's October 2026 CPU rates it CVSS 7.2 (PR:H); the article argues the real prerequisite is narrower than that rating implies. The upstream patch rejects oversized operands at runtime for window functions (ER_INVALID_BITWISE_AGGREGATE_OPERANDS_SIZE).

Oracle Database (CVE-2026-114819, Oracle Text, CVSS 9.9; 19.3-19.32, 21.3-21.24, 23.4.0-23.26.3) and Oracle REST Data Services (CVE-2026-91609, GraphQL interface, 24.2.0-26.2.1): chained against an exposed ORDS HTTP endpoint, an unauthenticated attacker can smuggle a crafted document into the database and execute commands as the OS service user before any login. Oracle does not rate either flaw as exploitable without login individually. ORDS was fixed in the October 2026 CPU (2026-10-20) and the database in the November 2026 update (2026-11-17). Primitive-level details are not public (closed source). Note: the Oracle advisory pages returned HTTP 403 to the research client, so Oracle details rely on the Hacker News article and Depthfirst post.

ClickHouse (no CVE assigned): in the RowBinary string deserializer the new buffer size is old size plus declared length without a limit; a length near UINT64_MAX wraps the offset and shrinks the vector without reallocating, so later reads write out of bounds. An unprivileged HTTP caller can set format_binary_max_string_size=0 in the query string under default configuration, disabling the length check; with CREATE TEMPORARY TABLE ON *.* Depthfirst obtained an interactive shell as the clickhouse account on 26.7.5.10. No fixed version is confirmed.

No threat actor, malware family, or network IOCs are associated with this research; the IOC section records detection-relevant artifacts (settings, DDL constructs, error codes, privileges, endpoints) rather than attacker infrastructure, so BeaconBeagle correlation was not applicable.

MITRE ATT&CK techniques by tactic:

Execution

T1059 Command and Scripting Interpreter; T1059.004 Command and Scripting Interpreter: Unix Shell; T1203 Exploitation for Client Execution

Initial Access

T1078 Valid Accounts; T1190 Exploit Public-Facing Application

Resource Development

T1587.004 Develop Capabilities: Exploits

Remediation

Patches

  • PostgreSQL 18.7 / 17.12 / 16.16 / 15.20 / 14.25
  • Oracle Critical Patch Update October 2026 (MySQL, ORDS)
  • Oracle Security Update November 2026 (Oracle Database / Oracle Text)

Immediate actions

  • Upgrade PostgreSQL to 18.7, 17.12, 16.16, 15.20 or 14.25 (released 2026-11-12)
  • Apply the Oracle October 2026 CPU (MySQL 26.7.x, ORDS) and the November 2026 Oracle Database update (2026-11-17)
  • Restrict network exposure of Oracle REST Data Services (ORDS) endpoints, especially the GraphQL interface, to trusted networks
  • Revoke the default TEMPORARY privilege from PUBLIC on PostgreSQL databases where not needed

Workarounds

  • PostgreSQL: REVOKE TEMPORARY ON DATABASE ... FROM PUBLIC for roles that do not need temporary objects
  • MySQL/ClickHouse: remove temporary-table rights from application accounts that do not need them
  • ClickHouse: no confirmed fix; restrict HTTP interface access and constrain user ability to change format_binary_max_string_size (e.g. via settings constraints)

Longer-term hardening

  • Review what database accounts can do, not only what they can read; avoid broad CREATE TEMPORARY TABLES ON *.* grants in MySQL and ClickHouse
  • Run database services as dedicated least-privilege OS accounts and monitor child process creation from database server processes
  • Track ClickHouse vendor releases for a confirmed fix

Affected and fixed versions

  • PostgreSQL Global Development Group — PostgreSQL
    Vulnerable versions: Before 18.7; Before 17.12; Before 16.16; Before 15.20; Before 14.25
    Fixed in: 18.7; 17.12; 16.16; 15.20; 14.25
  • Oracle — MySQL Server and MySQL Cluster
    Vulnerable versions: 26.7.0; 26.7.1
    Fixed in: See MySQL release notes (October 2026 CPU)
  • Oracle — Oracle Database (Oracle Text)
    Vulnerable versions: 19.3-19.32; 21.3-21.24; 23.4.0-23.26.3
    Fixed in: November 2026 security update (2026-11-17)
  • Oracle — Oracle REST Data Services (ORDS)
    Vulnerable versions: 24.2.0-26.2.1
    Fixed in: October 2026 CPU (2026-10-20)
  • ClickHouse — ClickHouse
    Vulnerable versions: 26.7.5.10 (tested)

Timeline

  • Oracle REST Data Services GraphQL flaw CVE-2026-91609 (24.2.0-26.2.1) fixed in the October 2026 CPU
  • Oracle October 2026 CPU / MySQL advisory published for CVE-2026-101786 (MySQL Server and Cluster 26.7.0-26.7.1, Optimizer, CVSS 7.2)
  • PostgreSQL releases 18.7, 17.12, 16.16, 15.20 and 14.25 fix CVE-2026-116331 (CVSS 8.8), alongside PostgreSQL 19 RC 2
  • Oracle November 2026 security update fixes Oracle Text CVE-2026-114819 (CVSS 9.9) in Oracle Database
  • Depthfirst's Zheng Yu publishes 'Narrow grants, wide engines' with RCE chains for PostgreSQL, MySQL, ClickHouse and Oracle (approximate date per press coverage)
  • The Hacker News reports the research; no in-the-wild exploitation seen and ClickHouse has no CVE or confirmed fixed version

Sources cited

Other reports on CVE-2026-116331

Drafted by the Threadlinqs research pipeline from 6 sources; published ; last updated —.

Threadlinqs Intelligence — Real-Time Threat Detection Platform

// threat_feed
$ sort --newest
Showing all threats

Live intelligence console

Threat level

Latest Threats