HIGH 7.5

CVE-2021-37136

Bzip2Decoder doesn't allow setting size restrictions for decompressed data

Description

Impact

The Bzip2 decompression decoder function doesn't allow setting size restrictions on the decompressed output data (which affects the allocation size used during decompression).

All users of Bzip2Decoder are affected. The malicious input can trigger an OOME and so a DoS attack

Workarounds

No workarounds other than not using the Bzip2Decoder

References

Relevant code areas:

https://github.com/netty/netty/blob/netty-4.1.67.Final/codec/src/main/java/io/netty/handler/codec/compression/Bzip2Decoder.java#L80 https://github.com/netty/netty/blob/netty-4.1.67.Final/codec/src/main/java/io/netty/handler/codec/compression/Bzip2Decoder.java#L294 https://github.com/netty/netty/blob/netty-4.1.67.Final/codec/src/main/java/io/netty/handler/codec/compression/Bzip2Decoder.java#L305

Affected Maven artifacts (3)

ArtifactAffected versionsFixed in
io.netty » netty
*
-
io.netty » netty-codec
< 4.1.68.Final
4.1.68.Final
org.jboss.netty » netty
*
-

Blast radius

3affected artifacts
360affected versions
53,486dependent artifacts (est.)
3,382,452dependent versions

73% of the dependent artifacts (39,527) still pull an affected version in their latest release.

DepthDependent versions
Direct
95,561
2 hops
461,158
3 hops
1,093,219
4 hops
898,340
5 hops
529,646
6 hops
304,528

Most used dependents

Computed from the dependency graph of build 20261124.0621 (compile and runtime scopes, nearest version wins). Exclusions and dependency management in consuming projects are not applied, so dependents are potentially affected. When several artifacts are affected, a dependent version that pulls more than one of them is counted once per artifact.

References