Title: Phase 1: emit relative acl:accessTo / acl:default in ACL generators (#427) · Issue #428 · JavaScriptSolidServer/JavaScriptSolidServer · GitHub
Open Graph Title: Phase 1: emit relative acl:accessTo / acl:default in ACL generators (#427) · Issue #428 · JavaScriptSolidServer/JavaScriptSolidServer
X Title: Phase 1: emit relative acl:accessTo / acl:default in ACL generators (#427) · Issue #428 · JavaScriptSolidServer/JavaScriptSolidServer
Description: Phase 1 of the umbrella plan in #427. Scope Update the ACL generators in src/wac/parser.js to emit relative acl:accessTo and acl:default URIs. Update callers in src/handlers/container.js and the createRootPodStructure function in src/ser...
Open Graph Description: Phase 1 of the umbrella plan in #427. Scope Update the ACL generators in src/wac/parser.js to emit relative acl:accessTo and acl:default URIs. Update callers in src/handlers/container.js and the cr...
X Description: Phase 1 of the umbrella plan in #427. Scope Update the ACL generators in src/wac/parser.js to emit relative acl:accessTo and acl:default URIs. Update callers in src/handlers/container.js and the cr...
Opengraph URL: https://github.com/JavaScriptSolidServer/JavaScriptSolidServer/issues/428
X: @github
Domain: github.com
IPv4 address: 140.82.112.3
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"Phase 1: emit relative acl:accessTo / acl:default in ACL generators (#427)","articleBody":"Phase 1 of the umbrella plan in #427.\n\n## Scope\n\nUpdate the ACL generators in `src/wac/parser.js` to emit relative `acl:accessTo` and `acl:default` URIs. Update callers in `src/handlers/container.js` and the `createRootPodStructure` function in `src/server.js` to pass the relative path string instead of the absolute `${podUri}…`.\n\nGenerators in scope:\n- `generateOwnerAcl`\n- `generatePrivateAcl`\n- `generateInboxAcl`\n- `generatePublicFolderAcl`\n- `generatePublicReadAcl`\n\nThe parser at `src/wac/parser.js:141` already calls `resolveUri(uri, baseUrl)` against the ACL document's request URL, so a relative `./` always matches the requesting host. This is a write-side change only — read-side support has been in place since `a736338` (Jan 2026).\n\n## Concrete change\n\n```diff\n- 'acl:accessTo': { '@id': resourceUrl },\n+ 'acl:accessTo': { '@id': relativePath },\n```\n\n…with callers computing `relativePath` as `'./'` for the container itself, `'./private/'` for nested containers, etc., instead of `${podUri}private/`.\n\n## Reproduction (current, broken)\n\n```bash\njss start --single-user --no-idp --port 4444\ncurl -s -o /dev/null -w \"%{http_code}\\n\" http://localhost:4444/ # 200\ncurl -s -o /dev/null -w \"%{http_code}\\n\" http://0.0.0.0:4444/ # 401\ncurl -s -o /dev/null -w \"%{http_code}\\n\" http://127.0.0.1:4444/ # 401\n```\n\nAfter Phase 1 all three should return 200.\n\n## Tests\n\n- **Unit**: each generator emits the relative form (`./`, `./private/`, etc.).\n- **Integration**: `--single-user --no-idp` server, fresh pod, `GET /` from localhost, 0.0.0.0, 127.0.0.1, and the loopback alias all return 200.\n- **Regression**: existing pods on disk that contain absolute-URI ACLs continue to authorize correctly (parser handles both forms).\n\n## Acceptance\n\n- [ ] All five generators emit relative `acl:accessTo` / `acl:default`.\n- [ ] Callers in `container.js` and `server.js` updated to pass relative paths.\n- [ ] Cross-host integration test passes for public read.\n- [ ] No regression on existing absolute-URI ACL files.\n- [ ] fonstr welcome page (or any `--single-user --no-idp` deployment) works on every interface the server binds.\n\n## Out of scope\n\n- `acl:agent` — that's Phase 2.\n- Default landing page at `/` for multi-user — that's Phase 3 (folds in #303).\n- Cross-host owner auth normalization — that's Phase 4.\n\nRefs #427.\n","author":{"url":"https://github.com/melvincarvalho","@type":"Person","name":"melvincarvalho"},"datePublished":"2026-05-14T03:48:08Z","url":"https://github.com/JavaScriptSolidServer/JavaScriptSolidServer/issues/428"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:8e8cffd4-c6a7-5a76-9e7f-8c4a85375ce3 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | A032:AD997:131215F:1811050:6B0393A5 |
| html-safe-nonce | e2dc2ce13d22caeabf82a2a604e45005c0f7a9e9b363293d238401f1ed1eaa8d |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJBMDMyOkFEOTk3OjEzMTIxNUY6MTgxMTA1MDo2QjAzOTNBNSIsInZpc2l0b3JfaWQiOiIzMjQ4NjY5NjE5MDMyMTM0NTY1IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | 0fdf4dcf5b6dc30d26b6242ac2b5e640e07d599668ce6825884171a65fda7c52 |
| hovercard-subject-tag | issue:4442977237 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/JavaScriptSolidServer/JavaScriptSolidServer/428/issue_layout |
| twitter:image | https://opengraph.githubassets.com/6cc1836f30023872b6ef8000d3236e91a7ecacdf3eae9f685d7bdb82d1127d8f/JavaScriptSolidServer/JavaScriptSolidServer/issues/428 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/6cc1836f30023872b6ef8000d3236e91a7ecacdf3eae9f685d7bdb82d1127d8f/JavaScriptSolidServer/JavaScriptSolidServer/issues/428 |
| og:image:alt | Phase 1 of the umbrella plan in #427. Scope Update the ACL generators in src/wac/parser.js to emit relative acl:accessTo and acl:default URIs. Update callers in src/handlers/container.js and the cr... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | melvincarvalho |
| hostname | github.com |
| expected-hostname | github.com |
| None | 87e774ee7c6b3bee0490394e4d3e57ec9dbc956f74b87ea685dc8996c1676456 |
| turbo-cache-control | no-preview |
| go-import | github.com/JavaScriptSolidServer/JavaScriptSolidServer git https://github.com/JavaScriptSolidServer/JavaScriptSolidServer.git |
| octolytics-dimension-user_id | 205442424 |
| octolytics-dimension-user_login | JavaScriptSolidServer |
| octolytics-dimension-repository_id | 958025407 |
| octolytics-dimension-repository_nwo | JavaScriptSolidServer/JavaScriptSolidServer |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 958025407 |
| octolytics-dimension-repository_network_root_nwo | JavaScriptSolidServer/JavaScriptSolidServer |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 423dbb54c5e7bfecc838eb387c1435eb3d0e760d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width