Repository navigation
feat(encryption): [10/N] Read encrypted manifests - #4308
Merged
Merged
Conversation
xanderbailey
marked this pull request as ready for review
November 8, 2026 17:35
kevinjqliu
approved these changes
Nov 9, 2026
kevinjqliu
left a comment
Contributor
There was a problem hiding this comment.
LGTM
i also just merged #4296 so the ci should be unblocked
| holding master key `master-1` = bytes `0x00` to `0x0f`. Its keys and snapshot are in the | ||
| `example_table_metadata_v3_encrypted` fixture in `tests/conftest.py`. | ||
|
|
||
| `manifest-v3-encrypted.avro` is a v3 data manifest with two added entries, written and encrypted by iceberg-rust's |
Contributor
There was a problem hiding this comment.
nit: might be a good idea to include how the tests/table/encryption/manifest-v3-encrypted.avro is generated. either in pr description/comment or in the readme.
for future readers 😄
A manifest list entry's key_metadata is the plaintext key metadata of its manifest, so fetch_manifest_entry decrypts with it when it is set, as iceberg-rust's ManifestReader does.
kevinjqliu
force-pushed
the
xb/encryption-read-manifests
branch
from
November 9, 2026 19:56
c6068ad to
221519c
Compare
Contributor
|
rebased onto latest main to get #4296 |
kevinjqliu
enabled auto-merge
November 9, 2026 19:57
Contributor
|
Thanks @xanderbailey |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Working towards #3222
Rationale for this change
Now that we can read encrypted manifest lists (#4159), we need to read the manifests they point to.
key_metadataholds the manifest's plaintext key metadata (key, AAD prefix and file length). That's safe because the manifest list holding it is itself encrypted, so reading a manifest doesn't need theEncryptionManageror the KMS.ManifestFile.fetch_manifest_entrydecrypts the manifest whenkey_metadatais set, matching iceberg-rust'sManifestReader([8/N] feat(encryption) [8/N] Read encrypted manifest file iceberg-rust#2586). Every manifest read goes through it, so scans,inspect, validation and purge pick this up without changes.This depends on #4296. iceberg-rust's manifest writer leaves out
avro.codec, and we currently read a missing codec as gzip (#4295), so the iceberg-rust test below fails until that lands.Are these changes tested?
Yes. An encrypted v3 manifest written by iceberg-rust is checked in under
tests/table/encryption, and reading it returns its entries. There's also a round trip of an encrypted manifest, checking that a wrong key fails and that the encrypted bytes don't read as plaintext.Are there any user-facing changes?
No. Nothing changes for unencrypted tables.