Remote Code Execution

RCE is any flaw that lets an attacker run attacker-chosen code or OS commands on a target, usually as the service’s process user. It is less a single bug class than the impact that many server-side classes end in.

What it is

RCE happens when attacker-controlled data crosses from the data plane into the instruction plane: some component (a shell, an interpreter, an expression engine, a deserializer, a loader, or a file handler) parses the data as something it should execute. The trust boundary that breaks is always the same assumption: “this value is only data.”

Bugcrowd frames RCE as “an impact, not a bug”, because the foothold can be file upload, command injection, SQLi, XXE, SSTI or even SSRF (RCE 101). Each sink class is a different CWE:

Sink the data reachesClassCWEPage
A shell parsing a command stringCommand injectionCWE-78Command Injection
A fixed binary’s argv (no shell)Argument injectionCWE-88Argument Injection
The app’s own language runtime (eval, pickle, template compiler)Code injectionCWE-94Code Injection
OGNL / SpEL / MVEL / EL evaluatorsEL injectionCWE-917Expression Language Injection
A template engineSSTICWE-1336Server-Side Template Injection
An object deserializerInsecure deserializationCWE-502Java Deserialization, Unsafe Python Functions
A file the server later executesUnrestricted uploadCWE-434Unrestricted File Upload, Web Shells
A naming/directory lookup that loads classesJNDI injectionCWE-917/502Log4Shell
Memory corruption in a parser/decoderMemory safetyCWE-787/416(cases below)

Why it matters

Impact ladder. A single command as the web user, then reading app secrets (.env, cloud credentials, DB strings), then lateral movement and cloud pivot, then root on appliances where everything runs as root (Citrix NetScaler, Zyxel), then persistence through a web shell or implant. In the Marimo case (CVE-2026-39987) attackers went from first probe to .env credential theft in under 3 minutes (Marimo exploited within hours).

Severity drivers.

  • Pre-auth vs post-auth. The “-Shell” family (Log4Shell, React2Shell, PHP2Shell, Node2Shell) needs no login: one crafted request is enough, often before any app code runs (What are shell vulnerabilities?).
  • Inherited, not written. Those bugs live in logging libraries, UI frameworks, runtimes and decoders. Careful app code is still exposed because the vulnerable code is a dependency of a dependency, or ships inside container images that are rarely rebuilt (same source).
  • Process privilege. Root-running CGIs and containers turn any sink into full compromise.
  • Credential co-location. In 5 of 20 hosted scanner platforms tested, the worker that ran untrusted repos also held the vendor’s own operational credentials, so a sandbox escape became vendor compromise (Assume Code Execution).

Time to exploit is hours, sometimes negative.

  • PHP2Shell: the first exploit request reached sensors 5.5 h before PHP shipped the fix, and the tooling carried Mirai-style loaders (ELLIO PHP2Shell).
  • Marimo: first in-the-wild attempt 9 h 41 min after the advisory, with no public PoC.
  • GreyNoise saw roughly half of exploitation surges against 18 edge vendors followed by a CVE within 3 weeks. The median lead was 11 days, and Cisco CVE-2026-20127 was exploited 39 days before disclosure (GreyNoise surge report).
  • 48% of 2025 tracked zero-days hit enterprise software and edge devices, which PRC espionage groups (UNC5221, UNC3886) favored for initial access (2025 Zero-Days in Review).

How it works

1. Injection into a command line

  • Command Injection: input is concatenated into a string that sh -c, system(), child_process.exec or subprocess(shell=True) parses, so ;, |, $() and backticks are live. Snyk documents the Python (os.system, shell=True, eval) and Go (exec.Command("sh","-c", s)) forms (Snyk Python, Snyk Go).
  • Argument Injection: there is no shell, but user data lands in argv without a -- separator, so a leading - turns into a flag (git --exec, hg --config=hooks.*, rg --pre, php-cgi -d).
subprocess.run(f"convert {name} out.png", shell=True)   # command injection
subprocess.run(["git", "rebase", branch])               # argument injection if branch = "--exec=..."
subprocess.run(["git", "rebase", "--", branch])         # safe: end-of-options

