[BUG] Native component acquisition ignores mounted namespace edges #12

Closed
opened 2026-09-30 02:31:50 +02:00 by erikinkinen · 0 comments
Owner

Summary

Native component acquisition forwards each name directly to its current provider without consulting mounted namespace edges. An existing covered directory can therefore be selected as an ordinary child instead of the mounted filesystem. Selected-mount policy then sees the underlying mount, not the overlay the pathname is intended to reach. This is a source-derived finding; no deployed bypass is claimed.

Reproduction

Unexecuted source-derived reproduction: create an underlying directory and file, mount another filesystem over that directory, and prepare an explicit native acquisition scope containing its parent. Acquire the mount basename, then the existing underlying file. Observe the provider route and actual selected mount. Also use an alias of the same parent and a different directory with the same basename.

Expected and actual behavior

Expected: match a configured mount edge using the actually held entering parent and raw basename. Crossing retains the mounted root and an independent entering-parent pin under the original scope ceiling; dot-dot returns through that actual edge. Covered provider children must never become ordinary candidates while mounted. Unsupported or unfinished crossing must preserve cleanup and refuse before selecting the covered child.

Current source: native acquisition calls the selected provider component operation directly. It checks cross-provider dot-dot and final selected mount flags, but does not select an overlay edge first. A mount over an absent directory usually fails lookup; a mount over an existing directory can select its underlying contents.

Environment and identity

  • Affected Vfsd source: 5fee4fdb0eb5d4ec96d84030b5253b3d2116014e on feature/posix-compat.
  • Input: actual native acquisition-scope component dispatch.
  • Provider identities are now returned with actual pins; native mount-edge ownership and transitions are still unfinished.
  • No image build, runtime execution or last known working revision is established.

Evidence and prior checks

The covered-directory selection defect is corrected and published: docs a62f871a, vfsd 1872afc5, integration 6c080259.

Native component dispatch compares configured raw basenames with actual held parent identities on their original provider/mount routes before forwarding a lookup. Equal names under different actual parents remain ordinary lookups; aliased parents identify the same edge, and conflicting configured aliases refuse. A matched edge refuses before selecting an underlying child while full scope-owned crossing is completed.

Deployment-counted mount records retain noncopyable namespace root and entering-parent owners. Mounted-root transport reserves its original mount/key and both correlations before submission, and remains distinct from conditional cloning. Parent walks retain at most two original component owners through advancement and cleanup. Successful pins last for the installed namespace mount; they are not client grants. Unknown replies and refused cleanup remain counted and drain from the serving loop independently of client liveness or new correlation allocation. A pending flag avoids idle cleanup scans.

Mount insertion now consumes an exclusive borrowed empty-record reservation. Another insertion cannot overwrite original native custody, and publishing a successful provider mount needs no further fallible storage step. Table reborrowing preserves initialized owners. The obsolete component-only backend retirement method is replaced by one original-acquisition method shared by the distinct private families.

Ten new controls are authored and unrun: three original transport controls and seven actual native-dispatch controls, covering aliases, ambiguous edges, different parents, malformed/lost replies, two-pin cleanup and correlation exhaustion. Rustfmt was applied to 22 Rust inputs using the crate's actual edition and repository settings; an existing include fragment keeps its surrounding format with only its noncopyable array initializer changed. Contracts, architecture/roadmaps and technical manual TeX are updated.

Three signed commits are pushed on feature/posix-compat, with remote head equality recorded. Integration adopts three catalog entries and retains independent Rust helper cafa58e132fe45defcea4df0e8d92cf65fdb209b. No Cargo source identities change. A read-only inventory covers 3509 code files in 76 repositories, all below 1000 lines; the largest changed source is 944 lines.

Full native Open/openat remains open. Scope-owned mount descent/ascent, initially mounted cwd and original subdirectory ceilings, symlink following and conditional creation with process umask remain implementation requirements. This correction adds no full Open acceptance credit. Recalculated progress is 16.91% weighted, 5.21% whole-item acceptance: 21/460 parents and 441/902 sub-items. Both complete EriX guest-build generations and the external Rust/LLVM guest rebuild remain required and unperformed. Tests, builds, lint checks, documentation generation, VM/profiler execution and CI observation remain deferred. No execution pass, warning-free build or measured speedup is claimed.

Earlier evidence follows; the current correction above supersedes the earlier covered-directory behavior.

Source path: src/scope_components.rs delegates to src/handles/acquisition/native.rs, which acquires through the current provider anchor without consulting the mount table.

Tracking

Related: full native Open/openat, Vfsd implementation, phase tracking.

