Junglewise Threat Intelligence

CVE-2026-42586: Netty Redis codec CRLF injection in RedisEncoder

CVE-2026-42586 · Severity: medium · CVSS 6.8 · Published 2026-05-13

Technologies: Netty Project Codec Redis, Netty-Codec-Redis. Vendors: Netty Project, Netty.

Executive brief

Netty, a popular networking framework for Java, contains a vulnerability in its Redis protocol component. This flaw allows an attacker to inject unauthorized Redis commands or forge server responses by including special line-break characters in data sent to the application. This could lead to unauthorized data access, modification of database settings, or the deletion of all stored data.

Technical details

The vulnerability exists in the `codec-redis` module, specifically within `RedisEncoder` and several message classes like `InlineCommandRedisMessage`. The `writeString()` method in `RedisEncoder.java` writes user-controlled string content directly to the network buffer without validating or sanitizing Carriage Return Line Feed (CRLF) sequences. Because the Redis Serialization Protocol (RESP) uses CRLF as a delimiter, an attacker can inject arbitrary commands (e.g., FLUSHALL, CONFIG SET) or poison responses. This affects text-based inline commands and simple string/error response types. Patches are available in versions 4.2.13.Final and 4.1.133.Final.

Affected products

  • Netty netty-codec-redis >= 4.2.0.Alpha1, <= 4.2.12.Final; <= 4.1.132.Final

Timeline

  • 2026-05-05: advisory: GitHub Advisory published
  • 2026-05-07: disclosed: Vulnerability disclosed as CVE-2026-42586

References

Related threats