@hasna/skills 0.10.55 → 0.10.57
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -0
- package/bin/index.js +787 -107
- package/bin/mcp.js +94 -1
- package/bin/migrate.js +1 -1
- package/bin/server.js +1 -1
- package/bin/worker.js +1 -1
- package/dist/index.d.ts +2 -0
- package/dist/index.js +179 -1
- package/dist/lib/agent-integration.d.ts +2 -0
- package/dist/lib/claude-prospective-review.d.ts +140 -0
- package/dist/sdk/index.js +94 -1
- package/docs/plugin-admission.md +59 -0
- package/package.json +1 -1
package/docs/plugin-admission.md
CHANGED
|
@@ -173,6 +173,65 @@ new loaders still require their dedicated review. API failure refuses an update;
|
|
|
173
173
|
stale projection as synchronized. Claude may retain its previous installation
|
|
174
174
|
after a refused update, whose existing local drift checks continue to apply.
|
|
175
175
|
|
|
176
|
+
## Prospective Claude candidate review
|
|
177
|
+
|
|
178
|
+
Before adding or changing a marketplace, an installer may call
|
|
179
|
+
`skills hook review-claude-candidate --request <absolute-json-path> --json`.
|
|
180
|
+
The `skills.claude-plugin-prospective-review/v1` request binds one frozen
|
|
181
|
+
marketplace/catalog closure and a non-empty `plugins` array. Each selected
|
|
182
|
+
plugin supplies its exact `plugin`, `manifestPath`, `manifestSha256` and bounded
|
|
183
|
+
JSON `optionsPatch`; an optional `releaseManifest` carries the separate
|
|
184
|
+
release.json path and raw-byte SHA-256. The request also binds current Skills
|
|
185
|
+
and Claude preimages, explicit user/project scope, caller assessment and one
|
|
186
|
+
complete expected semantic document set for the whole selected plugin batch.
|
|
187
|
+
The validator checks every selected manifest and source against the same
|
|
188
|
+
closure before returning one receipt. It derives the owned changes and refuses
|
|
189
|
+
any unrelated graph change. Harnesses validates each options patch against its
|
|
190
|
+
release manifest before invoking Claude; Skills does not copy its private
|
|
191
|
+
option allowlists or infer that caller-supplied options are release-approved.
|
|
192
|
+
The supported catalog shape uses relative selected-plugin sources inside that
|
|
193
|
+
closure. Nontrivial `metadata.pluginRoot` values and native catalog or selected
|
|
194
|
+
plugin dependency declarations refuse because this validator does not resolve
|
|
195
|
+
or review unselected external plugins.
|
|
196
|
+
The request may declare `functionHooksEnv: "1"`; without that declaration the
|
|
197
|
+
environment document is preserved unchanged. The validator shallow-merges
|
|
198
|
+
each declared options patch into the selected plugin's existing `options`;
|
|
199
|
+
the patch must explicitly bind `enabled: true`, and the validator enforces that
|
|
200
|
+
value after merging. This preserves all other selected options and unrelated
|
|
201
|
+
plugin configuration. It refuses a selected `enabledPlugins` array shape that
|
|
202
|
+
this schema does not model. Existing target registration rows keep their array
|
|
203
|
+
positions, new rows append, and unrelated rows remain byte-semantically bound.
|
|
204
|
+
Its receipt binds the raw request bytes and the complete projected documents;
|
|
205
|
+
semantic digests use UTF-8 JSON with object keys recursively sorted in
|
|
206
|
+
ECMAScript UTF-16 order, array order retained and JavaScript JSON primitive
|
|
207
|
+
serialization.
|
|
208
|
+
|
|
209
|
+
Native-generated fields use typed markers only in the exact selected rows:
|
|
210
|
+
`{"$generated":"claude-utc-timestamp","field":"<path>"}` requires a valid generated
|
|
211
|
+
UTC timestamp at that field. For a native update that may preserve or refresh
|
|
212
|
+
`lastUpdated`, `{"$allowed":[<exact prior timestamp>,<generated marker>]}` permits
|
|
213
|
+
only those two values. Existing `installedAt` remains exact; a fresh install's
|
|
214
|
+
`installedAt` is generated. No other row fields accept markers.
|
|
215
|
+
|
|
216
|
+
This is a read-only validator. It does not establish that caller-supplied
|
|
217
|
+
`native.home`, config/plugin roots, executable identity or Skills `dataDir` are
|
|
218
|
+
the installed consumers. Harnesses must resolve them through the installed
|
|
219
|
+
package-owned consumers and compare them before trusting the receipt. It must
|
|
220
|
+
also retain its existing review record and bind it to the exact candidate:
|
|
221
|
+
the caller's no-skill-injection assessment is not a semantic hook review, and
|
|
222
|
+
structural refusal checks do not prove hook behavior. Recheck all preimages and
|
|
223
|
+
candidate closure immediately before the first native mutation. The validator
|
|
224
|
+
does not claim native install atomicity or crash recovery.
|
|
225
|
+
|
|
226
|
+
The optional release manifest witness binds the complete supplied release.json
|
|
227
|
+
file bytes, path and SHA-256 in the request/receipt. Harnesses remains
|
|
228
|
+
responsible for verifying that its release options correspond to every
|
|
229
|
+
selected `optionsPatch`; the public Skills validator deliberately does not
|
|
230
|
+
interpret private release schemas.
|
|
231
|
+
Installed consumers can use the public `captureClaudeProspectiveCandidateClosure`
|
|
232
|
+
and `hashClaudePluginManifest` exports to prepare the exact digests without
|
|
233
|
+
copying the package's hashing algorithms.
|
|
234
|
+
|
|
176
235
|
## Reviewed plugin-hook attestation scope
|
|
177
236
|
|
|
178
237
|
A reviewed discovery input carries `pluginHooks: "reviewed-no-skill-injection"`.
|