You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "steveloughran (via GitHub)" <gi...@apache.org> on 2026/07/06 12:32:10 UTC
Re: [PR] Core, Data: Validate deletion-vector offset and length [iceberg]
steveloughran commented on code in PR #16500:
URL: https://github.com/apache/iceberg/pull/16500#discussion_r3528877741
##########
core/src/main/java/org/apache/iceberg/DVUtil.java:
##########
@@ -64,6 +65,35 @@ static PositionDeleteIndex readDV(DeleteFile deleteFile, FileIO fileIO) {
}
}
+ /**
+ * Validates that the deletion-vector offset and length on a {@link DeleteFile} are well-formed
+ * before they are consumed by a reader. Hostile or corrupted manifest metadata may otherwise
+ * trigger a {@link NegativeArraySizeException}, an invalid seek, or a multi-gigabyte allocation
+ * when the DV blob is read.
+ */
+ public static void validateDV(DeleteFile dv) {
+ Preconditions.checkArgument(
Review Comment:
makes sense. the factoring of the construction works though, really makes clear what it is that you have set.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org