@blamejs/core 0.13.6 → 0.13.7

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/CHANGELOG.md CHANGED
@@ -8,6 +8,8 @@ upgrading across more than a few patches at a time.
8
8
 
9
9
  ## v0.13.x
10
10
 
11
+ - v0.13.7 (2026-05-26) — **Documentation accuracy — several primitives described shipped features as deferred.** A documentation sweep corrected primitive descriptions that still called features deferred after they shipped, so the wiki and inline docs now match the code. b.mdoc documents that device authentication (the ISO 18013-5 §9.1.3 signature variant, verifyDeviceAuth) is verified, not deferred — only the COSE_Mac0 device-auth variant remains refused. b.network.dns.dnssec documents that the root-to-zone chain walk against the IANA trust anchors (verifyChain) and NSEC / NSEC3 denial of existence (verifyDenial / nsec3Hash) ship, where the card previously said they were deferred. b.cose lists COSE_Mac0 and COSE_Encrypt0 among what it ships. The JMAP server documents its push channel, blob upload/download, and EmailSubmission handlers as present, and the submission server documents CHUNKING / BDAT as supported. A new test detector keeps this class of drift from recurring: it fails the build when a comment promises a feature lands in a version that has already shipped. **Fixed:** *Corrected `deferred`/`does-not-ship` docs for features that have shipped* — `b.mdoc` (device authentication, §9.1.3), `b.network.dns.dnssec` (chain walk + NSEC/NSEC3), `b.cose` (COSE_Mac0 + COSE_Encrypt0), the JMAP server (push, blob, EmailSubmission), and the submission server (BDAT/CHUNKING) all carried `@card`/`@intro` text describing shipped capabilities as deferred or not-shipped. The descriptions now match the implemented surface; genuinely-deferred items (the mdoc MAC variant, DNSSEC in-RDATA name canonicalization, COSE multi-signer/multi-recipient) remain documented as such. **Detectors:** *Overdue-defer detector in the codebase-pattern gate* — A new check fails the build when a comment promises a feature "lands in" / is "deferred to" / is "not supported in" a version that the package has already reached — catching stale deferral notes (a feature that shipped but whose comment still says otherwise, or a missed deadline) before they reach a release. An allowlist records the deliberate defer-with-condition exceptions.
12
+
11
13
  - v0.13.6 (2026-05-26) — **`b.ai.frontierModelProtocol` — California SB 53 frontier-AI obligations.** b.ai.frontierModelProtocol assesses a developer's obligations under California's Transparency in Frontier Artificial Intelligence Act — SB 53, Cal. Bus. & Prof. Code §22757.10, effective 2026-01-01 — from a model's training compute and the developer's revenue. It reports whether the model crosses the frontier threshold (more than 10^26 training FLOPs), whether the developer is a large frontier developer (prior-year revenue, with affiliates, above $500M), and the resulting obligations: every frontier developer must report critical safety incidents and publish a transparency report, and a large frontier developer must additionally publish an annual safety framework and disclose its catastrophic-risk assessment. Passing a candidate safety framework reports which required elements (risk identification, mitigation, governance, cybersecurity, standards alignment) are missing. b.ai.frontierModelProtocol.incidentReport validates a critical-incident type against the Act's four categories and computes the notification deadline to the California Office of Emergency Services — 15 days from discovery, or 24 hours when there is an imminent risk of death or serious physical injury. The ca-tfaia compliance posture was already in the catalog. **Added:** *`b.ai.frontierModelProtocol` — SB 53 threshold classification, obligations, and incident reporting* — `b.ai.frontierModelProtocol({ trainingFlops, annualRevenueUsd, framework? })` returns `isFrontierModel`, `isLargeFrontierDeveloper`, the `obligations` list, and (when a framework is supplied) its `frameworkGaps`. `b.ai.frontierModelProtocol.incidentReport({ type, discoveredAt, imminentRiskToLife? })` builds a critical-safety-incident report with the California OES recipient and a `dueAt` / `deadlineHours` computed from the 15-day (or 24-hour imminent-risk) statutory window; `type` must be one of the four categories in `INCIDENT_TYPES`. Throws `FrontierProtocolError` on malformed input.
12
14
 
13
15
  - v0.13.5 (2026-05-26) — **`b.ai.aedtBiasAudit` — NYC Local Law 144 bias audit.** b.ai.aedtBiasAudit computes the bias-audit figures New York City Local Law 144 requires before an Automated Employment Decision Tool may screen candidates (NYC Admin. Code §20-870 et seq.; DCWP rules 6 RCNY §5-300). Given the per-category counts an independent auditor collected — selected/total for a pass-fail tool, or scored-above-the-overall-median/total for a continuous-score tool — it returns the selection (or scoring) rate, the impact ratio (each group's rate divided by the most-selected group's rate), and an adverse-impact flag (impact ratio below the EEOC four-fifths threshold of 0.8) for every group, across the sex, race/ethnicity, and intersectional dimensions, plus the most-selected group per dimension and an overall flag. Categories under 2% of the audited data are marked excluded per DCWP discretion. It is a pure calculation that produces exactly the figures the annual published summary must contain — the law mandates the calculation, not any particular remediation. The relevant compliance postures (nyc-ll144, and ca-tfaia for California SB 53) were already in the catalog. **Added:** *`b.ai.aedtBiasAudit` — Local Law 144 selection/scoring rates and four-fifths impact ratios* — `b.ai.aedtBiasAudit({ type, metadata, categories, minCategoryShare? })` where `type` is `"selection"` (group entries `{ selected, total }`) or `"scoring"` (`{ scoredAboveMedian, total }`). Returns per-group rate, impact ratio, and `adverseImpact` flag across the `sex`, `raceEthnicity`, and `intersectional` dimensions, plus the most-selected group per dimension and an `anyAdverseImpact` summary. Categories below `minCategoryShare` (2% default) are excluded from the impact-ratio basis. Throws `AedtBiasAuditError` on malformed input.
