Merge claude/security-b-118: plugin status written alone, access answers announced (strict in 1.19.0), drafts left out of related documents
Merged onto ee241de (the prepared 1.17.2). Conflicts kept both sides: AGENT.md rows (consent version; drafts, status, access answers), security.md sections (job queue, visitor accounts; access callbacks), src/index.ts (the jobs exports).
Co-Authored-By: Claude Opus 5.5 <[email protected]>
This commit is contained in:
@@ -1265,6 +1265,17 @@ own `payload-locked-documents` (who edits which document) also runs on Payload's
|
||||
plugin-wide default for it is planned for 2.0. Verify: the doctor shows no `visitor-writes` finding, and the
|
||||
closed-doors spec's customer gets 403 on every write door.
|
||||
|
||||
## Access callbacks (`cookieScanner.access`, the doctor's `access`)
|
||||
|
||||
A project's callback says who may use the cookie scanner's endpoints or read the doctor's status. Today any truthy
|
||||
answer lets the request in: `({ req }) => req.user` returns an account object and passes, and so does a function
|
||||
that returns `'no'` or `{}`. **From the next minor version (1.19.0) only `true` allows** — like
|
||||
`twoFactor.requireSetup.resetAccess` already does. Since 1.18.0 the first answer that is not a boolean is reported
|
||||
once per option in the server log:
|
||||
`[iapl] cookieScanner.access returned an object, not true or false. It is still read as allowed; …`.
|
||||
Return a boolean: `({ req }) => Boolean(req.user)`, `({ req }) => isAdmin(req.user, req.payload)`. One function reads
|
||||
every answer: `accessAllowed(option, answer)` (exported). The second factor is checked before the callback, as before.
|
||||
|
||||
## Turn off, override, extend
|
||||
|
||||
- **Stored secrets:** `secrets: { writeOnly: false }`, `secrets: { reenterOnChange: false }`; `writeOnlySecret` /
|
||||
|
||||
Reference in New Issue
Block a user