You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 67192ce
Browse filesBrowse the repository at this point in the historyBrowse files
fix(plugin-sharing): declared publicSharing.redactFields survive the object opting out (#14171)
* wip(plugin-sharing): preserve in-progress #13856 work (PM custodial commit)
The dispatched dev agent was terminated mid-task by a session rate limit
(HTTP 429) before it could commit or push. This commit preserves what was on
disk so the container's reclamation cannot lose it.
NOT reviewed and NOT verified: no suite was run against this state, and the
work is incomplete by the agent's own account (it was still re-acquiring the
shared verify lock for its reproduction leg). Treat as a starting point to
amend, never as a finished change.
Deliberately excluded: repro-13856.scratch.test.ts, which the agent named as
scratch and plainly did not intend to ship.
* fix(plugin-sharing): declared publicSharing.redactFields survive the object opting out
getPolicy() collapsed to an empty policy whenever the object's publicSharing
block had enabled !== true — redactFields: [] included — so a link minted
while the object was opted in, redeemed after it was opted out, kept resolving
and started serving the very fields the object declares redacted. The declared
redaction set is now read from the declared block regardless of enabled, so
opting out can never widen what an existing token serves. The mint-time gate,
the redemption-time eligibility gate, the per-link union, and the no-block
path are unchanged; whether standing links should resolve at all after opt-out
is a separate pending ruling and is deliberately not implemented here.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016ZC5rNQj3WEet5HAmmAkMs
* fix(docs): re-anchor system-context row 37 after the share-link hunk shifted it
`check-system-context-census` failed on this branch: 10 problems over 145
anchors and 109 census sites — 5 `[anchor-is-not-a-read-site]` plus the 5
`[site-without-a-row]` reads they had rotted off.
Cause: this PR's single hunk in `getPolicy`'s disabled branch (the
`redactFields` ternary and its explaining comment, +12/-1 at line ~103)
pushed every `isSystem` read site below it down by exactly 11 lines, so
row 37's citations in `content/docs/permissions/system-context.mdx` no
longer resolved.
Pure line rot, not a population change — the read-site count is unchanged
at 109, each stale anchor pairs 1:1 with an orphaned site at a uniform
delta of +11, and the old and new lines are byte-identical:
:423 -> :434 :477 -> :488 :481 -> :492 :554 -> :565 :584 -> :595
Repaired with `node scripts/check-system-context-census.mjs --fix`, which
rewrote 5 anchors and REFUSED nothing. No anchor was hand-edited; no
source or test file is touched.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_016ZC5rNQj3WEet5HAmmAkMs
---------
Co-authored-by: Claude <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: content/docs/permissions/system-context.mdx
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -135,7 +135,7 @@ The largest single consumer — **20 of the 109 sites**.
135
135
| 34 |`revoke()` deletes directly, **before** the non-manual-source guard | Get: the evaluator can revoke its own grants. Lose: the `CONFLICT` guard that warns a rule-materialised grant will be silently re-granted on the next reconcile |`plugin-sharing/src/sharing-service.ts:1286` (guard at `:1311`) |
136
136
| 35 |`listShares()` skips the management gate | Get: full enumeration of who can see a record |`plugin-sharing/src/sharing-service.ts:1338`|
137
137
| 36 |`sys_record_share` reads are **not** self-scoped | Get: tenant-wide share listing without `manage_sharing`|`sharing-plugin.ts:1077`|
138
-
| 37 | Share-link policy `enabled` check bypassed; system callers re-enter under a system context | Get: link creation/resolution while the policy is off |`plugin-sharing/src/share-link-service.ts:423`, `:477`, `:481`, `:554`, `:584`|
138
+
| 37 | Share-link policy `enabled` check bypassed; system callers re-enter under a system context | Get: link creation/resolution while the policy is off |`plugin-sharing/src/share-link-service.ts:434`, `:488`, `:492`, `:565`, `:595`|
139
139
| 38 | Sharing-rule provenance stamp skipped | Lose: the row is not marked as an admin customization — seeder / `defineRule` / boot reconcilers are "the package door" |`sharing-rule-provenance.ts:47`|
140
140
| 39 | Sharing-rule service write + delete paths return early | Lose: the manage-rules gate on the service surface, and the platform-global-rule delete guard |`sharing-rule-service.ts:157`, `:382`|
0 commit comments