Skip to content

fix: page-scoped ACL grants also cover the page's dot asset folder#300

Merged
kptdobe merged 1 commit into
mainfrom
dotasset
Jul 9, 2026
Merged

fix: page-scoped ACL grants also cover the page's dot asset folder#300
kptdobe merged 1 commit into
mainfrom
dotasset

Conversation

@kptdobe

@kptdobe kptdobe commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Page assets live under a dot-prefixed sibling folder (e.g. foo.html's images live under .foo/), but ACL grants anchored on the plain page name (foo, foo/**, foo/+**) never matched that dot-folder, so uploads there returned 403 even for users with write access to the page.
  • getUserActions now also checks the dot-folder variant of a /** / /+** grant prefix.

Test plan

  • Added a failing-first test reproducing the exact grant shape (path/+** + path.html) and confirmed it 403'd against .path/asset.jpg pre-fix
  • npm test — 420 passing
  • npm run lint — clean

Uploads into a page's `.pagename/` asset folder were getting 403'd even
when the user had write access to `pagename`/`pagename/**`, because the
dot-prefixed folder name never matched the plain-name grant.
@kptdobe kptdobe requested a review from bosschaert July 9, 2026 07:45
@codecov

codecov Bot commented Jul 9, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@kptdobe kptdobe merged commit 0e95a8e into main Jul 9, 2026
6 checks passed
@kptdobe kptdobe deleted the dotasset branch July 9, 2026 14:38
adobe-bot pushed a commit that referenced this pull request Jul 9, 2026
## [1.12.2](v1.12.1...v1.12.2) (2026-07-09)

### Bug Fixes

* page-scoped ACL grants also cover the page's dot asset folder ([#300](#300)) ([0e95a8e](0e95a8e))
@adobe-bot

Copy link
Copy Markdown
Collaborator

🎉 This PR is included in version 1.12.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants