[FEATURE] Implement source-qualified file status and seekable directories #25
Labels
No labels
alpha-1
bug
ci
docs
duplicate
enhancement
help wanted
invalid
performance
phase-6
question
refactor
security
wontfix
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
erix/posixd#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?
Problem and motivation
Compatibility clients need stat/fstat/lstat/fstatat, readdir and seekable directory iteration for real build workloads. The current descriptive FileStatus type and native legacy stat reply do not supply a complete authenticated bridge: filesystem/file identity is absent, timestamp zero can mean unknown, and directory cursors do not yet belong to shared compatibility descriptions. Opening a file for read merely to stat it would impose the wrong final-file permission requirement.
Proposed behavior and scope
Implement a source-qualified native metadata snapshot and exact held-object transport through LibIPC, the filesystem providers and Vfsd. Bind filesystem/file identity to original native objects; never derive it from a pathname, open handle or lossy hash. Preserve complete signed timestamp values, explicit precision and source/unavailability, independent ctime and mtime, owner/mode/link counts, and real symlink size. Initialize required volatile metadata from original trusted clock evidence instead of claiming a later query time was the creation time.
Connect compatibility status through Posixd's authenticated root/cwd/dirfd traversal and original shared descriptions. Path status requires search on real prefixes but does not acquire final-file Read authority. lstat/no-follow inspects the original link. fstat uses the retained description without reopening by path and handles all supported descriptor backends honestly. Reuse and refactor the existing original-candidate walk/custody machinery instead of duplicating a resolver.
Add original-directory enumeration with correct dot and dot-dot identities, root clamping and mounted overlays. Retain a shared cursor and support tell/seek/rewind without stealing bits from a provider's full-width cursor or publishing uninitialized names. Metadata/entry result capacity must be admitted before cursor effects; aliases and cancellation preserve the actual outcome. Update native workloads, contracts/manual and the signed immutable dependency graph. Existing rename/unlink lifetime, locks and event-driven poll work remains separately tracked; no source finding discovered here is waived as a test failure.
Authority, security and reliability
The original client receiver, realm generation and delegated scope select the namespace. Native provider routes, object pins and mount identities come only from retained owners. Numeric device/inode/cookie/status fields confer no authority. No ambient lookup, process grant, filesystem reopening fallback, fabricated zero timestamp, hidden unbounded identity map or reply-selected provider is allowed. Unknown fields remain explicitly unknown; the compatibility bridge must never fabricate a successful complete stat result from incomplete evidence.
Retain original provider caller and server custody across partial failure, cancellation, revoked scopes and malformed replies. No accepted native effect may be replayed because its result was lost. Source-qualified observations remain descriptive and do not replace current permission admission. Use counted existing storage or explicit added resource geometry, nonwrapping generations and exact teardown before reuse. Security, reliability, then performance govern the design.
Acceptance criteria
Checklist
No pass, measured speedup or guest rebuild is claimed; both complete EriX guest generations and external Rust/LLVM guest rebuilding remain required.
Alternatives and tradeoffs
Do not reinterpret existing unknown-zero legacy replies as observed metadata, use handles as inode numbers, or hash paths into identities. Preserve the existing counted native owners and add exact observation contracts. No terminal file Read admission is needed merely to return metadata after authorized traversal. Timestamp and filesystem-format limitations need explicit source distinctions and checked errors, not saturation or invented values.
The behavior is derived independently from the public stat structure contract, directory interfaces and directory iteration specification. No third-party implementation code is imported.
Tracking and rollout
Implemented and closed under source acceptance; test and CI execution remain waived.
Complete original metadata and status/directory source acceptance — 1 October 2026
Source acceptance covers explicit format admission/recovery, persistent original identities and full metadata, shared ordinary/acquired observations, fresh permissions, atomic filesystem/catalog updates, alias and cleanup lifetime, compatibility stat families and shared seekable directory descriptions. Imported unavailable facts remain explicit refusals.
Runtime and independent fixture producers emit the mandatory stream allocation flag, which admission and image verification require.
This checkpoint authors 14 Rust and four Python controls plus two selected exFAT VM scenarios; two existing FAT scenarios now also require six-child directory growth, post-growth observations and complete cleanup.
Both complete EriX guest generations and external Rust/LLVM guest rebuilding remain required and unperformed.
Related records and contracts
erikinkinen referenced this issue from erix/blockd2026-09-30 14:16:04 +02:00
erikinkinen referenced this issue from erix/coreutils2026-09-30 14:16:05 +02:00
erikinkinen referenced this issue from erix/crashd2026-09-30 14:16:05 +02:00
erikinkinen referenced this issue from erix/deviced2026-09-30 14:16:05 +02:00
erikinkinen referenced this issue from erix/docs2026-09-30 14:16:06 +02:00
erikinkinen referenced this issue from erix/drv-acpi2026-09-30 14:16:07 +02:00
erikinkinen referenced this issue from erix/drv-i80422026-09-30 14:16:07 +02:00
erikinkinen referenced this issue from erix/drv-ps2-keyboard2026-09-30 14:16:08 +02:00
erikinkinen referenced this issue from erix/drv-ps2-mouse2026-09-30 14:16:08 +02:00
erikinkinen referenced this issue from erix/drv-rtc-cmos2026-09-30 14:16:09 +02:00
erikinkinen referenced this issue from erix/drv-serial2026-09-30 14:16:10 +02:00
erikinkinen referenced this issue from erix/drv-virtio-block2026-09-30 14:16:12 +02:00
erikinkinen referenced this issue from erix/dynlinkd2026-09-30 14:16:12 +02:00
erikinkinen referenced this issue from erix/e2fsd2026-09-30 14:16:13 +02:00
erikinkinen referenced this issue from erix/exsh2026-09-30 14:16:14 +02:00
erikinkinen referenced this issue from erix/extop2026-09-30 14:16:15 +02:00
erikinkinen referenced this issue from erix/fatd2026-09-30 14:16:15 +02:00
erikinkinen referenced this issue from erix/fbcond2026-09-30 14:16:16 +02:00
erikinkinen referenced this issue from erix/hotplugd2026-09-30 14:16:17 +02:00
erikinkinen referenced this issue from erix/inputd2026-09-30 14:16:18 +02:00
erikinkinen referenced this issue from erix/integration2026-09-30 14:16:19 +02:00
erikinkinen referenced this issue from erix/irqd2026-09-30 14:16:20 +02:00
erikinkinen referenced this issue from erix/kernel2026-09-30 14:16:20 +02:00
erikinkinen referenced this issue from erix/keyd2026-09-30 14:16:21 +02:00
erikinkinen referenced this issue from erix/launchd2026-09-30 14:16:22 +02:00
erikinkinen referenced this issue from erix/lib-block2026-09-30 14:16:22 +02:00
erikinkinen referenced this issue from erix/lib-bootstrap2026-09-30 14:16:22 +02:00
erikinkinen referenced this issue from erix/lib-capabi2026-09-30 14:16:23 +02:00
erikinkinen referenced this issue from erix/lib-driver2026-09-30 14:16:23 +02:00
erikinkinen referenced this issue from erix/lib-input2026-09-30 14:16:23 +02:00
erikinkinen referenced this issue from erix/lib-interrupt2026-09-30 14:16:24 +02:00
erikinkinen referenced this issue from erix/lib-ipc2026-09-30 14:16:25 +02:00
erikinkinen referenced this issue from erix/lib-log2026-09-30 14:16:25 +02:00
erikinkinen referenced this issue from erix/lib-posixabi2026-09-30 14:16:26 +02:00
erikinkinen referenced this issue from erix/lib-service2026-09-30 14:16:26 +02:00
erikinkinen referenced this issue from erix/lib-stdio2026-09-30 14:16:26 +02:00
erikinkinen referenced this issue from erix/lib-time2026-09-30 14:16:27 +02:00
erikinkinen referenced this issue from erix/lib-tty2026-09-30 14:16:27 +02:00
erikinkinen referenced this issue from erix/lib-vfs2026-09-30 14:16:27 +02:00
erikinkinen referenced this issue from erix/loaderd2026-09-30 14:16:28 +02:00
erikinkinen referenced this issue from erix/logd2026-09-30 14:16:28 +02:00
erikinkinen referenced this issue from erix/memd2026-09-30 14:16:28 +02:00
erikinkinen referenced this issue from erix/named2026-09-30 14:16:29 +02:00
erikinkinen referenced this issue from erix/pagerd2026-09-30 14:16:29 +02:00
erikinkinen referenced this issue2026-09-30 14:16:30 +02:00
erikinkinen referenced this issue from erix/powerboxd2026-09-30 14:16:30 +02:00
erikinkinen referenced this issue from erix/probed2026-09-30 14:16:30 +02:00
erikinkinen referenced this issue from erix/procd2026-09-30 14:16:31 +02:00
erikinkinen referenced this issue from erix/ramfsd2026-09-30 14:16:31 +02:00
erikinkinen referenced this issue from erix/rootd2026-09-30 14:16:32 +02:00
erikinkinen referenced this issue from erix/seriald2026-09-30 14:16:32 +02:00
erikinkinen referenced this issue from erix/timed2026-09-30 14:16:33 +02:00
erikinkinen referenced this issue from erix/ttyd2026-09-30 14:16:33 +02:00
erikinkinen referenced this issue from erix/vfsd2026-09-30 14:16:34 +02:00
erikinkinen referenced this issue from erix/vspaced2026-09-30 14:16:34 +02:00
erikinkinen referenced this issue from erix/lib-posixabi2026-09-30 16:12:16 +02:00