@xemahq/biome-supply-chain 0.1.0 → 0.1.2
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/LICENSE +1 -1
- package/README.md +7 -1
- package/dist/lib/cosign-exec.d.ts +9 -9
- package/dist/lib/cosign-exec.d.ts.map +1 -1
- package/dist/lib/verdicts.d.ts.map +1 -1
- package/dist/lib/verdicts.js.map +1 -1
- package/package.json +9 -11
- package/src/lib/cosign-exec.ts +9 -9
- package/src/lib/verdicts.ts +9 -4
package/LICENSE
CHANGED
|
@@ -9,7 +9,7 @@ Parameters
|
|
|
9
9
|
|
|
10
10
|
Licensor: Neuralchowder Inc.
|
|
11
11
|
|
|
12
|
-
Licensed Work: Xema. The Licensed Work is (c) 2026 Neuralchowder Inc
|
|
12
|
+
Licensed Work: Xema. The Licensed Work is (c) 2026 Neuralchowder Inc.
|
|
13
13
|
|
|
14
14
|
The Licensed Work includes, without limitation, Xema Core, Xema Runtime,
|
|
15
15
|
Xema Kernel, Xema control plane, Xema application runtime, Xema biome
|
package/README.md
CHANGED
|
@@ -4,7 +4,7 @@ This package belongs to Layer 1 — a framework-free runtime SDK utility.
|
|
|
4
4
|
|
|
5
5
|
Shared cosign supply-chain verification for Xema biomes. It centralizes the two
|
|
6
6
|
things that were previously copy-pasted between `biome-fetcher-api` (OCI bundle
|
|
7
|
-
verification) and
|
|
7
|
+
verification) and `xema-store-api`:
|
|
8
8
|
|
|
9
9
|
- the single cosign CLI invocation (`ensureCosignAvailable`,
|
|
10
10
|
`verifyCosignSignature`, `verifyCosignAttestation`, `verifyCosignBlob`), and
|
|
@@ -49,3 +49,9 @@ if (outcome === CosignVerifyOutcome.Verified) {
|
|
|
49
49
|
Artifact resolution (resolving an OCI ref, or fetching + writing a blob to a
|
|
50
50
|
temp file) stays with each consumer; this package owns only the cosign exec and
|
|
51
51
|
the verdict enums.
|
|
52
|
+
|
|
53
|
+
## License
|
|
54
|
+
|
|
55
|
+
Business Source License 1.1 (BSL-1.1) — source-available; converts to MPL-2.0
|
|
56
|
+
four years after each release. © Xema — [xema.dev](https://xema.dev). See
|
|
57
|
+
the [repository LICENSE](../../../LICENSE).
|
|
@@ -3,30 +3,30 @@ export declare function ensureCosignAvailable(bin?: string): Promise<void>;
|
|
|
3
3
|
export interface VerifyCosignSignatureInput {
|
|
4
4
|
readonly ociRef: string;
|
|
5
5
|
readonly trustedIdentities: readonly string[];
|
|
6
|
-
readonly oidcIssuer?: string;
|
|
7
|
-
readonly keyPath?: string;
|
|
8
|
-
readonly bin?: string;
|
|
6
|
+
readonly oidcIssuer?: string | undefined;
|
|
7
|
+
readonly keyPath?: string | undefined;
|
|
8
|
+
readonly bin?: string | undefined;
|
|
9
9
|
}
|
|
10
10
|
export declare function verifyCosignSignature(input: VerifyCosignSignatureInput): Promise<void>;
|
|
11
11
|
export interface VerifyCosignAttestationInput {
|
|
12
12
|
readonly ociRef: string;
|
|
13
13
|
readonly predicateType: string;
|
|
14
14
|
readonly trustedIdentities: readonly string[];
|
|
15
|
-
readonly oidcIssuer?: string;
|
|
16
|
-
readonly keyPath?: string;
|
|
17
|
-
readonly bin?: string;
|
|
15
|
+
readonly oidcIssuer?: string | undefined;
|
|
16
|
+
readonly keyPath?: string | undefined;
|
|
17
|
+
readonly bin?: string | undefined;
|
|
18
18
|
}
|
|
19
19
|
export declare function verifyCosignAttestation(input: VerifyCosignAttestationInput): Promise<void>;
|
|
20
20
|
export interface VerifyCosignBlobInput {
|
|
21
21
|
readonly artifactPath: string;
|
|
22
22
|
readonly bundlePath: string;
|
|
23
23
|
readonly trustedIdentityRegexps: readonly string[];
|
|
24
|
-
readonly oidcIssuer?: string;
|
|
25
|
-
readonly bin?: string;
|
|
24
|
+
readonly oidcIssuer?: string | undefined;
|
|
25
|
+
readonly bin?: string | undefined;
|
|
26
26
|
}
|
|
27
27
|
export interface VerifyCosignBlobResult {
|
|
28
28
|
readonly outcome: CosignVerifyOutcome;
|
|
29
|
-
readonly matchedIdentity?: string;
|
|
29
|
+
readonly matchedIdentity?: string | undefined;
|
|
30
30
|
}
|
|
31
31
|
export declare function verifyCosignBlob(input: VerifyCosignBlobInput): Promise<VerifyCosignBlobResult>;
|
|
32
32
|
//# sourceMappingURL=cosign-exec.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"cosign-exec.d.ts","sourceRoot":"","sources":["../../src/lib/cosign-exec.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAC;AAoCjD,wBAAsB,qBAAqB,CACzC,GAAG,GAAE,MAA2B,GAC/B,OAAO,CAAC,IAAI,CAAC,CAYf;AAED,MAAM,WAAW,0BAA0B;IACzC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAExB,QAAQ,CAAC,iBAAiB,EAAE,SAAS,MAAM,EAAE,CAAC;IAC9C,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAC;
|
|
1
|
+
{"version":3,"file":"cosign-exec.d.ts","sourceRoot":"","sources":["../../src/lib/cosign-exec.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,mBAAmB,EAAE,MAAM,YAAY,CAAC;AAoCjD,wBAAsB,qBAAqB,CACzC,GAAG,GAAE,MAA2B,GAC/B,OAAO,CAAC,IAAI,CAAC,CAYf;AAED,MAAM,WAAW,0BAA0B;IACzC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAExB,QAAQ,CAAC,iBAAiB,EAAE,SAAS,MAAM,EAAE,CAAC;IAC9C,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAEzC,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACtC,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACnC;AAOD,wBAAsB,qBAAqB,CACzC,KAAK,EAAE,0BAA0B,GAChC,OAAO,CAAC,IAAI,CAAC,CAuBf;AAED,MAAM,WAAW,4BAA4B;IAC3C,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,aAAa,EAAE,MAAM,CAAC;IAC/B,QAAQ,CAAC,iBAAiB,EAAE,SAAS,MAAM,EAAE,CAAC;IAC9C,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACzC,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACtC,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACnC;AAMD,wBAAsB,uBAAuB,CAC3C,KAAK,EAAE,4BAA4B,GAClC,OAAO,CAAC,IAAI,CAAC,CAyBf;AAED,MAAM,WAAW,qBAAqB;IAEpC,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAE9B,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAE5B,QAAQ,CAAC,sBAAsB,EAAE,SAAS,MAAM,EAAE,CAAC;IACnD,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IACzC,QAAQ,CAAC,GAAG,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACnC;AAED,MAAM,WAAW,sBAAsB;IACrC,QAAQ,CAAC,OAAO,EAAE,mBAAmB,CAAC;IAEtC,QAAQ,CAAC,eAAe,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CAC/C;AASD,wBAAsB,gBAAgB,CACpC,KAAK,EAAE,qBAAqB,GAC3B,OAAO,CAAC,sBAAsB,CAAC,CAuBjC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"verdicts.d.ts","sourceRoot":"","sources":["../../src/lib/verdicts.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"verdicts.d.ts","sourceRoot":"","sources":["../../src/lib/verdicts.ts"],"names":[],"mappings":"AAqBA,oBAAY,gBAAgB;IAC1B,KAAK,UAAU;IACf,OAAO,YAAY;IACnB,QAAQ,aAAa;CACtB;AAGD,oBAAY,iBAAiB;IAC3B,KAAK,UAAU;IACf,OAAO,YAAY;IACnB,OAAO,YAAY;CACpB;AAGD,oBAAY,eAAe;IACzB,gBAAgB,4BAA4B;IAC5C,gBAAgB,4BAA4B;IAC5C,kBAAkB,yCAAyC;IAC3D,iBAAiB,6BAA6B;IAC9C,iBAAiB,6BAA6B;IAC9C,iBAAiB,6BAA6B;CAC/C;AAOD,oBAAY,mBAAmB;IAC7B,QAAQ,aAAa;IACrB,MAAM,WAAW;CAClB;AAGD,eAAO,MAAM,8BAA8B,EACzC,gCAAyC,CAAC"}
|
package/dist/lib/verdicts.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"verdicts.js","sourceRoot":"","sources":["../../src/lib/verdicts.ts"],"names":[],"mappings":";;;
|
|
1
|
+
{"version":3,"file":"verdicts.js","sourceRoot":"","sources":["../../src/lib/verdicts.ts"],"names":[],"mappings":";;;AAqBA,IAAY,gBAIX;AAJD,WAAY,gBAAgB;IAC1B,mCAAe,CAAA;IACf,uCAAmB,CAAA;IACnB,yCAAqB,CAAA;AACvB,CAAC,EAJW,gBAAgB,gCAAhB,gBAAgB,QAI3B;AAGD,IAAY,iBAIX;AAJD,WAAY,iBAAiB;IAC3B,oCAAe,CAAA;IACf,wCAAmB,CAAA;IACnB,wCAAmB,CAAA;AACrB,CAAC,EAJW,iBAAiB,iCAAjB,iBAAiB,QAI5B;AAGD,IAAY,eAOX;AAPD,WAAY,eAAe;IACzB,+DAA4C,CAAA;IAC5C,+DAA4C,CAAA;IAC5C,8EAA2D,CAAA;IAC3D,iEAA8C,CAAA;IAC9C,iEAA8C,CAAA;IAC9C,iEAA8C,CAAA;AAChD,CAAC,EAPW,eAAe,+BAAf,eAAe,QAO1B;AAOD,IAAY,mBAGX;AAHD,WAAY,mBAAmB;IAC7B,4CAAqB,CAAA;IACrB,wCAAiB,CAAA;AACnB,CAAC,EAHW,mBAAmB,mCAAnB,mBAAmB,QAG9B;AAGY,QAAA,8BAA8B,GACzC,gCAAyC,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xemahq/biome-supply-chain",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"description": "Shared cosign supply-chain verification for Xema biomes: the single cosign CLI exec + the signature/provenance verdict enums used by biome-fetcher-api (OCI
|
|
5
|
-
"license": "
|
|
3
|
+
"version": "0.1.2",
|
|
4
|
+
"description": "Shared cosign supply-chain verification for Xema biomes: the single cosign CLI exec + the signature/provenance verdict enums used by biome-fetcher-api (OCI bundle verification) and xema-store-api. Node-builtins only.",
|
|
5
|
+
"license": "LicenseRef-Xema-BSL-1.1",
|
|
6
6
|
"author": "Neuralchowder Inc. <developer@xema.dev> (https://xema.dev)",
|
|
7
7
|
"homepage": "https://xema.dev",
|
|
8
8
|
"repository": {
|
|
@@ -33,10 +33,8 @@
|
|
|
33
33
|
"src"
|
|
34
34
|
],
|
|
35
35
|
"devDependencies": {
|
|
36
|
-
"@types/node": "
|
|
37
|
-
"
|
|
38
|
-
"ts-jest": "^29.0.0",
|
|
39
|
-
"typescript": "^5.0.0"
|
|
36
|
+
"@types/node": "25.2.3",
|
|
37
|
+
"typescript": "5.9.3"
|
|
40
38
|
},
|
|
41
39
|
"keywords": [
|
|
42
40
|
"xema",
|
|
@@ -48,9 +46,9 @@
|
|
|
48
46
|
"signature-verification"
|
|
49
47
|
],
|
|
50
48
|
"scripts": {
|
|
51
|
-
"build": "tsc",
|
|
52
|
-
"
|
|
53
|
-
"
|
|
54
|
-
"
|
|
49
|
+
"build": "tsc -p tsconfig.build.json",
|
|
50
|
+
"test": "tsc -p tsconfig.json && node --test \"dist-test/test/**/*.test.js\"",
|
|
51
|
+
"typecheck": "tsc -p tsconfig.json --noEmit",
|
|
52
|
+
"clean": "rm -rf dist dist-test"
|
|
55
53
|
}
|
|
56
54
|
}
|
package/src/lib/cosign-exec.ts
CHANGED
|
@@ -56,10 +56,10 @@ export interface VerifyCosignSignatureInput {
|
|
|
56
56
|
readonly ociRef: string;
|
|
57
57
|
/** Exact keyless certificate-identity URIs (any one may match). */
|
|
58
58
|
readonly trustedIdentities: readonly string[];
|
|
59
|
-
readonly oidcIssuer?: string;
|
|
59
|
+
readonly oidcIssuer?: string | undefined;
|
|
60
60
|
/** Keyed verification: path to the public key (mutually exclusive w/ keyless). */
|
|
61
|
-
readonly keyPath?: string;
|
|
62
|
-
readonly bin?: string;
|
|
61
|
+
readonly keyPath?: string | undefined;
|
|
62
|
+
readonly bin?: string | undefined;
|
|
63
63
|
}
|
|
64
64
|
|
|
65
65
|
/**
|
|
@@ -98,9 +98,9 @@ export interface VerifyCosignAttestationInput {
|
|
|
98
98
|
readonly ociRef: string;
|
|
99
99
|
readonly predicateType: string;
|
|
100
100
|
readonly trustedIdentities: readonly string[];
|
|
101
|
-
readonly oidcIssuer?: string;
|
|
102
|
-
readonly keyPath?: string;
|
|
103
|
-
readonly bin?: string;
|
|
101
|
+
readonly oidcIssuer?: string | undefined;
|
|
102
|
+
readonly keyPath?: string | undefined;
|
|
103
|
+
readonly bin?: string | undefined;
|
|
104
104
|
}
|
|
105
105
|
|
|
106
106
|
/**
|
|
@@ -143,14 +143,14 @@ export interface VerifyCosignBlobInput {
|
|
|
143
143
|
readonly bundlePath: string;
|
|
144
144
|
/** Keyless certificate-identity REGEXPS (any one may match). */
|
|
145
145
|
readonly trustedIdentityRegexps: readonly string[];
|
|
146
|
-
readonly oidcIssuer?: string;
|
|
147
|
-
readonly bin?: string;
|
|
146
|
+
readonly oidcIssuer?: string | undefined;
|
|
147
|
+
readonly bin?: string | undefined;
|
|
148
148
|
}
|
|
149
149
|
|
|
150
150
|
export interface VerifyCosignBlobResult {
|
|
151
151
|
readonly outcome: CosignVerifyOutcome;
|
|
152
152
|
/** The identity regexp that matched, when Verified. */
|
|
153
|
-
readonly matchedIdentity?: string;
|
|
153
|
+
readonly matchedIdentity?: string | undefined;
|
|
154
154
|
}
|
|
155
155
|
|
|
156
156
|
/**
|
package/src/lib/verdicts.ts
CHANGED
|
@@ -2,10 +2,15 @@
|
|
|
2
2
|
* Shared cosign supply-chain verdict vocabulary.
|
|
3
3
|
*
|
|
4
4
|
* This is the single source of truth for the lowercase verdict/error enums
|
|
5
|
-
* that `biome-fetcher-api` (OCI bundle verification)
|
|
6
|
-
*
|
|
7
|
-
*
|
|
8
|
-
*
|
|
5
|
+
* that `biome-fetcher-api` (OCI bundle verification) previously duplicated
|
|
6
|
+
* locally. They are value-identical to that former copy, so adopting this
|
|
7
|
+
* package is a pure de-duplication with no wire/behaviour change.
|
|
8
|
+
*
|
|
9
|
+
* (`@xemahq/biome-package` was a second consumer until 2026-08-01, when it was
|
|
10
|
+
* deleted: it emitted a 4-layer OCI artifact whose layers carry no
|
|
11
|
+
* `org.opencontainers.image.title`, so the fetcher's `oras pull` skipped every
|
|
12
|
+
* one of them and materialised nothing. `xema biome publish` is now the single
|
|
13
|
+
* biome packager.)
|
|
9
14
|
*
|
|
10
15
|
* NOTE: `xema-store-api` keeps its OWN UPPERCASE `SignatureVerdict` /
|
|
11
16
|
* `ProvenanceVerdict` (persisted + OpenAPI + cross-service event wire); it
|