@@ -187,9 +187,8 @@ function chatbot(session, opts) {
187
187
  * machine-readable manner. This primitive returns the disclosure
188
188
  * payload (visible label + structured metadata) the operator wires
189
189
  * into the encoder / response pipeline. C2PA manifest emission is
190
- * deferred to v0.12.21 `b.contentCredentials` this primitive
191
- * supplies the label markup and the metadata schema that the C2PA
192
- * adapter consumes when it lands.
190
+ * handled by `b.contentCredentials`; this primitive supplies the label
191
+ * markup and the metadata schema that the C2PA adapter consumes.
193
192
  *
194
193
  * @opts
195
194
  * contentType: "image" | "audio" | "video" | "text", // required
@@ -56,11 +56,10 @@
56
56
  * - CVE-2024-12905 / CVE-2025-48387 (tar-fs path traversal).
57
57
  * - CVE-2025-4138 / 4330 (Python tarfile data filter bypass).
58
58
  *
59
- * Out of scope (v1):
59
+ * Compression is via `b.archive.gz` composition (tar.gz). Out of scope
60
+ * (v1):
60
61
  * - Sparse-file emission (read reconstructs them; write doesn't
61
62
  * produce sparse).
62
- * - Compression (tar.gz lands v0.12.9 via `b.archive.gz`
63
- * composition).
64
63
  * - BSD-tar extensions beyond pax.
65
64
  *
66
65
  * @card
@@ -1028,9 +1028,8 @@ module.exports = {
1028
1028
  * Adapter-driven storage backend. Wraps the bundle directory's file
1029
1029
  * tree into per-file key-value pairs routed through an operator-
1030
1030
  * supplied byte-store adapter so backup bundles can land anywhere
1031
- * that exposes the contract (local fs is the v0.12.7 default; tar
1032
- * folding lands v0.12.8, tar.gz v0.12.9, S3/MinIO/Azure/GCS
1033
- * objectStore v0.12.11).
1031
+ * that exposes the contract: local fs (the default), tar / tar.gz
1032
+ * folding, and S3 / MinIO / Azure / GCS objectStore adapters.
1034
1033
  *
1035
1034
  * The adapter contract (small surface; an `fs` implementation is the
1036
1035
  * default + ships in `lib/backup/_adapter-fs.js`):
package/lib/cose.js CHANGED
@@ -41,9 +41,10 @@
41
41
  * 2) listing a header label the verifier does not understand is
42
42
  * refused (RFC 9052 §3.1) — a crit-bypass defense.
43
43
  *
44
- * v1 ships COSE_Sign1 (single-signer) with an attached payload.
45
- * Detached payload, COSE_Sign (multi-signer), COSE_Mac0, and
46
- * COSE_Encrypt are deferred-with-condition (operator demand).
44
+ * Ships COSE_Sign1 (single-signer, attached payload), COSE_Mac0, and
45
+ * COSE_Encrypt0 (single-recipient AEAD). Detached payload, COSE_Sign
46
+ * (multi-signer), and COSE_Encrypt (multi-recipient) are
47
+ * deferred-with-condition (operator demand).
47
48
  *
48
49
  * @card
49
50
  * COSE_Sign1 sign / verify (RFC 9052) over the in-tree CBOR codec —
@@ -95,17 +95,17 @@
95
95
  * - `urn:ietf:params:jmap:error:accountNotFound`
96
96
  * - `urn:ietf:params:jmap:error:serverFail` (opaque last-resort)
97
97
  *
98
+ * ## Beyond Core + Mail, this also ships
99
+ *
100
+ * - **Push channel (RFC 8887)** — `eventSourceHandler` (SSE) and
101
+ * `webSocketHandler` (WebSocket, with `StateChange` push).
102
+ * - **Blob upload/download (RFC 8620 §6)** — `uploadHandler` /
103
+ * `downloadHandler`, routing uploads through the guard-* family.
104
+ * - **EmailSubmission/set (RFC 8621 §7.5)** — `emailSubmissionSetHandler`,
105
+ * composing `b.mail.send.deliver`.
106
+ *
98
107
  * ## What v1 does NOT ship
99
108
  *
100
- * - **Push channel (SSE + WebSocket per RFC 8887)** — operator wires
101
- * `b.sse` or `b.websocket` to the `pushSubscribe` hook. v1.5
102
- * bundles a turnkey push handler.
103
- * - **Blob upload/download endpoints** — operator wires their own
104
- * `/jmap/upload` / `/jmap/download` handlers; the framework
105
- * supplies `b.storage` + `b.objectStore` + the guard-* family
106
- * for the actual upload path.
107
- * - **EmailSubmission (RFC 8621 §7)** — operator wires the bridge
108
- * to `b.mail.server.submission`'s outbound agent.
109
109
  * - **Calendars / Contacts (RFC 9610)**, **Sieve (RFC 9404)**,
110
110
  * **MDN (RFC 9007)** — opt-in capabilities.
111
111
  *
@@ -79,11 +79,12 @@
79
79
  *
80
80
  * - **DKIM signing pre-relay** — operator wires `b.mail.dkim.sign`
81
81
  * in their outbound agent.
82
- * - **CHUNKING (BDAT) extension** — RFC 3030 BDAT not yet
83
- * supported on submission; clients use DATA instead.
84
82
  * - **Per-actor outbound quota** — operator implements via
85
83
  * `b.dailyByteQuota` against the authenticated actor.
86
84
  *
85
+ * (CHUNKING / BDAT, RFC 3030, IS supported — advertised in EHLO and
86
+ * handled alongside DATA.)
87
+ *
87
88
  * ## Composition contract
88
89
  *
89
90
  * Every gate is a primitive that already exists. Submission listener
package/lib/mdoc.js CHANGED
@@ -30,22 +30,22 @@
30
30
  * <code>opts.trustAnchorsPem</code> additionally verifies the issuer
31
31
  * certificate chain and its validity at the asserted time.
32
32
  *
33
- * <strong>Scope.</strong> This is issuer-data authentication
34
- * (ISO 18013-5 §9.1.2.4) — the data is genuine and issuer-signed. The
35
- * mdoc <em>device authentication</em> half (DeviceSigned / the
36
- * SessionTranscript-bound holder-binding proof, §9.1.3) is deferred:
37
- * it needs the live session transcript a verifier negotiates, so it is
38
- * a presentation-protocol concern rather than a credential check.
39
- * Composes <code>b.cose</code> + <code>b.cbor</code>; no new runtime
40
- * dependency. Distinct from W3C VCDM (<code>b.vc</code>) and IETF
41
- * SD-JWT VC (<code>b.auth.sdJwtVc</code>) the three credential
42
- * ecosystems.
33
+ * <strong>Scope.</strong> Two halves are verified: issuer-data
34
+ * authentication (ISO 18013-5 §9.1.2.4 — the data is genuine and
35
+ * issuer-signed, via <code>verifyIssuerSigned</code>) and mdoc device
36
+ * authentication (§9.1.3 holder binding over the verifier's
37
+ * <code>SessionTranscript</code>, via <code>verifyDeviceAuth</code>).
38
+ * Device auth covers the COSE_Sign1 signature variant; the COSE_Mac0
39
+ * (deviceMac) variant is refused rather than mis-verified. Composes
40
+ * <code>b.cose</code> + <code>b.cbor</code>; no new runtime dependency.
41
+ * Distinct from W3C VCDM (<code>b.vc</code>) and IETF SD-JWT VC
42
+ * (<code>b.auth.sdJwtVc</code>) — the three credential ecosystems.
43
43
  *
44
44
  * @card
45
- * ISO 18013-5 mdoc / mDL issuer-data verification — checks the
46
- * COSE_Sign1 IssuerAuth, the MSO validity window, and every disclosed
47
- * element's digest against the Mobile Security Object. Composes
48
- * b.cose + b.cbor; device-auth holder-binding deferred.
45
+ * ISO 18013-5 mdoc / mDL verification — issuer-data (COSE_Sign1
46
+ * IssuerAuth, MSO validity window, disclosed-element digests) plus
47
+ * device-auth holder binding (§9.1.3 signature variant over the session
48
+ * transcript). Composes b.cose + b.cbor.
49
49
  */
50
50
 
51
51
  var nodeCrypto = require("node:crypto");
@@ -30,16 +30,18 @@
30
30
  * <code>dnssec/uncanonicalizable-type</code> rather than mis-validated
31
31
  * — the security-critical DNSKEY / DS and the name-free address /
32
32
  * text types (A, AAAA, TXT, …) are fully supported. The recursive
33
- * chain-walk (root → TLD → zone), NSEC / NSEC3 denial-of-existence,
34
- * and the IANA root trust-anchor bundle are deferred: these primitives
35
- * are the per-RRset building blocks a chain-walker composes.
33
+ * chain-walk (root → TLD → zone via <code>verifyChain</code> against the
34
+ * bundled IANA root trust anchors) and NSEC / NSEC3 denial-of-existence
35
+ * (<code>verifyDenial</code> / <code>nsec3Hash</code>) ship alongside the
36
+ * per-RRset verification core.
36
37
  *
37
38
  * @card
38
- * Local DNSSEC verification (RFC 4035) — verify an RRSIG over a
39
- * canonicalised RRset against a DNSKEY (RSA / ECDSA P-256·P-384 /
40
- * Ed25519), plus DS-digest + key-tag. Don't trust the upstream AD bit;
41
- * verify the signature. Name-bearing RR types are refused, not
42
- * mis-validated; chain-walk + NSEC3 deferred.
39
+ * Local DNSSEC verification (RFC 4035 / 4034 / 5155) — verify an RRSIG
40
+ * over a canonicalised RRset against a DNSKEY (RSA / ECDSA P-256·P-384 /
41
+ * Ed25519) + DS-digest + key-tag, walk the root→zone chain to the IANA
42
+ * trust anchors, and check NSEC / NSEC3 denial of existence. Don't trust
43
+ * the upstream AD bit; verify the signature. Name-bearing RR types are
44
+ * refused, not mis-validated.
43
45
  */
44
46
 
45
47
  var nodeCrypto = require("node:crypto");
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@blamejs/core",
3
- "version": "0.13.6",
3
+ "version": "0.13.7",
4
4
  "description": "The Node framework that owns its stack.",
5
5
  "license": "Apache-2.0",
6
6
  "author": "blamejs contributors",
package/sbom.cdx.json CHANGED
@@ -2,10 +2,10 @@
2
2
  "$schema": "http://cyclonedx.org/schema/bom-1.5.schema.json",
3
3
  "bomFormat": "CycloneDX",
4
4
  "specVersion": "1.5",
5
- "serialNumber": "urn:uuid:4234e2f1-7c10-42c0-8f19-b429101d42d1",
5
+ "serialNumber": "urn:uuid:22a52afe-2217-4e18-a7a1-15e6a137ec0c",
6
6
  "version": 1,
7
7
  "metadata": {
8
- "timestamp": "2026-05-27T03:23:03.075Z",
8
+ "timestamp": "2026-05-27T04:39:38.785Z",
9
9
  "lifecycles": [
10
10
  {
11
11
  "phase": "build"
@@ -19,14 +19,14 @@
19
19
  }
20
20
  ],
21
21
  "component": {
22
- "bom-ref": "@blamejs/core@0.13.6",
22
+ "bom-ref": "@blamejs/core@0.13.7",
23
23
  "type": "application",
24
24
  "name": "blamejs",
25
- "version": "0.13.6",
25
+ "version": "0.13.7",
26
26
  "scope": "required",
27
27
  "author": "blamejs contributors",
28
28
  "description": "The Node framework that owns its stack.",
29
- "purl": "pkg:npm/%40blamejs/core@0.13.6",
29
+ "purl": "pkg:npm/%40blamejs/core@0.13.7",
30
30
  "properties": [],
31
31
  "externalReferences": [
32
32
  {
@@ -54,7 +54,7 @@
54
54
  "components": [],
55
55
  "dependencies": [
56
56
  {
57
- "ref": "@blamejs/core@0.13.6",
57
+ "ref": "@blamejs/core@0.13.7",
58
58
  "dependsOn": []
59
59
  }
60
60
  ]