[BUG] VSpace mapping changes ignore attenuated MAP rights #25
Labels
No labels
bug
ci
docs
duplicate
enhancement
help wanted
invalid
performance
phase-6
question
refactor
security
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
erix/kernel#25
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Caller-local VSpace map, protection and unmap operations resolved live object identity without checking the capability's current MAP right. The fixed Kernel requires MAP before any mapping mutation. Empty and MANAGE-only attenuations retain identity without regaining mapping authority.
Reproduction
Five owned-fixture host controls ran against original Kernel
d0d9e25b71with production source unchanged. Three negative controls failed: both empty and MANAGE-only aliases admitted a new mapping, changed an existing RW mapping to R, and removed an existing mapping. The independently held MAP alias cleaned up unexpected effects before assertions. MAP-only lifecycle and removed/reused-alias controls passed. The introducing revision and last known working revision are unknown.Expected and actual behavior
Original map, protection and unmap results were Ok(()), where RootSlotPolicyViolation was expected. The correction preserves live identity and retirement error precedence, checks the actual local capability's MAP bit and retains independent frame checks. MAP alone suffices. Host controls now pass; actual CPL3 requests through both restricted aliases are denied, preserve the same RW/NX backing and user-visible fixture value, and finish with all five temporary grants dropped.
Environment and identity
Evidence and prior checks
Four strict configurations pass 750 default / 774 all-feature tests, with three pre-existing ignored cases. Formatting, strict host/native Clippy, private rustdoc and thirteen native builds pass without warnings. Final Markdown checks found two overlong Kernel lines and one Integration line; wrapping them preserved every executable byte and all passing test evidence.
All 172 Integration helper commands pass. Unchanged orchestration and profiler Rust sources retain their prior strict matrices. Three exact-source native executions pass lifetime, invocation and mapping; both isolation and sparse contracts pass on the mapping capture with identical runtime settings. All fifteen native component signatures verify; each packaged Kernel equals exactly one retained original artifact after normal stripping. The original exec-successor service VM also passes against the complete 73-component graph and unchanged 120-second guest limit. Builds emit no warnings and QEMU stderr is empty.
The manual change passes all 45 tests and 2,431 pages; 450,550 word bounds and both changed pages are reviewed, with zero final warnings or overflow. Original failing host results remain retained. The unsafe original behavior was not executed natively; native acceptance proves the corrected boundary.
Tracking
Fixed in Kernel PR 3, coordinated through Integration PR 12 and Docs PR 4. Independent hardware roots remain in Kernel issue 22. Complete authority cleanup, measured performance improvement, external toolchain rebuilding and both full EriX guest-build generations remain open in the phase checklist.
Publication CI: Kernel 638/639 and Docs 1009/1010 pass. Each pair has four complete logs: Kernel totals 777,250 bytes with zero warnings, and Docs totals 774,674 bytes with zero final warnings or overflow. The manual retains its initial 35/1/0 LaTeX warning sequence through convergence. Integration 1721/1722 remains queued; it receives no CI acceptance credit.