@nexart/mcp-server 0.1.0 → 0.2.0
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 +63 -8
- package/CONTRIBUTING.md +7 -5
- package/README.md +47 -31
- package/SECURITY.md +8 -7
- package/THIRD_PARTY_NOTICES.md +2 -2
- package/dist/contracts.js +3 -2
- package/dist/json-schema.d.ts +9 -0
- package/dist/json-schema.js +20 -0
- package/dist/lookup/contracts.js +2 -1
- package/dist/network/contracts.d.ts +2 -2
- package/dist/owner/custody.d.ts +3 -0
- package/dist/owner/custody.js +26 -16
- package/dist/protocol-safety.d.ts +3 -0
- package/dist/protocol-safety.js +16 -0
- package/dist/receipts/contracts.d.ts +2 -2
- package/dist/receipts/contracts.js +2 -1
- package/dist/record/contracts.d.ts +42 -0
- package/dist/record/contracts.js +5 -0
- package/dist/record/record.d.ts +3 -0
- package/dist/record/record.js +6 -2
- package/dist/record-tools.d.ts +3 -0
- package/dist/record-tools.js +15 -5
- package/dist/server.d.ts +11 -1
- package/dist/server.js +5 -5
- package/dist/stdio.js +3 -19
- package/dist/write/attest.d.ts +3 -0
- package/dist/write/attest.js +2 -1
- package/dist/write/contracts.d.ts +2 -2
- package/docs/consumer-guide.md +133 -0
- package/package.json +11 -4
- package/server.json +2 -2
- package/docs/age-version-compatibility.md +0 -46
- package/docs/architecture.md +0 -72
- package/docs/compatibility.md +0 -163
- package/docs/contracts.md +0 -127
- package/docs/licensing-review.md +0 -109
- package/docs/milestone-1-validation.md +0 -110
- package/docs/milestone-2.md +0 -291
- package/docs/milestone-3.2.md +0 -291
- package/docs/milestone-3.md +0 -274
- package/docs/milestone-4a.md +0 -221
- package/docs/milestone-4b1.md +0 -220
- package/docs/milestone-4b2.md +0 -260
- package/docs/public-default.md +0 -263
- package/docs/recording-schema-compatibility.md +0 -46
- package/docs/release.md +0 -311
- package/docs/security-fixes.md +0 -47
- package/docs/security.md +0 -195
- package/docs/standalone-acceptance.md +0 -81
- package/docs/validation.md +0 -85
package/docs/milestone-2.md
DELETED
|
@@ -1,291 +0,0 @@
|
|
|
1
|
-
# Milestone 2 — contracts, implementation and acceptance
|
|
2
|
-
|
|
3
|
-
Scope: three additive read-only MCP tools. The existing four verifier schemas,
|
|
4
|
-
SDK adapters, limits, outputs and execution semantics are unchanged.
|
|
5
|
-
The executable remains private, `UNLICENSED`, version `0.1.0`. No SDK version
|
|
6
|
-
changes, external-repository edits, Git operations, publishing, database,
|
|
7
|
-
OAuth, remote multitenancy or later-milestone features are part of this work.
|
|
8
|
-
|
|
9
|
-
## New MCP contracts
|
|
10
|
-
|
|
11
|
-
All inputs are strict objects. Hashes must match `^sha256:[0-9a-f]{64}$`.
|
|
12
|
-
No caller-selected URL, origin, manifest, key, pin, lifecycle exception, path,
|
|
13
|
-
credential or alternate Node is accepted.
|
|
14
|
-
|
|
15
|
-
### `nexart_lookup_cer`
|
|
16
|
-
|
|
17
|
-
Input: `{ "certificateHash": "sha256:<64 lowercase hex>" }`.
|
|
18
|
-
|
|
19
|
-
GET `/v1/resolve/cer/:certificateHash`, validating `ok`, `schemaVersion:"1.0"`,
|
|
20
|
-
`artifactType:"cer"`, top-level identity, proof, verification, bundle and links.
|
|
21
|
-
Unknown upstream extensions are discarded by the disclosure projection;
|
|
22
|
-
they are not tool output. Identity/proof/bundle/receipt hashes must all equal
|
|
23
|
-
the requested hash. Any additional declared certificate hash in an envelope,
|
|
24
|
-
its bundle/attestation or canonical-certificate metadata must agree too.
|
|
25
|
-
The declared identity bundle type must match the returned bundle.
|
|
26
|
-
|
|
27
|
-
Recognized complete bundles are checked by the same published SDK dispatch
|
|
28
|
-
as the offline tools. Original/canonical content is never fetched separately,
|
|
29
|
-
used to repair a redacted projection, reconstructed or resealed.
|
|
30
|
-
|
|
31
|
-
### `nexart_lookup_project_bundle`
|
|
32
|
-
|
|
33
|
-
Input: `{ "projectHash": "sha256:<64 lowercase hex>" }`.
|
|
34
|
-
|
|
35
|
-
GET `/v1/resolve/project/:projectHash`, validating the published resolver
|
|
36
|
-
contract and matching top-level, proof, bundle-integrity and optional
|
|
37
|
-
Project-receipt hashes. A null historical bundle/receipt is handled explicitly.
|
|
38
|
-
Local integrity requires published `verifyProjectBundle` success **and
|
|
39
|
-
`projectHashValid === true`**. No Node aggregate verdict is authoritative.
|
|
40
|
-
The Project receipt's presence does not authenticate it.
|
|
41
|
-
|
|
42
|
-
### Lookup output, both tools
|
|
43
|
-
|
|
44
|
-
```text
|
|
45
|
-
contractVersion: "1"
|
|
46
|
-
lookup: found | not_found_or_not_public | unavailable | rejected
|
|
47
|
-
reasonCode: fixed wrapper code or safely projected published SDK code
|
|
48
|
-
family: recognized family or null
|
|
49
|
-
integrity: valid | invalid | indeterminate | not_performed
|
|
50
|
-
integrityScope: "returned_bundle"
|
|
51
|
-
sdk: existing allowlisted SDK result projection or null
|
|
52
|
-
receiptPresent: boolean
|
|
53
|
-
nodeSignature: "not_performed"
|
|
54
|
-
signerTrust: "not_established"
|
|
55
|
-
limitations: fixed scope statements
|
|
56
|
-
```
|
|
57
|
-
|
|
58
|
-
`found` is lookup success, not verification success. Redacted material that
|
|
59
|
-
prevents checking the original produces `indeterminate`/`not_performed`,
|
|
60
|
-
never an assertion that the original failed integrity. A supported complete
|
|
61
|
-
bundle with a locally detected hash failure produces `invalid`. Unknown
|
|
62
|
-
families are not verified. No bundle, content, prompt, I/O, openings, salts,
|
|
63
|
-
canonical strings, account metadata, internal identifiers, full receipt,
|
|
64
|
-
envelope, key material or raw SDK/Node diagnostics is returned.
|
|
65
|
-
|
|
66
|
-
HTTP 404 maps to `NOT_FOUND_OR_NOT_PUBLIC`: private, hidden, deleted,
|
|
67
|
-
nonexistent and backend-masked absence cannot be distinguished. It never
|
|
68
|
-
asserts that a private artifact exists. HTTP 409 permits only allowlisted
|
|
69
|
-
`INCOMPLETE_PROOF`/`INTEGRITY_MISMATCH` body codes and reports
|
|
70
|
-
`UPSTREAM_INCOMPLETE_PROOF`/`UPSTREAM_INTEGRITY_MISMATCH`; these are upstream
|
|
71
|
-
claims, not locally verified integrity failures. Other conflicts are
|
|
72
|
-
`UPSTREAM_PROOF_CONFLICT`; 429 is `RATE_LIMITED`; 5xx is
|
|
73
|
-
`UPSTREAM_UNAVAILABLE`. Raw diagnostic messages are always discarded.
|
|
74
|
-
|
|
75
|
-
### `nexart_verify_node_receipt`
|
|
76
|
-
|
|
77
|
-
Two input modes:
|
|
78
|
-
|
|
79
|
-
```json
|
|
80
|
-
{"source":"public_lookup","certificateHash":"sha256:<64 lowercase hex>"}
|
|
81
|
-
```
|
|
82
|
-
|
|
83
|
-
```text
|
|
84
|
-
{
|
|
85
|
-
source: "inline",
|
|
86
|
-
certificateHash: "sha256:<64 lowercase hex>",
|
|
87
|
-
receipt: complete signed CER receipt object,
|
|
88
|
-
signatureB64Url: detached signature string
|
|
89
|
-
}
|
|
90
|
-
```
|
|
91
|
-
|
|
92
|
-
The public mode rejects inline receipt/signature fields. Inline mode requires
|
|
93
|
-
both. Both modes require an external expected certificate hash; the wrapper
|
|
94
|
-
never takes the expected identity from the receipt itself.
|
|
95
|
-
|
|
96
|
-
Supported signed fields:
|
|
97
|
-
|
|
98
|
-
* `receiptVersion:"attestation.receipt.v1"`, `attestationId`, `certificateHash`,
|
|
99
|
-
`nodeRuntimeHash`, `protocolVersion`, `nodeId`, `attestorKeyId`.
|
|
100
|
-
* Optional signed `attestedAt`, `timestampType`, `timestampStatus`,
|
|
101
|
-
`timestampProvider`. Missing/invalid time prevents lifecycle acceptance.
|
|
102
|
-
|
|
103
|
-
Current protocol versions are `1.2.0`, `1.3.0`, `1.3.1`. Extra receipt fields
|
|
104
|
-
are rejected, never silently stripped before verification. The complete
|
|
105
|
-
original accepted object is passed unchanged to the published AI SDK
|
|
106
|
-
`verifyNodeReceiptSignature`. No handwritten Ed25519/canonicalization exists
|
|
107
|
-
in runtime. Project receipt versions are `UNSUPPORTED_RECEIPT_VERSION`; no
|
|
108
|
-
renaming `projectHash`/`registeredAt` into CER fields or structural casts to
|
|
109
|
-
invent compatibility occur.
|
|
110
|
-
|
|
111
|
-
Output is a strict safe summary:
|
|
112
|
-
|
|
113
|
-
```text
|
|
114
|
-
contractVersion: "1"
|
|
115
|
-
reasonCode
|
|
116
|
-
signature: valid | invalid | not_performed
|
|
117
|
-
hashBinding: match | mismatch | not_performed
|
|
118
|
-
nodeIdentity: match | mismatch | not_established
|
|
119
|
-
keyStatus: active | deprecated | revoked | unknown | unavailable
|
|
120
|
-
keyLifecycle: valid | invalid | unknown
|
|
121
|
-
lifecycleCode
|
|
122
|
-
signerTrust: trusted_under_policy | rejected | not_established
|
|
123
|
-
artifactIntegrity: "not_performed"
|
|
124
|
-
sdk: {ok, code} | null
|
|
125
|
-
limitations: fixed scope statements
|
|
126
|
-
```
|
|
127
|
-
|
|
128
|
-
`signature:valid` is mathematical verification under the selected discovery
|
|
129
|
-
key, **not approval of that key**. Signed hash/Node-identity mismatch or
|
|
130
|
-
revocation may coexist with a valid signature but cannot gain trust.
|
|
131
|
-
Timestamp fields are signed metadata, not cryptographic RFC 3161 verification.
|
|
132
|
-
Neither receipt mode claims artifact integrity, execution truth, producer
|
|
133
|
-
authorization, confidential-opening verification or completeness.
|
|
134
|
-
|
|
135
|
-
## Network controls
|
|
136
|
-
|
|
137
|
-
* Only `https://node.nexart.io`, two encoded exact-hash resolver paths and
|
|
138
|
-
`/.well-known/nexart-node.json`. No resolver-provided link is followed.
|
|
139
|
-
* GET only; no credentials, retries, conditional-cache reuse or redirects.
|
|
140
|
-
Redirect responses are rejected; 304 is not accepted as a successful lookup.
|
|
141
|
-
* Shared maximum two active operations and eight queued operations.
|
|
142
|
-
Receipt lookup plus manifest uses one slot and one operation deadline.
|
|
143
|
-
* Five-second total deadline includes queue, headers, body and post-work abort
|
|
144
|
-
checks. Caller cancellation is linked through requests and body reads.
|
|
145
|
-
* At most two requests per public-receipt operation; all others at most one.
|
|
146
|
-
* Decoded resolver body at most 1,048,576 bytes; manifest 65,536 bytes; conflict
|
|
147
|
-
diagnostic body 8,192 bytes. Declared oversized responses are rejected early.
|
|
148
|
-
Decoded streaming bytes are counted even with absent/smaller content length.
|
|
149
|
-
* JSON content type and valid UTF-8 required; lexical depth capped before
|
|
150
|
-
parsing. Existing depth/value/container limits apply to parsed responses.
|
|
151
|
-
Manifest maximum 32 keys; receipt argument maximum 16,384 bytes.
|
|
152
|
-
* Lookup logical output remains at most 262,144 bytes; receipt output is
|
|
153
|
-
inherently bounded by its fixed fields, enums and short SDK codes.
|
|
154
|
-
* Timers, listeners, readers and semaphore slots are released on completion,
|
|
155
|
-
failure, deadline and cancellation. No cache, persistence or evidence logs.
|
|
156
|
-
|
|
157
|
-
The synchronous published verifier cannot be forcibly preempted mid-call.
|
|
158
|
-
Pre-call input bounds and post-call cancellation/deadline checks apply; this
|
|
159
|
-
does not claim worker-process isolation or a hard CPU interruption guarantee.
|
|
160
|
-
|
|
161
|
-
## Trust bootstrap and lifecycle
|
|
162
|
-
|
|
163
|
-
The server expects exactly `nexart-node-prod-1`. Production key pins start
|
|
164
|
-
empty and **no live-discovered key has been approved**. The manifest alone
|
|
165
|
-
cannot establish signer trust, including its active key or a rotated key.
|
|
166
|
-
The caller cannot supply policy.
|
|
167
|
-
|
|
168
|
-
Mandatory signed `attestorKeyId` selects an exact manifest entry using the
|
|
169
|
-
published selector. The manifest is rejected on duplicate key IDs; unknown
|
|
170
|
-
IDs never fall back to `activeKid`. Unknown/unsupported key material cannot
|
|
171
|
-
produce acceptance. The published SDK performs the cryptographic check.
|
|
172
|
-
|
|
173
|
-
Server-controlled pins can independently approve a specific kid and exact
|
|
174
|
-
raw public-key material. Only a matching pin can enable scoped
|
|
175
|
-
`trusted_under_policy`, with matching hash/Node identity, valid signature and
|
|
176
|
-
known-valid lifecycle. Duplicate pins, changed material or rotation do not
|
|
177
|
-
silently gain trust. These configuration types are not MCP request fields.
|
|
178
|
-
|
|
179
|
-
Revoked keys never gain trust, even if their signatures verify. Deprecated
|
|
180
|
-
keys require an explicit usable upper bound for historical acceptance.
|
|
181
|
-
Missing, malformed or contradictory lifecycle metadata/time is unknown.
|
|
182
|
-
The SDK's lifecycle checker is called without globally dropping `notBefore`.
|
|
183
|
-
|
|
184
|
-
An audited Node behavior publishes the primary key's process boot as
|
|
185
|
-
`notBefore`, even though upstream internally may not enforce it as inception.
|
|
186
|
-
A receipt predating that advertised bound retains its signature result but
|
|
187
|
-
has **unknown historical lifecycle**, not trusted acceptance. No blanket
|
|
188
|
-
restart exception exists. Only a separately approved exact-key pin may supply
|
|
189
|
-
an explicit historical lower bound and documented provenance. None is
|
|
190
|
-
configured in production.
|
|
191
|
-
|
|
192
|
-
Discovery is not an authenticated historical/revocation archive, and
|
|
193
|
-
node-issued `attestedAt` is not independent trusted time. These limitations
|
|
194
|
-
remain even after a future pin is approved.
|
|
195
|
-
|
|
196
|
-
## Verification and reproducibility
|
|
197
|
-
|
|
198
|
-
### Observed acceptance result
|
|
199
|
-
|
|
200
|
-
**PASS — local implementation, safety tests, protocol compatibility and
|
|
201
|
-
installed-package acceptance. UNVERIFIED — positive deployed resolver
|
|
202
|
-
compatibility.** No required local check failed.
|
|
203
|
-
|
|
204
|
-
The completed isolated run on Node 24.22.1 / pnpm 10.26.1 recorded:
|
|
205
|
-
|
|
206
|
-
| Command/check | Observed result |
|
|
207
|
-
| --- | --- |
|
|
208
|
-
| `pnpm run build` (root) | PASS |
|
|
209
|
-
| `pnpm --version` (isolated checkout) | 10.26.1 |
|
|
210
|
-
| `pnpm install --frozen-lockfile --ignore-scripts` | PASS, independent checkout with shared registry cache allowed |
|
|
211
|
-
| `pnpm run build` (isolated checkout) | PASS |
|
|
212
|
-
| `pnpm exec node --test --test-concurrency=1 tests/transport.test.mjs tests/unit.test.mjs` | PASS: 45/45 original tests |
|
|
213
|
-
| `pnpm test` | PASS: 114/114; 0 failures, cancelled or skipped |
|
|
214
|
-
| `pnpm run evidence` | PASS: real stdio, both protocol revisions, all seven tools |
|
|
215
|
-
| `pnpm run benchmark` | PASS: existing eight workload checks |
|
|
216
|
-
| `pnpm pack --pack-destination <evidence-directory>` | PASS |
|
|
217
|
-
| `pnpm add --save-exact --ignore-scripts <packed-tarball>` (fresh consumer) | PASS |
|
|
218
|
-
| Consumer's installed `.bin/nexart-mcp-server` | PASS: both revisions, all seven tools; positive/tampered/unavailable/redacted calls |
|
|
219
|
-
| Installed executable stdin EOF | PASS: exit 0, no signal, JSON-RPC-only stdout |
|
|
220
|
-
|
|
221
|
-
Each protocol revision has an offline-fixture session and a synthetic-network
|
|
222
|
-
session, both in development and installed evidence. The network sessions
|
|
223
|
-
record successful CER/Project local verification, rejected tampered bundles,
|
|
224
|
-
valid receipt signatures with `signerTrust:not_established`, invalid modified
|
|
225
|
-
receipt signatures, unavailable hashes and sanitized strict-envelope errors.
|
|
226
|
-
|
|
227
|
-
The original `adapters`, `contracts`, `limits`, `results`, `stdio` and `verify`
|
|
228
|
-
source files were also compared byte-for-byte to the previously validated
|
|
229
|
-
standalone tarball: all six are unchanged. Only registration was added in
|
|
230
|
-
the original `server.ts`.
|
|
231
|
-
|
|
232
|
-
```sh
|
|
233
|
-
pnpm run build
|
|
234
|
-
pnpm run validate:release
|
|
235
|
-
```
|
|
236
|
-
|
|
237
|
-
The validator performs independent frozen installation/build, the original
|
|
238
|
-
45 tests, the expanded suite, actual development MCP stdio, package packing,
|
|
239
|
-
fresh consumer installation and the installed executable in both protocol
|
|
240
|
-
eras (`2025-11-25`, `2026-07-28`). All seven tools are discovered. The original
|
|
241
|
-
six good/tampered families and each new tool's positive, tampered, unavailable
|
|
242
|
-
and argument-redaction cases are exercised. EOF is separately observed with
|
|
243
|
-
exit zero and JSON-RPC-only stdout.
|
|
244
|
-
|
|
245
|
-
Synthetic transport uses a test-only preload replacing fetch at the fixed
|
|
246
|
-
origin. Test signing uses ephemeral in-memory test keys, never production
|
|
247
|
-
private keys. The preload is not imported by runtime and production accepts
|
|
248
|
-
no environment-based origin override. Fixtures are not an approved deployed
|
|
249
|
-
positive resolver fixture.
|
|
250
|
-
|
|
251
|
-
Read `generated-artifacts/milestone-2/release-summary.json`,
|
|
252
|
-
`baseline-tests.log`, `regression-tests.log`, `development-invocations.log`
|
|
253
|
-
and `installed-invocations.json` for observed outcomes. Prior milestone
|
|
254
|
-
evidence is retained in its original directory.
|
|
255
|
-
|
|
256
|
-
**Positive deployed resolver acceptance: UNVERIFIED.** No approved synthetic
|
|
257
|
-
public positive fixture was supplied. No private/customer artifact was used
|
|
258
|
-
to fill that gap and no upstream repository/service was changed.
|
|
259
|
-
|
|
260
|
-
Observed upstream issues remain: potentially sensitive resolver canonical/
|
|
261
|
-
context/proof sections; public redaction incompatible with full original
|
|
262
|
-
hash checking in some families; current-discovery lifecycle provenance
|
|
263
|
-
insufficient for historical key inception; distinct unsupported Project
|
|
264
|
-
receipts; indistinguishable 404s that can include backend-masked absence.
|
|
265
|
-
|
|
266
|
-
## Exact implementation file inventory
|
|
267
|
-
|
|
268
|
-
Added:
|
|
269
|
-
|
|
270
|
-
* `src/network-tools.ts`
|
|
271
|
-
* `src/network/client.ts`, `src/network/contracts.ts`
|
|
272
|
-
* `src/lookup/contracts.ts`, `src/lookup/verify.ts`
|
|
273
|
-
* `src/receipts/contracts.ts`, `src/receipts/verify.ts`
|
|
274
|
-
* `src/trust/policy.ts`, `src/trust/lifecycle.ts`
|
|
275
|
-
* `tests/network-fixtures.mjs`, `tests/network-preload.mjs`
|
|
276
|
-
* `tests/network-tools.test.mjs`
|
|
277
|
-
* `tests/network-transport.mjs`, `tests/network-transport.test.mjs`
|
|
278
|
-
* `docs/milestone-2.md`
|
|
279
|
-
|
|
280
|
-
Modified:
|
|
281
|
-
|
|
282
|
-
* `src/server.ts` — additive registrations only.
|
|
283
|
-
* `tests/client.mjs`, `tests/transport.test.mjs`
|
|
284
|
-
* `tests/transport-evidence.mjs`, `tests/installed-package.mjs`
|
|
285
|
-
* `tests/clean-install.mjs`
|
|
286
|
-
* `package.json` — description only; versions/privacy/license unchanged.
|
|
287
|
-
* `README.md`, `docs/contracts.md`, `docs/architecture.md`, `docs/compatibility.md`,
|
|
288
|
-
`docs/security.md`, `docs/validation.md`
|
|
289
|
-
* `.agents/memory/node-receipt-audit.md` — durable approved boundary, not runtime.
|
|
290
|
-
|
|
291
|
-
Generated ignored release evidence is not source or a publication.
|
package/docs/milestone-3.2.md
DELETED
|
@@ -1,291 +0,0 @@
|
|
|
1
|
-
# Controlled private live acceptance: preparation only
|
|
2
|
-
|
|
3
|
-
No live submission is authorized by preparation. No live Node request, credential
|
|
4
|
-
setup, production key approval, SDK/Node change, Git operation or publication is
|
|
5
|
-
part of this work. Public certification remains separately gated and out of scope.
|
|
6
|
-
|
|
7
|
-
## Prepared executable
|
|
8
|
-
|
|
9
|
-
`tests/acceptance/private-run.mjs` is an owner-operated local Node client for the
|
|
10
|
-
EXISTING `nexart_attest_cer` MCP tool. It is not an MCP tool, model host, new Node
|
|
11
|
-
endpoint, or second attestation implementation. Default mode is OFFLINE preflight.
|
|
12
|
-
|
|
13
|
-
```sh
|
|
14
|
-
node tests/acceptance/private-run.mjs --preflight A
|
|
15
|
-
```
|
|
16
|
-
|
|
17
|
-
This reproducibly creates only:
|
|
18
|
-
|
|
19
|
-
- `generated-artifacts/milestone-3.2/private-A/request.json`
|
|
20
|
-
- `generated-artifacts/milestone-3.2/private-A/preflight.json`
|
|
21
|
-
|
|
22
|
-
The directory is owner-only 0700, files 0600. The generated request contains the
|
|
23
|
-
CER and explicit private visibility, never original plaintext, salts/openings,
|
|
24
|
-
API credentials or model-selected transport configuration. Existing differing
|
|
25
|
-
files are rejected, not overwritten.
|
|
26
|
-
|
|
27
|
-
The deterministic SDK fixture specification is in
|
|
28
|
-
`tests/acceptance/private-fixture.mjs`. It uses published SDK 1.4.0, fixed synthetic
|
|
29
|
-
salts and artificial input/output. These salts are TEST CONSTANTS, not suitable for
|
|
30
|
-
any real customer/employee/personal evidence.
|
|
31
|
-
|
|
32
|
-
### Exact A preflight
|
|
33
|
-
|
|
34
|
-
```text
|
|
35
|
-
certificateHash:
|
|
36
|
-
sha256:ae3f28523d50f990c12d2712e8b9e3d90ea7d686c5514b99b618e2e2e4fc598c
|
|
37
|
-
verifyCerV2: OK
|
|
38
|
-
verifyConfidentialV2: AUTHENTIC (no openings supplied)
|
|
39
|
-
MCP confidential-submission profile: eligible
|
|
40
|
-
SDK sealing tool round-trip: exact matching CER
|
|
41
|
-
identity: absent
|
|
42
|
-
visibility: private
|
|
43
|
-
public enablement: false
|
|
44
|
-
plaintext/openings in request: absent
|
|
45
|
-
automatic retries: zero
|
|
46
|
-
```
|
|
47
|
-
|
|
48
|
-
AUTHENTIC is opening-free record authenticity, not proof of the original values.
|
|
49
|
-
The original IO hashes remain readable and can permit guessing/correlation;
|
|
50
|
-
the synthetic fixtures are deliberately non-sensitive.
|
|
51
|
-
|
|
52
|
-
## Source-confirmed private retrieval and credential controls
|
|
53
|
-
|
|
54
|
-
Reviewed `artnames/nexart-node` main:
|
|
55
|
-
`0adbad75bcf24580395713680571fab036f3d01f`. This is source evidence, NOT deployed
|
|
56
|
-
behaviour verification. No Node request was used to inspect these features.
|
|
57
|
-
|
|
58
|
-
### Existing owner route
|
|
59
|
-
|
|
60
|
-
`src/server.js:5070-5102`:
|
|
61
|
-
|
|
62
|
-
```http
|
|
63
|
-
GET /api/proofs/<URL-encoded-exact-certificateHash>
|
|
64
|
-
Authorization: Bearer <owner-controlled key>
|
|
65
|
-
```
|
|
66
|
-
|
|
67
|
-
It returns the proof object DIRECTLY, not `{ proof: ... }`. It calls
|
|
68
|
-
`getOwnedProofByCertificateHash` and checks exact hash equality. Source:
|
|
69
|
-
`src/db.js:1250-1268`; proof shape: `src/db.js:423-454`.
|
|
70
|
-
|
|
71
|
-
Required values:
|
|
72
|
-
|
|
73
|
-
| Value | Existing response location |
|
|
74
|
-
| --- | --- |
|
|
75
|
-
| Original CER | `proofJson` |
|
|
76
|
-
| Original identity | `proofJson.snapshot.identity`, when present |
|
|
77
|
-
| Certificate hash | `certificateHash` and `proofJson.certificateHash` |
|
|
78
|
-
| Private state | `visibilityState` |
|
|
79
|
-
| Signed receipt | `meta.receipt` |
|
|
80
|
-
| Receipt signature | `meta.receiptSignature` |
|
|
81
|
-
| Verification envelope | `meta.verificationEnvelope` |
|
|
82
|
-
| Envelope signature | `meta.verificationEnvelopeSignature` |
|
|
83
|
-
|
|
84
|
-
Account-owned proofs are available to the same authenticated account, including
|
|
85
|
-
sibling keys. Standalone-key ownership requires the same key. A foreign key does
|
|
86
|
-
not gain access merely by knowing the hash. A 404 can also mask lookup/database
|
|
87
|
-
problems, so it is not conclusive evidence that no commit occurred.
|
|
88
|
-
|
|
89
|
-
This GET is the existing authorized evidence-retrieval/export surface needed by
|
|
90
|
-
the test. No list-all request, visibility change, export-tracking POST, new
|
|
91
|
-
endpoint, or recovery attestation POST is needed. Full retrieved proof responses
|
|
92
|
-
are not dumped: the runner retains only the exact known synthetic CER and selected
|
|
93
|
-
signed evidence. Credentials/account metadata/unknown proof metadata are excluded.
|
|
94
|
-
If the deployed route lacks required fields, STOP; approve a separate trusted
|
|
95
|
-
response-collection method only after review. Never POST again to recover them.
|
|
96
|
-
|
|
97
|
-
### Actual key controls reviewed
|
|
98
|
-
|
|
99
|
-
`src/auth.js:createAuthMiddleware` and `src/db.js:136-173` validate the hash of a
|
|
100
|
-
Bearer credential, require an active key, and establish the key/account context.
|
|
101
|
-
The inspected attestation/owner-proof paths do not enforce endpoint scopes,
|
|
102
|
-
private-only permissions or credential expiry. Do not describe a dedicated test
|
|
103
|
-
key as having those restrictions without additional operator evidence.
|
|
104
|
-
|
|
105
|
-
Although key validation reads `api_keys.monthly_limit`, certification quota
|
|
106
|
-
preflight uses `accounts.monthly_limit` and account-wide usage:
|
|
107
|
-
`src/db.js:223-268`. The default fallback is 100; the Node operator can disable
|
|
108
|
-
quota enforcement, and quota-query errors have fallback behaviour. Therefore a
|
|
109
|
-
per-key limit field or label is NOT proof of an enforced one-request budget.
|
|
110
|
-
|
|
111
|
-
Request an owner-provisioned dedicated key for an otherwise isolated account,
|
|
112
|
-
with an operator-confirmed account budget and no competing usage. Do not mimic
|
|
113
|
-
Node's internal `test-` label/user-ID fixture namespace: the inspected source has
|
|
114
|
-
special usage-log suppression for those internal fixtures. Use normal key
|
|
115
|
-
management and deactivate/revoke the dedicated key after the window using an
|
|
116
|
-
existing owner-controlled mechanism.
|
|
117
|
-
|
|
118
|
-
Default auth is fail-closed on DB failure, but `METERING_REQUIRED=false` can alter
|
|
119
|
-
that; deployment settings remain unverified. No operator settings are changed here.
|
|
120
|
-
|
|
121
|
-
## Local Mac procedure: STOP before live execution
|
|
122
|
-
|
|
123
|
-
Preparation and offline checks may be performed without an API key. Execution
|
|
124
|
-
requires a NEW explicit owner authorization covering A, destination, account,
|
|
125
|
-
request count, quota budget and evidence retrieval.
|
|
126
|
-
|
|
127
|
-
1. Use an owner-controlled Mac/terminal outside this Replit/agent environment.
|
|
128
|
-
No model, agent shell, terminal automation, remote workspace inspector or
|
|
129
|
-
untrusted extension may access the credential, process environment, executable,
|
|
130
|
-
output directory or terminal. If this isolation cannot be established, STOP.
|
|
131
|
-
2. Use Node 24.x and pnpm 10.26.1. In a reviewed standalone checkout or extracted
|
|
132
|
-
private package, install declared development dependencies with:
|
|
133
|
-
|
|
134
|
-
```sh
|
|
135
|
-
pnpm install --frozen-lockfile --ignore-scripts
|
|
136
|
-
pnpm run build
|
|
137
|
-
node tests/acceptance/private-run.mjs --preflight A
|
|
138
|
-
```
|
|
139
|
-
|
|
140
|
-
The acceptance client uses the already-pinned MCP client dev dependency.
|
|
141
|
-
A consumer installation lacking dev dependencies is not enough for this runner.
|
|
142
|
-
No registry publication is involved.
|
|
143
|
-
3. Inspect the generated request and preflight report. Require the expected hash,
|
|
144
|
-
`visibility:"private"`, no identity and no plaintext/openings.
|
|
145
|
-
4. Before authorization, verify the account's remaining budget and ownership via
|
|
146
|
-
existing owner controls. Determine whether this deterministic hash is already
|
|
147
|
-
present: a replay is not proof of a new quota-consuming commit.
|
|
148
|
-
5. Review these hardcoded controls:
|
|
149
|
-
- Actual MCP tool: `nexart_attest_cer`.
|
|
150
|
-
- Only attestation enabled: eight tools including the seven read-only tools.
|
|
151
|
-
- Sealing/disclosure/public capabilities false.
|
|
152
|
-
- POST target fixed by existing implementation:
|
|
153
|
-
`https://node.nexart.io/api/attest`.
|
|
154
|
-
- Exact prepared request; explicit private visibility.
|
|
155
|
-
- Header generated by existing adapter: `X-NexArt-Visibility: private`.
|
|
156
|
-
- No CLI/MCP destination, header, credential or public-visibility override.
|
|
157
|
-
- No `NODE_OPTIONS`/test preload inherited by the launched server.
|
|
158
|
-
- A public request, if separately attempted, fails closed rather than silently
|
|
159
|
-
becoming private.
|
|
160
|
-
6. STOP HERE. Do not run the next command until the owner separately authorizes it:
|
|
161
|
-
|
|
162
|
-
```sh
|
|
163
|
-
node tests/acceptance/private-run.mjs --execute-authorized A
|
|
164
|
-
```
|
|
165
|
-
|
|
166
|
-
7. Only AFTER authorization, the owner manually types:
|
|
167
|
-
|
|
168
|
-
```text
|
|
169
|
-
PRIVATE sha256:ae3f28523d50f990c12d2712e8b9e3d90ea7d686c5514b99b618e2e2e4fc598c
|
|
170
|
-
```
|
|
171
|
-
|
|
172
|
-
The command then prompts for the dedicated key with terminal echo disabled.
|
|
173
|
-
Do not paste it into chat, a source file, a command argument, a shell assignment,
|
|
174
|
-
a recorded terminal session or a retained environment file.
|
|
175
|
-
|
|
176
|
-
The runner intentionally refuses live mode when Replit runtime markers are
|
|
177
|
-
present. This is an accidental-use guard, NOT a security boundary against an
|
|
178
|
-
agent controlling environment/code. Do not bypass it to complete this test.
|
|
179
|
-
|
|
180
|
-
The key exists transiently in the trusted local client and MCP child environment;
|
|
181
|
-
the actual MCP server requires server-controlled credentials. No agent should be
|
|
182
|
-
running with access to those local processes. It is never passed in tool arguments,
|
|
183
|
-
written to files, printed, or retained in evidence. No claim of physical memory
|
|
184
|
-
zeroization or protection from the local OS owner is made.
|
|
185
|
-
|
|
186
|
-
## What the one-shot run does
|
|
187
|
-
|
|
188
|
-
1. Connects to the actual MCP stdio implementation and checks the eight-tool
|
|
189
|
-
configuration.
|
|
190
|
-
2. Exclusively creates `attempt.json` BEFORE the tool invocation. It is a
|
|
191
|
-
permanent potentially-sent marker, even if a crash occurs before transmission.
|
|
192
|
-
3. Invokes `nexart_attest_cer` ONCE with the exact request.
|
|
193
|
-
4. Makes ONE owner-authenticated exact-hash GET to retrieve/reconcile the result.
|
|
194
|
-
5. Checks ATTESTED/private state, exact original CER values, SDK integrity and
|
|
195
|
-
opening-free confidentiality. It tolerates JSON object-key order changes, not
|
|
196
|
-
evidence-value changes or replacement hashes.
|
|
197
|
-
6. Independently verifies the retrieved original receipt using the published
|
|
198
|
-
SDK and a bounded public manifest GET.
|
|
199
|
-
7. Makes ONE anonymous exact-hash public resolver GET. It discards diagnostic/
|
|
200
|
-
evidence bodies and requires 404 for acceptance.
|
|
201
|
-
8. Saves selected signed evidence and a bounded acceptance report in mode 0600,
|
|
202
|
-
excluding the credential and unrelated proof metadata.
|
|
203
|
-
9. Closes the MCP client. There is NO retry loop and NO A-to-B automatic chain.
|
|
204
|
-
|
|
205
|
-
Receipt key identity, Node identity, key lifecycle and signer trust remain separate.
|
|
206
|
-
Pins are required to remain empty for this acceptance; signer trust must remain
|
|
207
|
-
unestablished. A mathematically valid receipt is not a trusted production signer.
|
|
208
|
-
Historical lifecycle uncertainty remains explicitly reported. Envelope signature
|
|
209
|
-
verification remains not_performed; the envelope/signature are recovered for
|
|
210
|
-
owner inspection.
|
|
211
|
-
|
|
212
|
-
`PRIVATE_ACCEPTANCE_PASS` requires:
|
|
213
|
-
|
|
214
|
-
- MCP reports accepted, with requested/confirmed private visibility.
|
|
215
|
-
- Original CER/hash and optional identity match exactly.
|
|
216
|
-
- Retrieved receipt has a valid Ed25519 signature and matching hash/Node identity.
|
|
217
|
-
- Key lifecycle is not known invalid; any uncertainty stays visible in the report.
|
|
218
|
-
- Signer trust remains not_established.
|
|
219
|
-
- Anonymous resolver returns 404.
|
|
220
|
-
|
|
221
|
-
A public 404 is only an observation of that route at that time, not proof no other
|
|
222
|
-
system has a copy. No execution capture or completeness claim is established.
|
|
223
|
-
|
|
224
|
-
If the POST outcome is ambiguous, the same owner GET is used for reconciliation;
|
|
225
|
-
the report does not convert unknown MCP completion into a pass. If anything fails,
|
|
226
|
-
the attempt marker remains and the runner refuses another invocation. DO NOT
|
|
227
|
-
delete the marker/retry simply to obtain a receipt. Additional reconciliation is
|
|
228
|
-
a separately authorized read-only action. A known pre-send failure may consume
|
|
229
|
-
the local marker without consuming Node quota; that safe denial is intentional.
|
|
230
|
-
The marker protects this owner-controlled acceptance directory, not a global Node
|
|
231
|
-
budget. Do not switch output directories, edit/delete markers or copy a passed
|
|
232
|
-
report to bypass sequencing. A same-user agent able to do those things is outside
|
|
233
|
-
the required isolation boundary.
|
|
234
|
-
|
|
235
|
-
## Budget proposal — not authorization
|
|
236
|
-
|
|
237
|
-
For A only:
|
|
238
|
-
|
|
239
|
-
- At most ONE authenticated `/api/attest` POST.
|
|
240
|
-
- At most ONE successful certification quota unit expected for a fresh proof.
|
|
241
|
-
- ZERO automatic POST retries, ZERO C/D submissions, ZERO public approvals.
|
|
242
|
-
- One authenticated exact-hash proof GET.
|
|
243
|
-
- Up to two unauthenticated manifest GETs (existing MCP check + independent check).
|
|
244
|
-
- One anonymous public resolver GET.
|
|
245
|
-
- Maximum five HTTP requests in the normal path, of which two are authenticated.
|
|
246
|
-
|
|
247
|
-
Internal TSA/ingest activity and operator quota accounting are Node-controlled;
|
|
248
|
-
the local count is not a financial guarantee. An account limit and one-shot
|
|
249
|
-
runner complement each other but do not manufacture a per-key hard cap.
|
|
250
|
-
Do not run if even one accepted synthetic unit is outside the owner's budget.
|
|
251
|
-
|
|
252
|
-
After A truly passes, B needs a new explicit authorization and its own one-request
|
|
253
|
-
budget. B's expected hash remains:
|
|
254
|
-
|
|
255
|
-
```text
|
|
256
|
-
sha256:21dea7b7dfffcc7bc496a0eff64338cb22d490df21802137c40c36738202369a
|
|
257
|
-
```
|
|
258
|
-
|
|
259
|
-
Only then:
|
|
260
|
-
|
|
261
|
-
```sh
|
|
262
|
-
node tests/acceptance/private-run.mjs --preflight B
|
|
263
|
-
# Review its synthetic identity, then STOP for B's separate authorization.
|
|
264
|
-
```
|
|
265
|
-
|
|
266
|
-
The runner requires A's passed owner acceptance record before preparing B. This
|
|
267
|
-
is a sequencing check, not tamper resistance against an owner/agent able to edit
|
|
268
|
-
the evidence directory. No B files are prepared in this workspace now.
|
|
269
|
-
|
|
270
|
-
## Focused test-gap closure and validation
|
|
271
|
-
|
|
272
|
-
`tests/approval-boundaries.test.mjs` covers eight actual child processes racing
|
|
273
|
-
one approval, bidirectional invalidation under in-memory destination/profile/
|
|
274
|
-
visibility mutations, and a valid-artifact/correct-piped-confirmation invocation
|
|
275
|
-
in a session with no controlling terminal. Production approval source is unchanged.
|
|
276
|
-
|
|
277
|
-
`tests/private-acceptance.test.mjs` covers exact A preflight, B gating, both real
|
|
278
|
-
MCP protocol revisions with SYNTHETIC Node preload, and a fully mocked owner
|
|
279
|
-
workflow including acceptance, ambiguity, missing owner evidence, public exposure,
|
|
280
|
-
bad receipt signature, secret-free retained evidence and permanent no-retry state.
|
|
281
|
-
All network-capable test dependencies are mocked; no production key or quota is
|
|
282
|
-
used. The mocked owner workflow is not a real macOS/Node acceptance result.
|
|
283
|
-
|
|
284
|
-
To retain a separate release record without overwriting Milestone 3 evidence:
|
|
285
|
-
|
|
286
|
-
```sh
|
|
287
|
-
pnpm run build
|
|
288
|
-
node tests/clean-install.mjs milestone-3.2
|
|
289
|
-
```
|
|
290
|
-
|
|
291
|
-
The package stays private/UNLICENSED. Source/protocol/crypto semantics are unchanged.
|