Repository navigation
fix: authorize every SELECT source - #19
Merged
Merged
Conversation
marianfoo
marked this pull request as ready for review
August 6, 2026 13:21
marianfoo
force-pushed
the
codex/fix-base-sec-003
branch
from
August 6, 2026 15:29
550ad6e to
aa2ec78
Compare
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.
Goal
Close BASE-SEC-003 by applying the existing table authorization policy to every provable physical SELECT source, including nested subqueries and later
UNION/UNION ALLsources.Changes
FROM/JOINsource with the unchanged authorization object or fallback policyHIERARCHYconstructor while preserving realHIERARCHY_*table namesUNION ALLcannot hide a later unauthorized sourceTDD and review evidence
The finished plan is
docs/plans/finished/base-sec-003.md. Against the original production code, the first test-only A4H run passed 22/26 tests and failed exactly the four intended nested/dynamic boundaries. External review then identified the SAP-documented attached path form: a second test-only replay passed 32/34 and failed exactlyREJECTS_ATTACHED_PATH_SOURCEandACCEPTS_HIERARCHY_NAMED_TABLE. No SQL was executed for either security proof.PR #18 and PR #20 were merged first. This branch was then rebased onto their final master state, overlapping source/docs were resolved semantically, and every affected local/A4H gate was repeated on the integrated candidate rather than carrying forward branch-local evidence.
Exact integrated validation
Final head:
aa2ec789ef173d4244db0168d12d557bd71a7ebc.npm ci,npm test,npm run lint:quality, andgit diff --check339a53f579fcde6b95dee08841a421fbe510839d06113902c800b6c28eee539746789b7a44ac06953e9a69a03f19199d6192ebf10327aa24c3e13c77d1e9c654ABAP_CLOUD_READINESS: 668 findings (462 P1, 206 P2)S4HANA_READINESS_2023: no rows, but incomplete because prerequisite checks are unavailable31116086378: passed; external abaplint passed and observations were informational/skipped as configuredFinal review
Outcome: fixed. No provable physical SELECT source reaches generation without the existing activity/table policy; unprovable forms fail closed. Parenthesized joins remain a documented functional limitation until their grammar is modeled. Missing GUI status
STATUS010remains the independent BASE-BUG-007 installation issue and did not invalidate the safe startup smoke.Release note
Prevent nested, attached-path, and otherwise unprovable SELECT sources from bypassing ZTOAD table authorization.