[
https://issues.apache.org/jira/browse/AVRO-4247?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18080896#comment-18080896
]
ASF subversion and git services commented on AVRO-4247:
-------------------------------------------------------
Commit 5242f3fbff4d6ebd31b1188869e058f09f48a9a1 in avro's branch
refs/heads/branch-1.11 from Ismaël Mejía
[ https://gitbox.apache.org/repos/asf?p=avro.git;h=5242f3fbff ]
AVRO-4247: [Java] Enforce decompression size limits (#3745)
Cherry-pick of d28279dace from master with Java 8 compatibility fixes:
- Replace Objects.checkFromIndexSize() (Java 9+) with manual bounds check
- Replace ByteArrayOutputStream.writeBytes() override (Java 11+) with
standalone method delegating to write(b, 0, b.length)
> Avro compression codecs should verify decompression size
> --------------------------------------------------------
>
> Key: AVRO-4247
> URL: https://issues.apache.org/jira/browse/AVRO-4247
> Project: Apache Avro
> Issue Type: Bug
> Components: java
> Affects Versions: 1.12.1
> Reporter: Ismaël Mejía
> Assignee: Steve Loughran
> Priority: Blocker
> Labels: pull-request-available
> Fix For: 1.13.0, 1.12.2
>
> Time Spent: 5.5h
> Remaining Estimate: 0h
>
> {color:#1f2328}All Avro Java compression codecs (Deflate, Zstandard, XZ,
> BZip2, Snappy) decompress data without any size limit, allowing an attacker
> to craft a small Avro file (~50KB) that expands to an extremely large size
> (~50MB+), causing {color}{{OutOfMemoryError}}{color:#1f2328} and crashing the
> JVM.{color}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)