# GHSA-3X2M-C67V-VW77: DLP/WAF rule inside every documented validation limit overflows a 2048-byte stack buffer in the enforcer dataplane

- Database: GitHub
- Severity: CVSS 9.4 (Critical)
- Published: 2026-11-20
- Modified: 2026-11-20

## Tracked as

- [CVE-2026-127182](https://cve.now/CVE-2026-127182.md): SUSE NeuVector remote crash or code execution in DLP/WAF enforcer

## Affected versions

- github.com/neuvector/neuvector (Go): from 5.6.0

## Description

### Impact

A stack-based buffer overflow (CWE-121 / CWE-787 out-of-bounds write) exists in the NeuVector Enforcer dataplane and is reachable from the Controller REST API via DLP (Data Loss Prevention) and WAF sensor/rule configuration.

When a DLP or WAF rule is distributed to Enforcers, the dataplane builds a signature string by writing each rule's name and patterns into a fixed 2048-byte stack buffer (`char dlpsig_buf[MAX_USER_SIG_LEN]` in `dp/dpi/sig/dpi_sig.c`) using unbounded `sprintf()` calls. The 2048-byte length check only runs *after* the buffer has already been filled, so it validates data in the very buffer it was meant to protect. The Controller-side validator (`validateDlpRuleConfig()` in `controller/rest/dlp_rule.go`) counts raw pattern lengths against the documented limits *before* rewriting wildcards (`*` → `.*`), and performs no re-check afterwards, so a rule that respects every documented limit can still expand past 2048 bytes once framed and written by the dataplane.

**What the vulnerability allows:**

- An out-of-bounds stack write in the Enforcer dataplane, a privileged, host-networked DaemonSet process.
- At minimum, a crash of the dataplane on every node that receives the rule, resulting in a persistent, cluster-wide loss of DLP/WAF inspection and network enforcement. Because the rule is stored in cluster configuration, it is re-parsed on every Enforcer restart or join, so the effect is sticky and cluster-wide.
- Depending on the Enforcer build hardening and stack layout, controlled corruption of attacker-chosen bytes may be leveraged toward code execution in the privileged container.

**Privileges required:** An authenticated account with permission to create or update DLP/WAF configuration. DLP sensors are domain-scoped, so a namespace-scoped administrator — not only a global NeuVector admin — can reach this path. No user interaction and no special deployment configuration are required; exploitation is deterministic.

**Affected components:** Enforcer dataplane (`dp`, C) and the Controller REST API / Manager UI configuration path (`controller/rest/dlp_rule.go` and the WAF equivalent). The CRD ingestion path should also be reviewed as a second entry point.

#### Preconditions

- Network reachability to the Controller REST API or Manager UI.
- A NeuVector account authorized to write DLP or WAF sensor/rule configuration (including domain/namespace-scoped roles).
- A separate validation gap compounds this: because all length checks are gated on the pattern `op` field, supplying an unrecognized `op` value bypasses the length, context and PCRE-compile checks entirely, allowing substantially larger unvalidated payloads to reach the dataplane.

**Note:** Only the minimum information needed to detect and mitigate the issue is provided here. Operators can detect exposure by auditing DLP/WAF sensors for rules with unusually large or many patterns, or with unexpected `op` values, and by watching for Enforcer dataplane crash-loops after rule changes.

### Patches

This vulnerability has been fixed in the following NeuVector versions:

- `>= 5.7.0`
- `>= 5.6.5`
- `>= 5.5.6`

The fix bounds the dataplane signature writes and corrects the Controller-side validation (post-expansion length enforcement and explicit rejection of unknown `op` values). A defense-in-depth build change additionally enables stack-protection compiler flags (`-fstack-protector-strong`) for the Enforcer.

Users are advised to upgrade to a fixed version as soon as possible.

### Workarounds

There is no complete workaround. As a mitigation, restrict DLP and WAF configuration permissions to trusted administrators only, and audit existing DLP/WAF sensors and rules for oversized or malformed patterns and unexpected `op` values until the upgrade is applied.

### References

- [CVE-2026-127182](https://nvd.nist.gov/vuln/detail/CVE-2026-127182)
- [NeuVector Security Advisories](https://github.com/neuvector/neuvector/security/advisories)
- Affected code: `dp/dpi/sig/dpi_sig.c` (`dpi_sig_bld`, `MAX_USER_SIG_LEN`), `controller/rest/dlp_rule.go` (`validateDlpRuleConfig`)

### For more information

If you have any questions or comments about this advisory:

- Open an issue in the [neuvector/neuvector](https://github.com/neuvector/neuvector/issues) repository
- Email the NeuVector security team

### Credits

- Reported by Adel Zaitri (contact@adelzaitri.com) through coordinated disclosure.

## References

- https://github.com/neuvector/neuvector/security/advisories/GHSA-3x2m-c67v-vw77

Page: https://cve.now/GHSA-3X2M-C67V-VW77

Wrong or missing data? Send feedback: POST https://cve.now/api/v1/feedback (see https://cve.now/agents#feedback).