2. Injection into an interpreter

3. Deserialization

Attacker bytes become an object graph whose magic methods or gadget chains execute. Look for serialized blobs in cookies, parameters and headers across Java, .NET, PHP, Python and Node (Insecure deserialization across languages). See Java Deserialization.

4. Lookups and dynamic loading

  • Log4Shell (CVE-2021-44228): a logged ${jndi:...} makes the JVM fetch and instantiate a remote class.
  • Spring4Shell (CVE-2022-22965): data binding lets a request reach class.module.classLoader and reconfigure the server to write an executable file (Spring4Shell step by step).
  • Unrestricted class instantiation: Oracle EBS CVE-2026-114925, an OA Framework REST handler instantiates Java classes named in request input with no allowlist; chained with the CVE-2026-114924 function-authorization bypass (CWE-306) it gives unauthenticated OS command execution on the app tier, 12.2.3-12.2.15 (Horizon3 Oracle EBS).

5. Write primitive, then execution

  • Unrestricted File Upload places a web shell under an active handler.
  • Any arbitrary file write reduces to path control + content control + a known-executed destination. The hard part is the third term, especially in distroless or read-only containers. Ethiack’s DEF CON research catalogs destinations such as /etc/ld.so.preload and shows how to turn the write into a read primitive for fingerprinting (Write Once, Shell Everywhere).
  • SQLite sqlite_dbpage gives page-level writes, enough to build a loadable .so from SQL alone (SQLite dbpage to RCE).
  • Renderers that cache files: dompdf can be made to cache a .php “font” in its font cache through injected CSS, which is then requested directly (dompdf XSS to RCE). See SSRF in PDF and HTML Renderers.

6. Exposed execution features

Some RCE involves no injection at all: the feature is code execution and only access control was missing.

  • Marimo’s /terminal/ws WebSocket skipped auth.
  • AEM’s GroovyConsole was reachable behind a bypassable Dispatcher (RCE 101).
  • JDWP debug ports were exposed in TeamCity, Jenkins and Spring Boot and exploited for miners (Exposed JDWP).
  • Spring Boot Actuator misconfigurations: /heapdump leaks and Spring Cloud Gateway routes (CVE-2022-22947) (Actuator misconfigurations).

7. Sandbox escapes

