We're in the process of implementing the encryption spec in rust and python and have noticed something in the spec wording https://github.com/apache/iceberg/blob/1504ddd5d5119e934e7cbcaed82b9384caf35b82/format/gcm-stream-spec.md#cipher-block-structure `The last block has a non-zero length <= BlockLength` but Java `AesGcmOutputStream` will actually write an empty block and `AesGcmInputFile` will reject anything shorter than `MIN_STREAM_LENGTH` https://github.com/apache/iceberg/blob/1504ddd5d5119e934e7cbcaed82b9384caf35b82/core/src/main/java/org/apache/iceberg/encryption/AesGcmInputFile.java#L68-L74 So java seems to disagree in both directions? Link to python PR where this discussion came up https://github.com/apache/iceberg-python/pull/3969
Activity
ykisana commentedon Oct 1, 2026
Good catch, I think makes sense to agree with Java for this one. The rule is clear and Java is already shipped, make Python and Rust follow it.
Have PR for that: #18335