{ "$schema": "https://json-schema.org/draft-07/schema#", "$id": "https://desirecore.local/schemas/special-review.v1.schema.json", "title": "Market Class C special review record", "type": "object", "additionalProperties": false, "required": ["schemaVersion"], "properties": { "schemaVersion": { "const": 1 }, "reviewedBy": { "type": "string", "minLength": 1 }, "reviewedAt": { "type": "string", "minLength": 1 }, "notes": { "type": "string" }, "excludePaths": { "type": "array", "description": "Repo-relative paths or globs omitted from the audit tree walk only. Must not include LICENSE/NOTICE/COPYING or dependency manifests. The DesireCore installer does not honor this field until the client contract admits it.", "items": { "type": "string", "minLength": 1 }, "uniqueItems": true }, "budgetExemptPaths": { "type": "array", "description": "Repo-relative paths that remain in the audit manifest and must still be regular files, but may exceed MAX_FILE_BYTES. Prefer this for runtime data that must stay installed.", "items": { "type": "string", "minLength": 1 }, "uniqueItems": true }, "acceptedDependencyIdentities": { "type": "object", "description": "Map of dependency path to the identity key of the *new* snapshot: package.json is the SHA-256 of the manifest with version removed; other manifests use the git blob SHA.", "additionalProperties": { "type": "string", "pattern": "^([a-f0-9]{40}|[a-f0-9]{64})$" } }, "acceptedFrontmatterSha256": { "type": "object", "description": "Map of install path (empty string for a repo-root skill) to SHA-256 of stable_frontmatter(new SKILL.md).", "additionalProperties": { "type": "string", "pattern": "^[a-f0-9]{64}$" } }, "acceptedRootEvidenceSha256": { "type": "object", "description": "Map of repo-root LICENSE/NOTICE/COPYING path to SHA-256 of the *new* snapshot file bytes. When root evidence changes, this map must exactly equal the added or changed paths; deletions of LICENSE/NOTICE/COPYING are never accepted.", "additionalProperties": { "type": "string", "pattern": "^[a-f0-9]{64}$" } }, "acceptedCollectionPaths": { "type": "array", "description": "Exact set of new collection membership install paths when discovered children differ from the old entry. Must equal the discovered path set. Newly added members also require acceptedFrontmatterSha256 for that path.", "items": { "type": "string", "minLength": 1 }, "uniqueItems": true }, "acceptedScopedNotice": { "type": "object", "description": "Exact in-place additive NOTICE changes inside the install scope. LICENSE/COPYING, deletions, renames, new files, rewrites that drop existing bytes, globs, and root-level NOTICE (use acceptedRootEvidenceSha256) cannot be accepted here. fromRef/toRef must equal the audit's old and new snapshot SHAs, and files must be exactly the changed NOTICE paths with matching previous and new SHA-256 hashes.", "additionalProperties": false, "required": ["fromRef", "toRef", "files"], "properties": { "fromRef": { "type": "string", "pattern": "^[0-9a-f]{40}$" }, "toRef": { "type": "string", "pattern": "^[0-9a-f]{40}$" }, "files": { "type": "array", "minItems": 1, "items": { "type": "object", "additionalProperties": false, "required": ["path", "previousSha256", "sha256"], "properties": { "path": { "type": "string", "minLength": 1 }, "previousSha256": { "type": "string", "pattern": "^[a-f0-9]{64}$" }, "sha256": { "type": "string", "pattern": "^[a-f0-9]{64}$" } } } } } }, "acceptedRootLicenseDirectoryManifestSha256": { "type": "object", "description": "Map of a repo-root LICENSE*/NOTICE*/COPYING* directory name (for example licenses) to the SHA-256 of the canonical JSON manifest of regular files under that directory at the *new* snapshot (sorted path to file SHA-256). Required when those directory file sets change, including renames. This does not accept changes to, replacements of, or deletions of root LICENSE/NOTICE/COPYING files (deletions remain forbidden; file changes still use acceptedRootEvidenceSha256). Symlinks, submodules, and other non-regular files at those root names or inside the directory remain blocked.", "additionalProperties": { "type": "string", "pattern": "^[a-f0-9]{64}$" } }, "acceptedClientAttachedNotices": { "type": "object", "description": "Bound install-readback evidence that a verified DesireCore client commit attached collection/repo-root LICENSE/NOTICE/COPYING files into each selected install copy. This is not a license exception and does not treat a root file seen at audit time, or a future client change, as delivery. sourceRef must equal the audit's new pin; clientCommit must be an already-verified attach implementation (not a descendant tip by default); noticeSha256 must equal the regular root notice file at that pin; scopes must be exactly the install paths with per-copy attached name/sourceName/sha256 matching that root notice. The acceptance does not automatically extend to a later pin.", "additionalProperties": false, "required": ["sourceRef", "clientCommit", "noticeRootPath", "noticeSha256", "scopes"], "properties": { "sourceRef": { "type": "string", "pattern": "^[0-9a-f]{40}$" }, "clientCommit": { "type": "string", "pattern": "^[0-9a-f]{40}$" }, "clientTree": { "type": "string", "pattern": "^[0-9a-f]{40}$" }, "clientReleaseTag": { "type": "string", "description": "Optional shipped official DesireCore release tag (e.g. v10.0.214) verified to include clientCommit without unverified staging/install drift. Required when allowCarryForwardWhenUnchanged is true.", "pattern": "^v\\d+\\.\\d+\\.\\d+(?:-[0-9A-Za-z.-]+)?$" }, "allowCarryForwardWhenUnchanged": { "type": "boolean", "description": "When true (requires clientReleaseTag), allows the verified client-attached notice proof to carry forward to newer pins ONLY when the root notice bytes at the new pin are byte-identical to noticeSha256, install scopes are unchanged, and no colliding top-level LICENSE/NOTICE/COPYING file exists in any install scope. All other audits still run in full." }, "observedAt": { "type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}T\\d{2}:\\d{2}:\\d{2}Z$" }, "noticeRootPath": { "type": "string", "minLength": 1 }, "noticeSha256": { "type": "string", "pattern": "^[a-f0-9]{64}$" }, "scopes": { "type": "array", "minItems": 1, "items": { "type": "object", "additionalProperties": false, "required": ["path", "attached"], "properties": { "path": { "type": "string", "minLength": 1 }, "contentDigest": { "type": "string", "pattern": "^[a-f0-9]{64}$" }, "attached": { "type": "array", "minItems": 1, "items": { "type": "object", "additionalProperties": false, "required": ["name", "sourceName", "sha256"], "properties": { "name": { "type": "string", "minLength": 1 }, "sourceName": { "type": "string", "minLength": 1 }, "sha256": { "type": "string", "pattern": "^[a-f0-9]{64}$" } } } } } } } } }, "acceptedDescriptionAndLocales": { "type": "object", "description": "Human review that market listing shortDesc/summary copy was updated to match a changed upstream SKILL.md description. Bound to the exact old and new pins and to each affected install path. Files must be exactly the description-changed scopes that already have locale copy. Each locale binds the reviewed shortDesc and its SHA-256, plus the previous listing text; the English/latin shortDesc must cover distinctive new-description terms, and zh-CN must be distinct CJK rather than a leftover English or old listing string. Catalog summary mirrors must match. This is not a generic exemption and does not automatically extend to a later pin.", "additionalProperties": false, "required": ["fromRef", "toRef", "files"], "properties": { "fromRef": { "type": "string", "pattern": "^[0-9a-f]{40}$" }, "toRef": { "type": "string", "pattern": "^[0-9a-f]{40}$" }, "files": { "type": "array", "minItems": 1, "items": { "type": "object", "additionalProperties": false, "required": ["path", "oldDescription", "newDescription", "newFrontmatterSha256", "locales"], "properties": { "path": { "type": "string" }, "oldDescription": { "type": "string", "minLength": 1 }, "newDescription": { "type": "string", "minLength": 1 }, "newFrontmatterSha256": { "type": "string", "pattern": "^[a-f0-9]{64}$" }, "locales": { "type": "object", "minProperties": 1, "additionalProperties": { "type": "object", "additionalProperties": false, "required": ["shortDesc", "sha256", "previousShortDesc"], "properties": { "shortDesc": { "type": "string", "minLength": 1 }, "sha256": { "type": "string", "pattern": "^[a-f0-9]{64}$" }, "previousShortDesc": { "type": "string" } } } } } } } } }, "acceptedExactPinLicenseException": { "type": "object", "description": "Exact-pin human license exception for entries without a standalone LICENSE file (e.g. one-line README MIT declaration). Never inherited automatically across snapshots: fromRef/toRef must match the audited old and new pins, evidenceSha256 must match the file bytes at toRef, and reviewDoc must point to a repo-relative review document under docs/.", "additionalProperties": false, "required": ["fromRef", "toRef", "evidencePath", "evidenceSha256", "reviewDoc"], "properties": { "fromRef": { "type": "string", "pattern": "^[0-9a-f]{40}$" }, "toRef": { "type": "string", "pattern": "^[0-9a-f]{40}$" }, "evidencePath": { "type": "string", "minLength": 1 }, "evidenceSha256": { "type": "string", "pattern": "^[a-f0-9]{64}$" }, "reviewDoc": { "type": "string", "minLength": 1 } } }, "acceptedBehavioralSecurityReview": { "type": "object", "description": "Exact-pin read-only behavioral review for updates touching credentials, browser cookies/consent, authorization/network boundaries, or .skillignore inside the install scope. Bound to fromRef/toRef, a repo-relative reviewDoc under docs/, and the reviewedPaths list. Does not extend to later pins and is not a security certification or runtime acceptance.", "additionalProperties": false, "required": ["fromRef", "toRef", "reviewDoc", "reviewedPaths"], "properties": { "fromRef": { "type": "string", "pattern": "^[0-9a-f]{40}$" }, "toRef": { "type": "string", "pattern": "^[0-9a-f]{40}$" }, "reviewDoc": { "type": "string", "minLength": 1 }, "reviewedPaths": { "type": "array", "minItems": 1, "uniqueItems": true, "items": { "type": "string", "minLength": 1 } } } }, "acceptedDataOnlyLicenseException": { "type": "object", "description": "Audited carry-forward of a catalog-specific one-line license exception (e.g. README.md MIT declaration) ONLY for updates whose entire installed-scope diff is restricted to explicit allowedDataPaths. Every non-allowlisted file (including evidencePath, SKILL.md, scripts, manifests) must be byte-identical, and when requireValidJson is true (default) every changed data file must parse as a JSON object with an identical top-level key set.", "additionalProperties": false, "required": ["evidencePath", "evidenceSha256", "allowedDataPaths"], "properties": { "evidencePath": { "type": "string", "minLength": 1 }, "evidenceSha256": { "type": "string", "pattern": "^[a-f0-9]{64}$" }, "allowedDataPaths": { "type": "array", "minItems": 1, "uniqueItems": true, "items": { "type": "string", "minLength": 1 } }, "requireValidJson": { "type": "boolean", "default": true } } } }, "allOf": [ { "if": { "required": ["acceptedScopedNotice"] }, "then": { "required": ["reviewedBy", "reviewedAt", "notes"] } }, { "if": { "required": ["acceptedRootLicenseDirectoryManifestSha256"] }, "then": { "required": ["reviewedBy", "reviewedAt", "notes"] } }, { "if": { "required": ["acceptedClientAttachedNotices"] }, "then": { "required": ["reviewedBy", "reviewedAt", "notes"] } }, { "if": { "required": ["acceptedDescriptionAndLocales"] }, "then": { "required": ["reviewedBy", "reviewedAt", "notes"] } }, { "if": { "required": ["acceptedExactPinLicenseException"] }, "then": { "required": ["reviewedBy", "reviewedAt", "notes"] } }, { "if": { "required": ["acceptedBehavioralSecurityReview"] }, "then": { "required": ["reviewedBy", "reviewedAt", "notes"] } }, { "if": { "required": ["acceptedDataOnlyLicenseException"] }, "then": { "required": ["reviewedBy", "reviewedAt", "notes"] } } ] }