Apps that run untrusted code (plugins, notebooks, CI, AI agents) depend on an isolation layer, and the escape is the bug.

  • vm2 builds its boundary inside one V8 context using proxies. That design has produced roughly two dozen escapes, including a CVSS 10 escape reachable through the README’s own require.external example config (GitLab vm2). Its hand-maintained feature list lags the language spec by design (vm2's next escapes).
  • isolated-vm uses a real V8 isolate. GHSA-864f-rcv7-6rh4 broke the data-transfer code instead: type confusion in ExternalCopy led to host memory corruption and control-flow hijack (isolated-vm escape).
  • Redis CVE-2025-49844 (“RediShell”): a UAF reachable from a crafted Lua script escapes the Lua sandbox to native code (RediShell).
  • Ghostscript CVE-2026-125396 (fixed 10.08.0): a font-loading UAF switches off -dSAFER. ImageMagick, Pillow, libvips and Qt plugins hand PostScript/EPS to Ghostscript even when the file is named .png/.jpg/.pdf, so thumbnailing, previews, print queues, Roundcube attachments and WordPress upload plugins reached it, several without login. Bundled copies in containers are not fixed by host updates (Ghostscript sandbox escape). See Unrestricted File Upload.
  • Hosted AI code sandboxes: a DEF CON 34 talk chained spreadsheet parsing past ChatGPT’s supervisor to persistent root in the sandbox, live-patched the internal Jupyter kernel, and abused the task scheduler to launder exfiltration URLs past web guardrails (Owning ChatGPT's sandbox). See AI Infrastructure Vulnerabilities.

8. Memory corruption in pre-app parsing

PHP2Shell (CVE-2026-109618, OOM corruption in the multipart parser; CVE-2026-109619, stale global state across requests) fires while PHP parses the request, before application code runs. Node2Shell/HTTP2Shell (CVE-2026-111497) sits in Brotli request-body decoding, which Express 5 and body-parser 2.x perform before auth (ELLIO, Aikido). Application testing will not find these. Inventory and patching will.

The November 2026 wave added three more:

  • nginx2root CVE-2026-123007 (nginx 1.9.5-1.31.8, HTTP/2 on): a double refund of the connection send window on stream cancel pushes send_window above 2³¹−1; the unsigned MAX − window check then wraps, the 64-bit window goes negative and reaches a memcpy length near 2⁶⁴. glibc’s backward vector copy limits the overwrite, which the public exploit turns into code execution as the worker. Preconditions are heavy: direct HTTP/2 (no terminating proxy), ~119 GiB inside the 1 h keepalive_time, AVX-512 x86-64. Fixed in 1.31.9/1.30.7 (nginx2root).
  • Ruby2Shell CVE-2026-132825: a one-byte heap overflow in string case conversion for single-byte encodings (ISO-8859-1, Windows-1252). Rack case-converts a request field while parsing a crafted form, so default Rails and classic Sinatra apps are reachable pre-auth. Six sibling regex-engine and case-conversion bugs shipped in the same release (4.0.10, 3.4.13, 3.3.14). Regex bugs need attacker-controlled patterns; gem updates don’t replace the interpreter (Ruby2Shell).
  • phpAfterShell CVE-2026-115560 (session serializer mismatch, RCE) and CVE-2026-126714 (partially overwritten session files), fixed in PHP 8.2.36/8.3.37/8.4.28/8.5.13. Exposure hinges on session.upload_progress.enabled and inconsistent session.serialize_handler across FPM pools, vhosts and CLI jobs sharing session storage (NetSPI phpAfterShell). CVE-2026-126714 (CVSS 4.0 9.2) exists because PHP rewrites the session file from offset 0 without truncating first: an interrupted write leaves new data followed by the old tail, which session_start() then deserializes. It needs file-backed sessions, a way to plant data (upload progress, or large user strings in $_SESSION), an interruption mid-write, and a gadget path; depthfirst reached RCE without an app gadget via a second, undisclosed memory bug in a PHP-native class (SecurityWeek, Cloudflare). A WAF can only block the planting requests: the deserialization happens inside PHP, and session data copied from a DB, queue or upstream API never crosses it. Interim mitigations: session.upload_progress.enabled=0 (an explicit ini setting overrides the new default), less untrusted data in sessions, restart every FPM worker after upgrading. See PHP Object Injection.

Where to find it

  • Process spawners: image, video and document conversion (ImageMagick, ffmpeg, LaTeX), VCS operations (git and hg with user branch names, revisions, push options), network diagnostics (ping or traceroute fields), backup and export features, appliance CGIs.
  • Interpreters and evaluators: workflow and automation expressions (n8n), formula fields, rule engines, “custom script” or plugin uploads (Groovy, Jython), notebook and terminal endpoints, admin consoles (GroovyConsole, Jenkins script console).
  • Deserializers: session cookies (Flask/pickle, Java rO0, .NET ViewState), RPC frameworks (RSC Flight, RMI, .NET Remoting, XML-RPC, CORBA/IIOP), cache stores, ML model and dataset loaders, config-management reports (Puppet /puppet/v3/report).
  • Non-HTTP platform listeners enabled by a server profile, not by the app (WildFly IIOP on 3528).
  • Document renderers invoked indirectly by image libraries (Ghostscript under ImageMagick/Pillow/libvips).
  • Template sinks: email templates, PDF and report generators, CMS theme editors, user-controlled template names.
  • Logging: any header or field that gets logged (Log4Shell used User-Agent and X-Forwarded-For).
  • Write primitives: upload endpoints, archive extraction, path-traversal writes, DB file writes, renderer caches.
  • Infra surfaces: exposed debug ports (JDWP), Actuator, Consul, admission controllers (IngressNightmare), CI runners, git push pipelines.
  • Source exposure first: an exposed .git/ dumped with git-dumper revealed source that shelled out to bash scripts for FTP user management, which led to RCE on four hosts for $10k (Exposed .git to RCE). See Secrets in Git History.
  • AI agents and coding tools: “safe command” allowlists, tool calls built by string interpolation, repo config auto-executed on open. See AI Coding Assistant Risks and MCP Security.

How to test

  1. Fingerprint the stack and versions. Search for known RCEs in the CMS, framework and appliance before fuzzing (RCE 101). Many critical findings are n-days on exposed products.
  2. Map every input-to-sink path. Walk each feature in Burp and note where input plausibly reaches a converter, VCS call, template, evaluator, deserializer, logger or file write.
  3. Pick a class-appropriate, harmless oracle:
    • Shell sinks: a time delay or an OOB DNS/HTTP callback before anything else (see Out-of-Band Detection).
    • Argv sinks: a value starting with - that changes behavior (an error message, a --help-style response).
    • Template/EL sinks: arithmetic probes ({{7*7}}, ${7*7}, #{7*7}) to fingerprint (SSTI Detection).
    • Deserializers: identify the format by magic bytes and use a DNS-only gadget to confirm.
    • JNDI/lookups: a DNS-scheme lookup to your collaborator.
  4. Confirm blind execution out of band. Most real sinks are blind. Treat a DNS hit carrying a computed value as proof, not a delay alone.
  5. If metacharacters are filtered, pivot classes. Move from command injection to argument injection (GTFOBins-style flags), or from a filtered template to context enumeration.
  6. For write primitives, fingerprint before you guess. Use the write (or a paired read) to learn the OS, runtime and container layout, then choose a known-executed destination.
  7. Prove minimal impact (id, hostname, a canary file) and stop. Don’t pivot on production targets without authorization.

Checklist

  • Every conversion, VCS, network-tool and export feature probed with time and OOB oracles
  • User values in argv tested with a leading -
  • Template/EL probes in every reflected or rendered field, including email and PDF templates
  • Cookies, hidden fields and RPC bodies checked for serialized formats
  • Logged headers tested with a DNS-only JNDI-style lookup
  • Upload ladder: Content-Type, extension, config file, magic bytes, polyglot, race
  • Exposed consoles, debug ports, Actuator and .git/ enumerated
  • Dependency inventory checked for the current “-Shell” CVEs
  • AI agent and tool features tested for prompt injection leading to tool/argument injection

Exploitation and escalation

RCE is usually the end of a chain. Common paths (see Vulnerability Chaining):

  • SSRF → internal service → RCE. A blind SSRF in Yahoo Mail’s logoGrabber was escalated with gopher to RCE for $15k (Just Gopher It). See Gopher Protocol SSRF and Server-Side Request Forgery.
  • SQLi → RCE. One pentest found a DB-derived filename fed to a PHP include, so SQLi controlled what got included (SQL injection to RCE). wp2shell reached unauthenticated RCE in WordPress core via SQLi. See SQL Injection.
  • LFI → RCE. Inject code into a log the server writes (an access-log User-Agent), then include that log (LFI to RCE via access log).
  • File read → secret → deserialization RCE. At Google DevSite, the OAuth client secret was reused as Flask SECRET_KEY, which allowed forged session cookies carrying a pickle and pickle.loads RCE, paid $90k ($90k Google RCE). KindaRails2Shell (CVE-2026-66066) chains arbitrary file read through libvips in Active Storage to RCE on default Rails 7/8 apps that accept untrusted images (KindaRails2Shell).
  • Content-Type confusion → file read → takeover. n8n “Ni8mare” CVE-2026-21858 (CVSS 10): a body-parsing confusion lets the attacker control req.body.files, read local files, and fully take over about 100k instances (Ni8mare).
  • Low-priv account → feature abuse. XSS got an editor role, and the editor’s LaTeX-to-PDF feature then gave file read and command execution (LaTeX to RCE).
  • Config store → EL. An exposed Consul feeds a SpEL-evaluated property (MetaSpore). See Expression Language Injection.
  • Supply chain. An unclaimed internal npm scope name led to dependency confusion and RCE for $2.5k (Unclaimed Node package). See Dependency Confusion and Software Supply Chain Security.
  • Prompt injection → tool call → RCE. Agent “safe command” allowlists fall to Argument Injection (Trail of Bits). In Semantic Kernel, CVE-2026-25592 and CVE-2026-26030 came from unsafe string interpolation and blocklist bypasses in plugins (When prompts become shells). See Prompt Injection and Indirect Prompt Injection.
  • Post-RCE. Plant a web shell for persistence, steal credentials from env and metadata (Cloud Metadata Service Exploitation), and escalate (Privilege Escalation). PHP disable_functions lists that miss proc_open() still let a web shell run commands (disable_functions bypass).

Bypassing defenses

  • Metacharacter denylists miss $(), backticks, newline/%0a and ${IFS}. Argument injection needs no metacharacters at all (Command Injection, Argument Injection).
  • Encoding transforms re-introduce dashes. In PHP-CGI CVE-2024-4577, Windows Best-Fit maps a soft hyphen to -, which revived CVE-2012-1823.
  • Name-based sandboxes fail against rich objects. A Pydantic model’s deprecated parse_raw exposed inside a sandboxed Jinja2 context reached deserialization and RCE: enumerate the context, don’t just hunt payloads (Pydantic vs Jinja2 sandbox).
  • Compile-time vs render-time. Twig CVE-2026-46633 and Syncope’s static {} run before the sandbox or validation applies (Code Injection). Twig’s SecurityPolicy allows {% use %} unconditionally, so the primitive is reachable from sandboxed templates (Symfony Twig advisory).
  • Substring blacklists in front of SSTI. Jinja resolves \xNN string escapes after the filter has inspected the raw bytes, so a blacklist of __, os, globals, [ etc. is bypassed; the Flask app ran as root, so one request gave uid 0 (FortiPy SSTI to root). See Jinja2 SSTI.
  • Allowlists that check only the outer type. jackson-databind CVE-2026-54512: a polymorphic type id with generics (ArrayList<Gadget>) is validated only on the container, then the inner class is instantiated; fixed by recursive validation in 2.21.x (WildFly two roads). See Polymorphic Deserialization.
  • “The container isolates it.” BentoML renders an imported bento’s dockerfile_template in an unsandboxed Jinja2 Environment with jinja2.ext.do on the host, before Docker runs (BentoML GHSA-v959-cwq9-7hr6).
  • Gadget blocklists cover only the classes someone thought of. A new Oracle Coherence + Xalan chain under a ~2 KB size limit bypassed a custom blocklist on all three cluster nodes (The classes the blocklist forgot).
  • JRE hardening (trustURLCodebase=false) does not stop JNDI. Local factories (Tomcat BeanFactory) and deserialization still work (Log4Shell).
  • WAF signatures on ${jndi: fall to nested lookups (${${lower:j}ndi:...}) (Log4Shell).
  • Upload filters fall through a ladder of Content-Type spoofing, alternate extensions, .htaccess/web.config, magic-byte prefixes, polyglots, and a race between write and delete (Web shell via race). See Unrestricted File Upload.
  • Server-specific protections. WordPress plugins that protect files with .htaccess are unprotected on Nginx (Server mismatch).
  • Hidden-field trust. GitHub CVE-2026-3854: unsanitized git push options were injected into the internal X-Stat metadata header (rails_env, custom_hooks_dir, repo_pre_receive_hooks), bypassing the hook sandbox (Wiz GitHub RCE, GitHub response). The design lesson is that a delimiter-joined internal header is only as trustworthy as its least-sanitized field; the reported bounty was $100k (One Delimiter Too Many).
  • Signatures that cover a length, not the bytes executed. In an Intigriti CTF binary, the verifier hashed code_len + data_len bytes from code_offset but the executor picked which DATA block to run separately, so a signed template’s hash stayed valid while a second same-length block was executed. Hash exactly what you will execute (Hash/length mismatch to RCE).
  • Anti-CSRF tokens as a deserialization sink. Idunno.AntiCsrf deserialized its form token with an unkeyed ObjectStateFormatter, so the CSRF control itself was the pre-auth RCE (THN). See NET Deserialization.
  • Patches that fix the PoC, not the class. vm2 3.11.7 blocks the reported escape, but broad require.root with require.external stays risky (GitLab vm2).

Real-world cases

  • Log4Shell CVE-2021-44228 (CVSS 10): JNDI lookup in logged strings, mass-exploited within hours (Rapid7).
  • Confluence CVE-2021-26084: OGNL injection via queryString, coin miners then ransomware (Rapid7).
  • Spring4Shell CVE-2022-22965: data binding to classloader (Spring4Shell).
  • PHP-CGI CVE-2024-4577: Best-Fit argument injection, deployed by TellYouThePass (Wiz).
  • IngressNightmare CVE-2025-1974 (9.8): NGINX config injection into the admission controller, exposing all cluster secrets; seen in >6,500 clusters (Wiz).
  • React2Shell CVE-2025-55182: RSC Flight deserialization, unauthenticated (OffSec).
  • RediShell CVE-2025-49844: Lua sandbox UAF; affects Valkey and managed Redis (Wiz).
  • Jenkins Git Parameter CVE-2025-53652: command injection via git parameter (VulnCheck).
  • Apache Syncope CVE-2025-57738: unsandboxed Groovy implementations (SecureLayer7).
  • n8n CVE-2025-68613 / CVE-2026-21858: expression sandbox escape; Content-Type confusion takeover (Resecurity, Cyera).
  • GitHub CVE-2026-3854: git push option injection, fixed within hours, no exploitation found (GitHub).
  • Marimo CVE-2026-39987 (9.3): unauthenticated terminal WebSocket, exploited in under 10 h (eSecurityPlanet).
  • Citrix NetScaler CVE-2026-88771: pre-auth command injection in a root Perl script (watchTowr).
  • Zyxel CVE-2026-6837: PKCS#12 password into system() (writeup).
  • TeamCity CVE-2026-63077 (9.8): unauthenticated OS command execution (THN).
  • Gogs --exec: argument injection via a branch name in rebase-merge (BleepingComputer).
  • Open Build Service CVE-2026-56004: hg --config hook injection (Fenrisk).
  • Home Assistant ffmpeg: pseudo-protocol file read, then SUPERVISOR_TOKEN, then root (elttam).
  • Tailscale SSH TS-2026-009: username parsed as an option (Tailscale).
  • MLflow CVE-2026-118623: pickle evaluation artifacts (advisory).
  • Twig CVE-2026-46633: compile-time PHP injection (advisory).
  • GitLab Snippets CVE-2026-1606: CWE-94 (Rescana).
  • PHP2Shell CVE-2026-109618/109619 (9.2): pre-app RCE in PHP core, exploited before the fix (ELLIO).
  • KindaRails2Shell CVE-2026-66066: libvips file read to RCE (Ethiack).
  • GeoNetwork CVE-2026-63219 + CVE-2026-58400: unauthenticated upload plus unsafe XSLT (Ethiack).
  • ImageTragick CVE-2016-3714: image upload to delegate RCE (writeup).
  • Cisco Unified CM CVE-2026-20230: exploited to drop web shells (Help Net Security).
  • Vertex AI “Pickle in the Middle”: bucket squatting to cross-tenant pickle RCE (Unit 42).
  • Puppet Server CVE-2026-115731: __ptype rich-data deserialization to class_eval, CISA KEV 2026-11-17 (Ostorlab).
  • WildFly 32-35: pre-auth IIOP deserialization (auth after parameter read; ORBUseCodebaseOnly unset) plus jackson PTV generics bypass CVE-2026-54512 (chern0b.it).
  • Oracle EBS CVE-2026-114924 + CVE-2026-114925 (9.8 each): authz bypass chained to arbitrary class instantiation in REST services (Horizon3).
  • nginx2root CVE-2026-123007: HTTP/2 flow-control underflow, public exploit (StepSecurity).
  • Ruby2Shell CVE-2026-132825: case-conversion heap overflow, pre-auth in default Rails (THN).
  • phpAfterShell CVE-2026-115560 / CVE-2026-126714: PHP session handling (NetSPI).
  • Ghostscript CVE-2026-125396: -dSAFER escape via uploads in ~10 apps; WordPress closed its path separately as CVE-2026-65640 (THN).
  • Dataiku DSS DSA-2026-015 (8.8, CWE-1336): authenticated Jinja2 template code injection (Dataiku).
  • BentoML GHSA-v959-cwq9-7hr6: malicious bento archive to host code execution on bentoml containerize (advisory).
  • yt CVE-2026-132751: eval() on a stored dataset attribute (writeup).
  • ChatGPT sandbox (DEF CON 34): spreadsheet parsing to root, kernel patching, scheduler-based exfiltration (SecurityTabs).
  • Able2Shell (N-able N-central): 30+ AI-assisted zero-days dropped publicly with PoCs; the top chain is unauthenticated XXE in service import → trusted local session → password reset → commands as nable (plus a root privesc). N-able took hosted N-central offline worldwide (BleepingComputer, Field Effect). See XML External Entity Injection.
  • Idunno.AntiCsrf CVE-2026-131914 (9.3): unkeyed .NET ObjectStateFormatter on the CSRF form field, one unauthenticated POST to RCE in w3wp.exe; exploited in the wild, library abandoned since 2008 (THN).
  • mailcow CVE-2026-125757: domain-admin footer rendered by rspamd’s Jinja/lupa engine; macro defaults are load()ed outside the sandbox env, reaching os.execute in the shared container (PoC, vuln.today).
  • Craft CMS CVE-2026-130674: incomplete blocklist fix; title-format authors write files via ZipArchive/XMLWriter from the non-sandboxed renderObjectTemplate() (GHSA-42hj-xv33-m6rg). See Twig SSTI.
  • rConfig CVE-2026-135692: EncryptStringCast unserializes decrypted attributes with no class allowlist; a gadget stored in a device password fires on GET /api/devices (advisory).
  • binary-parser CVE-2026-134814: string-typed options (length, key, tag, offset, namely() alias) concatenated into generated JS at parser compile time (GHSA-hhq6-2gpv-hrf4). See Code Injection.
  • KindleEar CVE-2026-135436: non-admin recipe upload executed by calibre compile_recipe via exec(), root in the container (advisory).
  • Bounties: Google DevSite pickle $90k; Yahoo gopher SSRF $15k; GitLab git flag injection $12k; SEMrush logo upload $10k; exposed .git $10k (Top 25 RCE reports and the case links above).
  • Intigriti challenge 1126: a duplicate DATA command overwrote the stored data offset/length after signature verification (verify one buffer, execute another); bind verification to the exact executed bytes and reject duplicate commands. (source)
  • Metasploit wrap-up (Nov 2026): BeyondTrust RS origin-validation file upload (CVE-2026-102764) and Cisco SEG AMP file write (CVE-2026-76519) give unauthenticated RCE; Openfire CVE-2024-25420 escalates to RCE. (source)
  • Cairn agentic intrusions: path-traversal file write of sitecustomize.py, then triggering a training endpoint so a fresh Python process imported it (root shell). See Agentic Offensive Frameworks. (source)

Prevention

  • Remove the sink. Use argv APIs (execve, subprocess.run([...]), exec.Command(bin, args...), ProcessBuilder) with -- before user values. Prefer libraries over shelling out, for example a Go imaging library instead of invoking ImageMagick (Snyk Go).
  • Data parsers, not code evaluators. Use ast.literal_eval, JSON.parse and yaml.safe_load. Never deserialize untrusted pickle, Java or .NET streams; use signed, schema-validated formats. Use safetensors-style formats for ML weights.
  • Restricted evaluation contexts. Use SpEL SimpleEvaluationContext, OGNL member-access restrictions, sandboxed template environments, and never take template source or template names from users. A sandbox is defense in depth, not the fix (Pydantic/Jinja2, Twig). BentoML’s fix was SandboxedEnvironment plus removing jinja2.ext.do/ext.debug.
  • Authenticate before parsing, validate everything parsed. WildFly’s fix moved authentication above the parameter read and forced ORBUseCodebaseOnly; jackson’s fix validates nested type parameters. Instantiate only allowlisted classes from request input (Oracle EBS).
  • Shrink parser reach. Disable session.upload_progress if unused (set in php.ini/FPM pool; ini_set() is too late), keep session.serialize_handler consistent across everything sharing a session store, disable Puppet CA autosign or use policy-based autosign, and restrict TCP 8140 (NetSPI, Ostorlab).
  • Isolation for untrusted code. Don’t rely on in-process JS sandboxes (vm2). Use separate processes, isolates or containers, and keep credentials out of the worker that executes untrusted input (Assume Code Execution).
  • Uploads. Validate content by re-encoding, allowlist extensions, store outside the web root on noexec with randomized names, and never let users control the storage path or .htaccess.
  • Lock down execution features. Authenticate terminals, consoles, Actuator, JDWP, Consul and admission webhooks, and keep them off the internet.
  • Patch velocity and inventory. Exploitation now precedes or closely follows disclosure. Keep an SBOM so “-Shell” bugs in transitive dependencies and base images can be found and rebuilt quickly. Apply vendor stopgaps where they exist (VIPS_BLOCK_UNTRUSTED, Log4j JndiLookup removal). See SBOM and Provenance.
  • Contain the blast radius. Use non-root service users, seccomp, read-only roots and egress filtering. Egress filtering also blocks OOB callbacks and reverse shells.

Tools

  • Burp Suite + Collaborator for blind OOB confirmation, and BChecks injection checks for custom scanning (PortSwigger BChecks).
  • SSTImap and PayloadsAllTheThings for template-engine fingerprinting (pwnatlas SSTI).
  • ysoserial (Java/.NET), phpggc (PHP), and pickle tooling for deserialization gadget testing (pwnatlas deser).
  • git-dumper and nuclei for exposed source and known-CVE sweeps (Exposed .git).
  • Semgrep (including the Log4j lookup-injection rule), CodeQL and Bandit for sink discovery in source (Semgrep Log4j rule, ML hosting study). See Python SAST Tools.
  • Build Canaries for testing whether scanners, CI or ingestion run repository-controlled hooks (Assume Code Execution).
  • GTFOBins for flag-to-execution mappings in argument injection.

Sub-pages

  • Command Injection: shell metacharacter breakout into sh -c sinks (CWE-78).
  • Argument Injection: flag smuggling into a fixed binary’s argv, no shell needed (CWE-88).
  • Code Injection: input evaluated as code by eval, pickle or template compilers (CWE-94).
  • Expression Language Injection: OGNL, SpEL and MVEL evaluation reaching java.lang.Runtime (CWE-917).
  • Log4Shell: CVE-2021-44228 JNDI lookup injection and the state of JNDI exploitation.
  • Unrestricted File Upload: the validation-bypass ladder for landing executable files (CWE-434).
  • Web Shells: post-write payloads, polyglots, detection and persistence.

Related topics: Server-Side Template Injection · Java Deserialization · Unsafe Python Functions · Python Sandbox Escapes · Gopher Protocol SSRF · Server-Side Request Forgery · SSRF in Image and Media Processors · SSRF in PDF and HTML Renderers · SQL Injection · XML External Entity Injection · AI Infrastructure Vulnerabilities · Python AI and ML Framework Vulnerabilities · Prompt Injection · AI Coding Assistant Risks · MCP Security · Dependency Confusion · Software Supply Chain Security · CI-CD Pipeline Attacks · Out-of-Band Detection · Vulnerability Chaining · Privilege Escalation

See also: Insecure Deserialization · Prototype Pollution

See also: Path Traversal · Zip Slip and Archive Extraction

Sources