Repository navigation
[python] Apply query authorization to the Daft blob-table native read - #10026
Merged
JingsongLi merged 1 commit intoSep 21, 2026
Merged
Conversation
plusplusjiajia
force-pushed
the
fix/pypaimon-daft-blob-auth
branch
2 times, most recently
from
September 20, 2026 17:32
d0c6232 to
322e04d
Compare
plusplusjiajia
force-pushed
the
fix/pypaimon-daft-blob-auth
branch
from
September 20, 2026 17:35
322e04d to
f10140c
Compare
JingsongLi
reviewed
Sep 21, 2026
JingsongLi
left a comment
Contributor
There was a problem hiding this comment.
Requirement fit: SUPPORTED (triage: GO)\nImplementation: CLEAN\n\nThis has direct security value: scalar-only BLOB reads can no longer route authorized queries through Daft native parquet and bypass row filters or masks. I reviewed both native-file call sites, the PyPaimon fallback, zero-column row-count preservation, and the authorization tests and found no actionable P0/P1/P2 issue.
XiaoHongbo-Hope
pushed a commit
that referenced
this pull request
Oct 8, 2026
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.
Problem
A blob table never reaches Daft's native parquet reader through
use_native_reader:_reader_routingrules it out on_has_blob_columnsbefore it ever looks athas_auth, so that refusal is dead code for such a table. It reaches the native reader through_blob_table_native_files, which hands Daft the covering parquet files when no BLOB column is projected, and that path never looked at query authorization.A blob table carrying a column mask or a row filter, read with a scalar-only projection, therefore returned raw parquet: both live in pypaimon's reader, which was skipped entirely.
Change
_blob_table_native_filestakeshas_authand returnsNonefor it, the way it already does for deletion vectors. The parameter has no default, so a new call site has to answer for it rather than silently bypassing the check. Both existing call sites, task generation and explain, pass it.Keeping an authorized split off the native reader exposed a second defect. A count or a constant projection pushes
columns=[], and the fallback task cannot build a Daft record batch from zero arrays. That already broke such a query on an ordinary authorized table; the blob table only avoided it by bypassing authorization. The fallback now carries the row count in a placeholder column and projects it away.