Skip to content

feat: ACL_REQUIRE_CREATOR rejects unstamped document creates - #15

Merged
cursor[bot] merged 1 commit into
mainfrom
feat/acl-require-creator-c8e3
Jul 25, 2026
Merged

feat: ACL_REQUIRE_CREATOR rejects unstamped document creates#15
cursor[bot] merged 1 commit into
mainfrom
feat/acl-require-creator-c8e3

Conversation

@PeterBaker0

@PeterBaker0 PeterBaker0 commented Jul 25, 2026

Copy link
Copy Markdown
Owner

Summary

Adds opt-in ACL_REQUIRE_CREATOR (default false) so the installed Couch _design/acl validate_doc_update can reject non-admin creates that omit a non-empty creator. This closes the hole where unstamped docs become world-open to every DB member via r-*, without changing default create semantics or map behaviour for already-written open docs.

Changes

  • Config: ACL_REQUIRE_CREATORcouch.aclRequireCreator (bool, default off)
  • VDU: when on, create path requires non-empty creator for non-_design docs (_admin exempt)
  • Ddoc version: 2.3.0 (flag off) ↔ 2.4.0 (flag on); ensure/migrate rewrites generated VDUs on flag flip
  • Docs: USER-GUIDE, README env table, CHANGELOG (Unreleased), prod compose comment
  • Tests: unit coverage for both modes + migrate-on-flip; integration matrix via a second proxy container

Test plan

  • pnpm lint / pnpm fmt:check / pnpm typecheck / pnpm test (206 unit tests)
  • docker compose up -d --build then pnpm test:integration (156 tests, including require-creator + existing ACL isolation)

Release notes

After merge, cut a minor release (1.5.0) so the GHCR image includes this flag. Changelog entry is under [Unreleased].

Open in Web Open in Cursor 

Bake an opt-in require-creator rule into the generated Couch VDU so
non-admin creates cannot omit creator. Default remains off; flag flips
bump the ddoc version so ensure rewrites on deploy.

Co-authored-by: Peter Baker <PeterBaker0@users.noreply.github.com>
@cursor
cursor Bot marked this pull request as ready for review July 25, 2026 02:02
@cursor
cursor Bot merged commit 77ea3f8 into main Jul 25, 2026
2 checks passed
@cursor
cursor Bot deleted the feat/acl-require-creator-c8e3 branch July 25, 2026 02:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants