@interop/was-conformance-suite 0.2.0 → 0.3.1
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/dist/suites/authz-ordering-api.d.ts +9 -0
- package/dist/suites/authz-ordering-api.d.ts.map +1 -0
- package/dist/suites/authz-ordering-api.js +286 -0
- package/dist/suites/authz-ordering-api.js.map +1 -0
- package/dist/suites/blinded-index-api.d.ts +11 -0
- package/dist/suites/blinded-index-api.d.ts.map +1 -0
- package/dist/suites/blinded-index-api.js +468 -0
- package/dist/suites/blinded-index-api.js.map +1 -0
- package/dist/suites/changes-query-api.d.ts.map +1 -1
- package/dist/suites/changes-query-api.js +61 -0
- package/dist/suites/changes-query-api.js.map +1 -1
- package/dist/suites/chunks-api.d.ts +27 -0
- package/dist/suites/chunks-api.d.ts.map +1 -0
- package/dist/suites/chunks-api.js +613 -0
- package/dist/suites/chunks-api.js.map +1 -0
- package/dist/suites/client-backends.d.ts.map +1 -1
- package/dist/suites/client-backends.js +23 -0
- package/dist/suites/client-backends.js.map +1 -1
- package/dist/suites/client-delegation.d.ts.map +1 -1
- package/dist/suites/client-delegation.js +12 -0
- package/dist/suites/client-delegation.js.map +1 -1
- package/dist/suites/client-export-import.d.ts.map +1 -1
- package/dist/suites/client-export-import.js +1 -0
- package/dist/suites/client-export-import.js.map +1 -1
- package/dist/suites/client-resources.d.ts.map +1 -1
- package/dist/suites/client-resources.js +30 -0
- package/dist/suites/client-resources.js.map +1 -1
- package/dist/suites/client-spaces.d.ts.map +1 -1
- package/dist/suites/client-spaces.js +27 -0
- package/dist/suites/client-spaces.js.map +1 -1
- package/dist/suites/collection-api.d.ts.map +1 -1
- package/dist/suites/collection-api.js +151 -0
- package/dist/suites/collection-api.js.map +1 -1
- package/dist/suites/conditional-requests-api.d.ts +11 -0
- package/dist/suites/conditional-requests-api.d.ts.map +1 -0
- package/dist/suites/conditional-requests-api.js +444 -0
- package/dist/suites/conditional-requests-api.js.map +1 -0
- package/dist/suites/digest-api.d.ts +7 -0
- package/dist/suites/digest-api.d.ts.map +1 -0
- package/dist/suites/digest-api.js +157 -0
- package/dist/suites/digest-api.js.map +1 -0
- package/dist/suites/encryption-marker-api.d.ts.map +1 -1
- package/dist/suites/encryption-marker-api.js +132 -8
- package/dist/suites/encryption-marker-api.js.map +1 -1
- package/dist/suites/index.d.ts +8 -1
- package/dist/suites/index.d.ts.map +1 -1
- package/dist/suites/index.js +16 -2
- package/dist/suites/index.js.map +1 -1
- package/dist/suites/invocation-target-api.d.ts +12 -0
- package/dist/suites/invocation-target-api.d.ts.map +1 -0
- package/dist/suites/invocation-target-api.js +252 -0
- package/dist/suites/invocation-target-api.js.map +1 -0
- package/dist/suites/policy-api.d.ts.map +1 -1
- package/dist/suites/policy-api.js +23 -0
- package/dist/suites/policy-api.js.map +1 -1
- package/dist/suites/resource-api.d.ts.map +1 -1
- package/dist/suites/resource-api.js +269 -0
- package/dist/suites/resource-api.js.map +1 -1
- package/dist/suites/server.d.ts.map +1 -1
- package/dist/suites/server.js +1 -0
- package/dist/suites/server.js.map +1 -1
- package/dist/suites/spaces-api.d.ts.map +1 -1
- package/dist/suites/spaces-api.js +579 -1
- package/dist/suites/spaces-api.js.map +1 -1
- package/dist/suites/write-validation-api.d.ts +7 -0
- package/dist/suites/write-validation-api.d.ts.map +1 -0
- package/dist/suites/write-validation-api.js +186 -0
- package/dist/suites/write-validation-api.js.map +1 -0
- package/package.json +5 -3
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"authz-ordering-api.d.ts","sourceRoot":"","sources":["../../src/suites/authz-ordering-api.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAA;AAEhD,UAAU,KAAK;IACb,KAAK,EAAE,GAAG,CAAA;IACV,GAAG,EAAE,GAAG,CAAA;IACR,UAAU,EAAE,MAAM,CAAA;CACnB;AAmBD,eAAO,MAAM,gBAAgB,EAAE,KAAK,CAAC,KAAK,CAkRzC,CAAA"}
|
|
@@ -0,0 +1,286 @@
|
|
|
1
|
+
/*!
|
|
2
|
+
* Copyright (c) 2026 Interop Alliance. All rights reserved.
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* WAS conformance tests -- authorization-ordering negatives.
|
|
6
|
+
*
|
|
7
|
+
* The spec's "maximum privacy" rule (spec "Error Handling") requires servers
|
|
8
|
+
* to verify a caller's authorization *before* any check whose distinct error
|
|
9
|
+
* would reveal that a target exists: conflict detection (409), encrypted-write
|
|
10
|
+
* envelope validation (422), cursor / query-body validation (400/501), and
|
|
11
|
+
* quota reads (403). A server that runs those checks first leaks existence
|
|
12
|
+
* through the differing status code. Every test here invokes as Bob -- a
|
|
13
|
+
* well-formed, signed request that simply lacks privilege over Alice's Space
|
|
14
|
+
* -- and expects the privacy-merged `not-found` (404) mask.
|
|
15
|
+
*/
|
|
16
|
+
import assert from '../harness/assert.js';
|
|
17
|
+
/**
|
|
18
|
+
* Asserts a rejected request carries the privacy-merged `not-found` mask:
|
|
19
|
+
* status 404, `application/problem+json`, and the single merged `type` (the
|
|
20
|
+
* registry forbids splitting `not-found` into distinguishable kinds).
|
|
21
|
+
*
|
|
22
|
+
* @param expectedError {any} the error thrown by `ZcapClient.request()`
|
|
23
|
+
*/
|
|
24
|
+
function assertNotFoundMask(expectedError) {
|
|
25
|
+
assert.ok(expectedError, 'expected the under-authorized request to fail');
|
|
26
|
+
assert.equal(expectedError.response.status, 404);
|
|
27
|
+
assert.match(expectedError.response.headers.get('content-type'), /application\/problem\+json/);
|
|
28
|
+
assert.equal(expectedError.data.type, 'https://wallet.storage/spec#not-found');
|
|
29
|
+
}
|
|
30
|
+
export const authzOrderingApi = {
|
|
31
|
+
id: 'authz-ordering-api',
|
|
32
|
+
name: 'Authorization ordering (no-leak negatives)',
|
|
33
|
+
specRefs: ['https://wallet.storage/spec#error-handling'],
|
|
34
|
+
setup: async (ctx) => {
|
|
35
|
+
const alice = { ...ctx.actors.alice };
|
|
36
|
+
const bob = { ...ctx.actors.bob };
|
|
37
|
+
alice.space1 = { id: ctx.generateId() };
|
|
38
|
+
const resourceId = ctx.generateId();
|
|
39
|
+
await ctx.createSpace({
|
|
40
|
+
spaceDescription: {
|
|
41
|
+
id: alice.space1.id,
|
|
42
|
+
name: "Alice's Ordering Space",
|
|
43
|
+
controller: alice.did
|
|
44
|
+
},
|
|
45
|
+
rootClient: alice.rootClient
|
|
46
|
+
});
|
|
47
|
+
// A plain Collection holding one Resource (the existing ids Bob probes for)
|
|
48
|
+
await alice.rootClient.request({
|
|
49
|
+
url: new URL(`/space/${alice.space1.id}/`, ctx.serverUrl).toString(),
|
|
50
|
+
method: 'POST',
|
|
51
|
+
action: 'POST',
|
|
52
|
+
json: { id: 'credentials', name: 'Verifiable Credentials' }
|
|
53
|
+
});
|
|
54
|
+
await alice.rootClient.request({
|
|
55
|
+
url: new URL(`/space/${alice.space1.id}/credentials/${resourceId}`, ctx.serverUrl).toString(),
|
|
56
|
+
method: 'PUT',
|
|
57
|
+
action: 'PUT',
|
|
58
|
+
json: { id: resourceId, name: 'Existing Resource' }
|
|
59
|
+
});
|
|
60
|
+
// An encryption-marked Collection (for the envelope-validation ordering test)
|
|
61
|
+
await alice.rootClient.request({
|
|
62
|
+
url: new URL(`/space/${alice.space1.id}/`, ctx.serverUrl).toString(),
|
|
63
|
+
method: 'POST',
|
|
64
|
+
action: 'POST',
|
|
65
|
+
json: { id: 'vault', name: 'Vault', encryption: { scheme: 'edv' } }
|
|
66
|
+
});
|
|
67
|
+
return { alice, bob, resourceId };
|
|
68
|
+
},
|
|
69
|
+
teardown: async (ctx, state) => {
|
|
70
|
+
const { alice } = state;
|
|
71
|
+
try {
|
|
72
|
+
await alice.rootClient.request({
|
|
73
|
+
url: new URL(`/space/${alice.space1.id}`, ctx.serverUrl).toString(),
|
|
74
|
+
method: 'DELETE'
|
|
75
|
+
});
|
|
76
|
+
}
|
|
77
|
+
catch {
|
|
78
|
+
/* best-effort cleanup */
|
|
79
|
+
}
|
|
80
|
+
},
|
|
81
|
+
tests: [
|
|
82
|
+
{
|
|
83
|
+
id: 'ordering.collection-post-conflict-404',
|
|
84
|
+
name: "[root] Bob's POST of an existing Collection id yields 404, not id-conflict (409)",
|
|
85
|
+
specRefs: [
|
|
86
|
+
'https://wallet.storage/spec#id-conflict',
|
|
87
|
+
'https://wallet.storage/spec#not-found'
|
|
88
|
+
],
|
|
89
|
+
run: async (ctx, state) => {
|
|
90
|
+
const { serverUrl } = ctx;
|
|
91
|
+
const { alice, bob } = state;
|
|
92
|
+
// Authorization MUST run before conflict detection: a 409 here would
|
|
93
|
+
// let Bob probe Alice's Space for existing Collection ids.
|
|
94
|
+
let expectedError;
|
|
95
|
+
try {
|
|
96
|
+
await bob.rootClient.request({
|
|
97
|
+
url: new URL(`/space/${alice.space1.id}/`, serverUrl).toString(),
|
|
98
|
+
method: 'POST',
|
|
99
|
+
action: 'POST',
|
|
100
|
+
json: { id: 'credentials', name: 'Probe Collection' }
|
|
101
|
+
});
|
|
102
|
+
}
|
|
103
|
+
catch (err) {
|
|
104
|
+
expectedError = err;
|
|
105
|
+
}
|
|
106
|
+
assertNotFoundMask(expectedError);
|
|
107
|
+
}
|
|
108
|
+
},
|
|
109
|
+
{
|
|
110
|
+
id: 'ordering.resource-post-conflict-404',
|
|
111
|
+
name: "[root] Bob's POST of an existing Resource id yields 404, not id-conflict (409)",
|
|
112
|
+
specRefs: [
|
|
113
|
+
'https://wallet.storage/spec#id-conflict',
|
|
114
|
+
'https://wallet.storage/spec#not-found'
|
|
115
|
+
],
|
|
116
|
+
run: async (ctx, state) => {
|
|
117
|
+
const { serverUrl } = ctx;
|
|
118
|
+
const { alice, bob, resourceId } = state;
|
|
119
|
+
let expectedError;
|
|
120
|
+
try {
|
|
121
|
+
await bob.rootClient.request({
|
|
122
|
+
url: new URL(`/space/${alice.space1.id}/credentials/`, serverUrl).toString(),
|
|
123
|
+
method: 'POST',
|
|
124
|
+
action: 'POST',
|
|
125
|
+
json: { id: resourceId, name: 'Probe Resource' }
|
|
126
|
+
});
|
|
127
|
+
}
|
|
128
|
+
catch (err) {
|
|
129
|
+
expectedError = err;
|
|
130
|
+
}
|
|
131
|
+
assertNotFoundMask(expectedError);
|
|
132
|
+
}
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
id: 'ordering.encrypted-write-404',
|
|
136
|
+
name: "[root] Bob's plaintext write to an encrypted Collection yields 404, not scheme-mismatch (422)",
|
|
137
|
+
specRefs: [
|
|
138
|
+
'https://wallet.storage/spec#encryption-scheme-mismatch',
|
|
139
|
+
'https://wallet.storage/spec#not-found'
|
|
140
|
+
],
|
|
141
|
+
run: async (ctx, state) => {
|
|
142
|
+
const { serverUrl } = ctx;
|
|
143
|
+
const { alice, bob } = state;
|
|
144
|
+
// Authorization MUST run before envelope validation: a 422 here would
|
|
145
|
+
// reveal both that `vault` exists and that it is encryption-marked.
|
|
146
|
+
let expectedError;
|
|
147
|
+
try {
|
|
148
|
+
await bob.rootClient.request({
|
|
149
|
+
url: new URL(`/space/${alice.space1.id}/vault/plaintext-doc`, serverUrl).toString(),
|
|
150
|
+
method: 'PUT',
|
|
151
|
+
action: 'PUT',
|
|
152
|
+
json: { hello: 'world' }
|
|
153
|
+
});
|
|
154
|
+
}
|
|
155
|
+
catch (err) {
|
|
156
|
+
expectedError = err;
|
|
157
|
+
}
|
|
158
|
+
assertNotFoundMask(expectedError);
|
|
159
|
+
}
|
|
160
|
+
},
|
|
161
|
+
{
|
|
162
|
+
id: 'ordering.list-bad-cursor-404',
|
|
163
|
+
name: "[root] Bob's List Collection with a malformed cursor yields 404, not invalid-cursor (400)",
|
|
164
|
+
specRefs: [
|
|
165
|
+
'https://wallet.storage/spec#invalid-cursor',
|
|
166
|
+
'https://wallet.storage/spec#not-found'
|
|
167
|
+
],
|
|
168
|
+
run: async (ctx, state) => {
|
|
169
|
+
const { serverUrl } = ctx;
|
|
170
|
+
const { alice, bob } = state;
|
|
171
|
+
// Authorization MUST run before cursor validation: pagination params
|
|
172
|
+
// describe the request, but validating them first would answer before
|
|
173
|
+
// the 404 mask is decided.
|
|
174
|
+
let expectedError;
|
|
175
|
+
try {
|
|
176
|
+
await bob.rootClient.request({
|
|
177
|
+
url: new URL(`/space/${alice.space1.id}/credentials/?cursor=not-valid-%%%`, serverUrl).toString(),
|
|
178
|
+
method: 'GET'
|
|
179
|
+
});
|
|
180
|
+
}
|
|
181
|
+
catch (err) {
|
|
182
|
+
expectedError = err;
|
|
183
|
+
}
|
|
184
|
+
assertNotFoundMask(expectedError);
|
|
185
|
+
}
|
|
186
|
+
},
|
|
187
|
+
{
|
|
188
|
+
id: 'ordering.query-bad-body-404',
|
|
189
|
+
name: "[root] Bob's query POST with an invalid body yields 404, not 400/501",
|
|
190
|
+
specRefs: ['https://wallet.storage/spec#not-found'],
|
|
191
|
+
run: async (ctx, state) => {
|
|
192
|
+
const { serverUrl } = ctx;
|
|
193
|
+
const { alice, bob } = state;
|
|
194
|
+
// An authorized caller sending this body gets a precise query-body
|
|
195
|
+
// error (an unknown profile is 501); Bob must get the 404 mask first.
|
|
196
|
+
let expectedError;
|
|
197
|
+
try {
|
|
198
|
+
await bob.rootClient.request({
|
|
199
|
+
url: new URL(`/space/${alice.space1.id}/credentials/query`, serverUrl).toString(),
|
|
200
|
+
method: 'POST',
|
|
201
|
+
action: 'POST',
|
|
202
|
+
json: { profile: 'no-such-profile' }
|
|
203
|
+
});
|
|
204
|
+
}
|
|
205
|
+
catch (err) {
|
|
206
|
+
expectedError = err;
|
|
207
|
+
}
|
|
208
|
+
assertNotFoundMask(expectedError);
|
|
209
|
+
}
|
|
210
|
+
},
|
|
211
|
+
{
|
|
212
|
+
id: 'ordering.space-quotas-read-404',
|
|
213
|
+
name: "[root] Bob's read of Alice's Space quota report yields 404, never 403",
|
|
214
|
+
specRefs: [
|
|
215
|
+
'https://wallet.storage/spec#quotas',
|
|
216
|
+
'https://wallet.storage/spec#not-found'
|
|
217
|
+
],
|
|
218
|
+
run: async (ctx, state) => {
|
|
219
|
+
const { serverUrl } = ctx;
|
|
220
|
+
const { alice, bob } = state;
|
|
221
|
+
let expectedError;
|
|
222
|
+
try {
|
|
223
|
+
await bob.rootClient.request({
|
|
224
|
+
url: new URL(`/space/${alice.space1.id}/quotas`, serverUrl).toString(),
|
|
225
|
+
method: 'GET'
|
|
226
|
+
});
|
|
227
|
+
}
|
|
228
|
+
catch (err) {
|
|
229
|
+
expectedError = err;
|
|
230
|
+
}
|
|
231
|
+
assertNotFoundMask(expectedError);
|
|
232
|
+
}
|
|
233
|
+
},
|
|
234
|
+
{
|
|
235
|
+
id: 'ordering.collection-quota-read-404',
|
|
236
|
+
name: "[root] Bob's read of Alice's Collection quota yields 404, never 403 or 501",
|
|
237
|
+
specRefs: [
|
|
238
|
+
'https://wallet.storage/spec#quotas',
|
|
239
|
+
'https://wallet.storage/spec#not-found'
|
|
240
|
+
],
|
|
241
|
+
run: async (ctx, state) => {
|
|
242
|
+
const { serverUrl } = ctx;
|
|
243
|
+
const { alice, bob } = state;
|
|
244
|
+
// Per-Collection accounting is optional (501 when unsupported), but
|
|
245
|
+
// that answer is reserved for authorized callers -- Bob gets the mask.
|
|
246
|
+
let expectedError;
|
|
247
|
+
try {
|
|
248
|
+
await bob.rootClient.request({
|
|
249
|
+
url: new URL(`/space/${alice.space1.id}/credentials/quota`, serverUrl).toString(),
|
|
250
|
+
method: 'GET'
|
|
251
|
+
});
|
|
252
|
+
}
|
|
253
|
+
catch (err) {
|
|
254
|
+
expectedError = err;
|
|
255
|
+
}
|
|
256
|
+
assertNotFoundMask(expectedError);
|
|
257
|
+
}
|
|
258
|
+
},
|
|
259
|
+
{
|
|
260
|
+
id: 'ordering.resource-delete-404',
|
|
261
|
+
name: "[root] Bob's DELETE of Alice's Resource yields 404 and does not delete it",
|
|
262
|
+
specRefs: ['https://wallet.storage/spec#not-found'],
|
|
263
|
+
run: async (ctx, state) => {
|
|
264
|
+
const { serverUrl } = ctx;
|
|
265
|
+
const { alice, bob, resourceId } = state;
|
|
266
|
+
const resourceUrl = new URL(`/space/${alice.space1.id}/credentials/${resourceId}`, serverUrl).toString();
|
|
267
|
+
let expectedError;
|
|
268
|
+
try {
|
|
269
|
+
await bob.rootClient.request({ url: resourceUrl, method: 'DELETE' });
|
|
270
|
+
}
|
|
271
|
+
catch (err) {
|
|
272
|
+
expectedError = err;
|
|
273
|
+
}
|
|
274
|
+
assertNotFoundMask(expectedError);
|
|
275
|
+
// The operation must not have been performed: Alice still sees it.
|
|
276
|
+
const checkResponse = await alice.rootClient.request({
|
|
277
|
+
url: resourceUrl,
|
|
278
|
+
method: 'GET'
|
|
279
|
+
});
|
|
280
|
+
assert.equal(checkResponse.status, 200);
|
|
281
|
+
assert.equal(checkResponse.data.name, 'Existing Resource');
|
|
282
|
+
}
|
|
283
|
+
}
|
|
284
|
+
]
|
|
285
|
+
};
|
|
286
|
+
//# sourceMappingURL=authz-ordering-api.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"authz-ordering-api.js","sourceRoot":"","sources":["../../src/suites/authz-ordering-api.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;;;;;;;;;;GAWG;AACH,OAAO,MAAM,MAAM,sBAAsB,CAAA;AASzC;;;;;;GAMG;AACH,SAAS,kBAAkB,CAAC,aAAkB;IAC5C,MAAM,CAAC,EAAE,CAAC,aAAa,EAAE,+CAA+C,CAAC,CAAA;IACzE,MAAM,CAAC,KAAK,CAAC,aAAa,CAAC,QAAQ,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAChD,MAAM,CAAC,KAAK,CACV,aAAa,CAAC,QAAQ,CAAC,OAAO,CAAC,GAAG,CAAC,cAAc,CAAC,EAClD,4BAA4B,CAC7B,CAAA;IACD,MAAM,CAAC,KAAK,CAAC,aAAa,CAAC,IAAI,CAAC,IAAI,EAAE,uCAAuC,CAAC,CAAA;AAChF,CAAC;AAED,MAAM,CAAC,MAAM,gBAAgB,G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|
|
2
|
+
interface State {
|
|
3
|
+
alice: any;
|
|
4
|
+
bob: any;
|
|
5
|
+
advertised: boolean;
|
|
6
|
+
queryUrl: (collectionId: string) => string;
|
|
7
|
+
resourceUrl: (collectionId: string, resourceId: string) => string;
|
|
8
|
+
}
|
|
9
|
+
export declare const blindedIndexApi: Suite<State>;
|
|
10
|
+
export {};
|
|
11
|
+
//# sourceMappingURL=blinded-index-api.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"blinded-index-api.d.ts","sourceRoot":"","sources":["../../src/suites/blinded-index-api.ts"],"names":[],"mappings":"AAuBA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,qBAAqB,CAAA;AAKhD,UAAU,KAAK;IACb,KAAK,EAAE,GAAG,CAAA;IACV,GAAG,EAAE,GAAG,CAAA;IACR,UAAU,EAAE,OAAO,CAAA;IACnB,QAAQ,EAAE,CAAC,YAAY,EAAE,MAAM,KAAK,MAAM,CAAA;IAC1C,WAAW,EAAE,CAAC,YAAY,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,KAAK,MAAM,CAAA;CAClE;AAuCD,eAAO,MAAM,eAAe,EAAE,KAAK,CAAC,KAAK,CAgexC,CAAA"}
|