## Summary Native component acquisition forwards each name directly to its current provider without consulting mounted namespace edges. An existing covered directory can therefore be selected as an ordinary child instead of the mounted filesystem. Selected-mount policy then sees the underlying mount, not the overlay the pathname is intended to reach. This is a source-derived finding; no deployed bypass is claimed. ## Reproduction Unexecuted source-derived reproduction: create an underlying directory and file, mount another filesystem over that directory, and prepare an explicit native acquisition scope containing its parent. Acquire the mount basename, then the existing underlying file. Observe the provider route and actual selected mount. Also use an alias of the same parent and a different directory with the same basename. ## Expected and actual behavior Expected: match a configured mount edge using the actually held entering parent and raw basename. Crossing retains the mounted root and an independent entering-parent pin under the original scope ceiling; dot-dot returns through that actual edge. Covered provider children must never become ordinary candidates while mounted. Unsupported or unfinished crossing must preserve cleanup and refuse before selecting the covered child. Current source: native acquisition calls the selected provider component operation directly. It checks cross-provider dot-dot and final selected mount flags, but does not select an overlay edge first. A mount over an absent directory usually fails lookup; a mount over an existing directory can select its underlying contents. ## Environment and identity - Affected Vfsd source: `5fee4fdb0eb5d4ec96d84030b5253b3d2116014e` on `feature/posix-compat`. - Input: actual native acquisition-scope component dispatch. - Provider identities are now returned with actual pins; native mount-edge ownership and transitions are still unfinished. - No image build, runtime execution or last known working revision is established. ## Evidence and prior checks The [covered-directory selection defect](https://git.erikinkinen.fi/erix/vfsd/issues/12) is corrected and published: [docs `a62f871a`](https://git.erikinkinen.fi/erix/docs/commit/a62f871a8d476ab1185ba11dbf0f1fdf5767b027), [vfsd `1872afc5`](https://git.erikinkinen.fi/erix/vfsd/commit/1872afc572ddeb3b12bf1482af8773cc13020698), [integration `6c080259`](https://git.erikinkinen.fi/erix/integration/commit/6c0802594660957c6716ae77e2d52f70dadc7017). Native component dispatch compares configured raw basenames with actual held parent identities on their original provider/mount routes before forwarding a lookup. Equal names under different actual parents remain ordinary lookups; aliased parents identify the same edge, and conflicting configured aliases refuse. A matched edge refuses before selecting an underlying child while full scope-owned crossing is completed. Deployment-counted mount records retain noncopyable namespace root and entering-parent owners. Mounted-root transport reserves its original mount/key and both correlations before submission, and remains distinct from conditional cloning. Parent walks retain at most two original component owners through advancement and cleanup. Successful pins last for the installed namespace mount; they are not client grants. Unknown replies and refused cleanup remain counted and drain from the serving loop independently of client liveness or new correlation allocation. A pending flag avoids idle cleanup scans. Mount insertion now consumes an exclusive borrowed empty-record reservation. Another insertion cannot overwrite original native custody, and publishing a successful provider mount needs no further fallible storage step. Table reborrowing preserves initialized owners. The obsolete component-only backend retirement method is replaced by one original-acquisition method shared by the distinct private families. Ten new controls are authored and unrun: three original transport controls and seven actual native-dispatch controls, covering aliases, ambiguous edges, different parents, malformed/lost replies, two-pin cleanup and correlation exhaustion. Rustfmt was applied to 22 Rust inputs using the crate's actual edition and repository settings; an existing include fragment keeps its surrounding format with only its noncopyable array initializer changed. Contracts, architecture/roadmaps and technical manual TeX are updated. Three signed commits are pushed on feature/posix-compat, with remote head equality recorded. Integration adopts three catalog entries and retains independent Rust helper `cafa58e132fe45defcea4df0e8d92cf65fdb209b`. No Cargo source identities change. A read-only inventory covers 3509 code files in 76 repositories, all below 1000 lines; the largest changed source is 944 lines. [Full native Open/openat](https://git.erikinkinen.fi/erix/posixd/issues/17) remains open. Scope-owned mount descent/ascent, initially mounted cwd and original subdirectory ceilings, symlink following and conditional creation with process umask remain implementation requirements. This correction adds no full Open acceptance credit. Recalculated progress is 16.91% weighted, 5.21% whole-item acceptance: 21/460 parents and 441/902 sub-items. Both complete EriX guest-build generations and the external Rust/LLVM guest rebuild remain required and unperformed. Tests, builds, lint checks, documentation generation, VM/profiler execution and CI observation remain deferred. No execution pass, warning-free build or measured speedup is claimed. Earlier evidence follows; the current correction above supersedes the earlier covered-directory behavior. Source path: `src/scope_components.rs` delegates to `src/handles/acquisition/native.rs`, which acquires through the current provider anchor without consulting the mount table. ## Tracking Related: [full native Open/openat](https://git.erikinkinen.fi/erix/posixd/issues/17), [Vfsd implementation](https://git.erikinkinen.fi/erix/vfsd/pulls/3), [phase tracking](https://git.erikinkinen.fi/erix/integration/issues/65).
erikinkinen added this to the Alpha 1 milestone 2026-10-30 09:35:17 +01:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
erix/vfsd#12
No description provided.