TASK-003 Add secure assigned-folder browsing

This commit is contained in:
rob
2026-11-25 20:54:05 +00:00
parent 549f11d9f4
commit 68335d629b
14 changed files with 520 additions and 300 deletions
+11 -3
View File
@@ -1,8 +1,8 @@
# Foldershare current state
- Updated: 2026-11-25 for TASK-002 integration
- Inspected worktree: `/home/rob/projects/foldershare`
- TASK-002 integration base: `codex` at `cd6d6b3`
- Updated: 2026-11-25 for TASK-003 acceptance and integration
- Inspected worktree: `/home/rob/projects/foldershare/.worktrees/TASK-003`
- TASK-003 base: `codex` at `549f11d`
## Verified repository state
@@ -45,3 +45,11 @@ Captain accepted TASK-002 on 2026-11-07 and authorized its local integration int
- The authentication checks require `login_disabled = false`. Rows left `NULL` by the old nullable migration are denied authentication. Existing invalid or host-absolute folder assignments require admin reassignment to virtual paths. TASK-002 includes no data migration, and local account and assignment data were not inspected.
- On 2026-11-25, all ten API tests passed with disposable SQLite and media fixtures. Python syntax checks, frontend production build and diff checks passed. Frontend lint could not run because ESLint configuration is missing. Python datetime and Sass deprecation warnings remain.
- TASK-003 covers ordinary-user browsing, TASK-004 covers download grants and resume, and TASK-005 covers the rest of the admin workflow. Target-Pi deployment and cookie/TLS configuration remain unverified. TASK-007's manual-test adapter awaits separate Captain validation in its own worktree.
## TASK-003 assigned-folder browsing
- Implemented in `task/TASK-003-secure-browsing`. Captain accepted the task and authorized its local integration into `codex` on 2026-11-25.
- Signed-in users can browse within their current assigned root. The homepage renders folder navigation, file metadata, and distinct messages for empty, unassigned and unavailable media. The admin folder picker continues to use the admin-only root API. Stored assignments are omitted from the sign-in response.
- The API returns one directory at a time and verifies the current assignment on each call. The server reports a missing media root or storage I/O errors as unavailable. Detecting a disconnected mount that still looks like a readable local directory requires deployment-level mount checks under TASK-006.
- All 15 API tests, Python syntax, production build and diff checks passed. Frontend lint is still blocked by the absent ESLint configuration. Chromium exercised the isolated snapshot at 1280 × 800 and 375 × 812. The existing header references a missing `/logo.png` asset in both views.
- The TASK-007 adapter produced and verified the snapshot. Its readiness HTTP check timed out on concurrent cold frontend and browser startup, so the successful QA run delayed the adapter's Firefox launch. The candidate passed Chromium browser QA and the disposable session cleaned up. The TASK-003 snapshot was absent at integration preflight.