@openbrf/plugin-sdk 1.0.0 → 1.4.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/README.md +95 -0
- package/dist/abort-signal.d.ts +23 -0
- package/dist/abort-signal.d.ts.map +1 -0
- package/dist/abort-signal.js +2 -0
- package/dist/abort-signal.js.map +1 -0
- package/dist/action-refusal.d.ts +101 -0
- package/dist/action-refusal.d.ts.map +1 -0
- package/dist/action-refusal.js +96 -0
- package/dist/action-refusal.js.map +1 -0
- package/dist/action-schema.d.ts.map +1 -1
- package/dist/action-schema.js +4 -1
- package/dist/action-schema.js.map +1 -1
- package/dist/actions.d.ts +94 -6
- package/dist/actions.d.ts.map +1 -1
- package/dist/actions.js.map +1 -1
- package/dist/blocks.d.ts +310 -0
- package/dist/blocks.d.ts.map +1 -0
- package/dist/blocks.js +185 -0
- package/dist/blocks.js.map +1 -0
- package/dist/catalog.d.ts +1092 -41
- package/dist/catalog.d.ts.map +1 -1
- package/dist/catalog.js +472 -15
- package/dist/catalog.js.map +1 -1
- package/dist/entitlements.d.ts +117 -0
- package/dist/entitlements.d.ts.map +1 -0
- package/dist/entitlements.js +62 -0
- package/dist/entitlements.js.map +1 -0
- package/dist/extensions.d.ts +183 -0
- package/dist/extensions.d.ts.map +1 -0
- package/dist/extensions.js +67 -0
- package/dist/extensions.js.map +1 -0
- package/dist/finances.d.ts +294 -0
- package/dist/finances.d.ts.map +1 -0
- package/dist/finances.js +56 -0
- package/dist/finances.js.map +1 -0
- package/dist/findings.d.ts +92 -1
- package/dist/findings.d.ts.map +1 -1
- package/dist/findings.js +91 -0
- package/dist/findings.js.map +1 -1
- package/dist/host.d.ts +729 -4
- package/dist/host.d.ts.map +1 -1
- package/dist/host.js +54 -0
- package/dist/host.js.map +1 -1
- package/dist/imports.d.ts +104 -0
- package/dist/imports.d.ts.map +1 -0
- package/dist/imports.js +70 -0
- package/dist/imports.js.map +1 -0
- package/dist/index.d.ts +17 -7
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +15 -6
- package/dist/index.js.map +1 -1
- package/dist/localized-text.d.ts +18 -0
- package/dist/localized-text.d.ts.map +1 -0
- package/dist/localized-text.js +17 -0
- package/dist/localized-text.js.map +1 -0
- package/dist/manifest.d.ts +859 -0
- package/dist/manifest.d.ts.map +1 -1
- package/dist/manifest.js +957 -12
- package/dist/manifest.js.map +1 -1
- package/dist/package-check.d.ts.map +1 -1
- package/dist/package-check.js +9 -1
- package/dist/package-check.js.map +1 -1
- package/dist/permissions.d.ts +170 -11
- package/dist/permissions.d.ts.map +1 -1
- package/dist/permissions.js +210 -2
- package/dist/permissions.js.map +1 -1
- package/dist/recipients.d.ts +139 -0
- package/dist/recipients.d.ts.map +1 -0
- package/dist/recipients.js +223 -0
- package/dist/recipients.js.map +1 -0
- package/dist/records.d.ts +130 -0
- package/dist/records.d.ts.map +1 -0
- package/dist/records.js +85 -0
- package/dist/records.js.map +1 -0
- package/dist/require-capability.d.ts +37 -0
- package/dist/require-capability.d.ts.map +1 -0
- package/dist/require-capability.js +88 -0
- package/dist/require-capability.js.map +1 -0
- package/dist/settings-schema.d.ts +35 -0
- package/dist/settings-schema.d.ts.map +1 -1
- package/dist/settings-schema.js +55 -2
- package/dist/settings-schema.js.map +1 -1
- package/package.json +4 -4
- package/src/abort-signal.ts +22 -0
- package/src/action-refusal.ts +178 -0
- package/src/action-schema.ts +4 -1
- package/src/actions.ts +103 -6
- package/src/blocks.ts +289 -0
- package/src/catalog.ts +630 -72
- package/src/entitlements.ts +150 -0
- package/src/extensions.ts +212 -0
- package/src/finances.ts +317 -0
- package/src/findings.ts +94 -0
- package/src/host.ts +768 -4
- package/src/imports.ts +135 -0
- package/src/index.ts +209 -0
- package/src/localized-text.ts +19 -0
- package/src/manifest.ts +1231 -12
- package/src/package-check.ts +15 -0
- package/src/permissions.ts +223 -3
- package/src/recipients.ts +294 -0
- package/src/records.ts +172 -0
- package/src/require-capability.ts +106 -0
- package/src/settings-schema.ts +64 -2
package/dist/catalog.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"catalog.d.ts","sourceRoot":"","sources":["../src/catalog.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"catalog.d.ts","sourceRoot":"","sources":["../src/catalog.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,KAAK,EAAE,mBAAmB,EAAuB,MAAM,eAAe,CAAC;AAiF9E,uDAAuD;AACvD,eAAO,MAAM,qBAAqB;;;;kBAyBhC,CAAC;AAEH,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAEpE,YAAY,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAEzD;;;;;;;GAOG;AACH,eAAO,MAAM,2BAA2B;;;;;;;;;;;;;;;;;;;;;;;;;;;kBAK7B,CAAC;AAEZ,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,2BAA2B,CAAC,CAAC;AAmBhF,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBAuIjC,CAAC;AAEL;;;;;;;;;GASG;AACH,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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,WAAW,EAAE,SAAS,iBAAiB,EAAE,CAAC;CAC3C,CAAC;AAEN;;;;;;;;;;GAUG;AACH,wBAAgB,iBAAiB,CAAC,KAAK,EAAE,OAAO,GAAG,kBAAkB,CAcpE"}
|
package/dist/catalog.js
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
import { IntegrityError, parseSha512 } from "./integrity.js";
|
|
3
|
-
import {
|
|
3
|
+
import { localizedTextSchema } from "./localized-text.js";
|
|
4
|
+
import { declaredActionsSchema, missingProcessingProblem, undeclaredPersonalDataProblem, declaredExtensionPointsSchema, declaredExtensionsSchema, extensionGroupRefusals, extensionHostPersonalDataRefused, extensionPermissionsRefused, extensionPointRefusal, extensionRuleIssues, pluginExtensionPointSchema, pluginExtensionSchema, declaredDeviceRoutesSchema, deviceRouteRuleIssues, pluginActionSchema, pluginDeviceRouteSchema, pluginIdSchema, pluginManifestSchema, pluginProcessingSchema, proposeImportPersonalDataIssues, } from "./manifest.js";
|
|
4
5
|
import { PLUGIN_PERMISSIONS, PLUGIN_PERSONAL_DATA_CATEGORIES, } from "./permissions.js";
|
|
6
|
+
import { declaredRecipientsSchema, pluginRecipientSchema, recipientCategoryIssues, } from "./recipients.js";
|
|
5
7
|
/**
|
|
6
8
|
* The catalog index.
|
|
7
9
|
*
|
|
@@ -26,6 +28,12 @@ import { PLUGIN_PERMISSIONS, PLUGIN_PERSONAL_DATA_CATEGORIES, } from "./permissi
|
|
|
26
28
|
* any check of the manifest saw it. The index carries its version for exactly
|
|
27
29
|
* this, so a new field is a new index version rather than a key an older
|
|
28
30
|
* instance ignores.
|
|
31
|
+
*
|
|
32
|
+
* An instance reads both versions there are. Version 2 adds the device routes
|
|
33
|
+
* of ADR 0031 and the processing declaration of ADR 0035 to a plugin entry, and
|
|
34
|
+
* the other fields of ADR 0030 join them there as they are built; version 1 is
|
|
35
|
+
* the index as it stood before, which a catalog keeps serving to instances that
|
|
36
|
+
* read nothing newer.
|
|
29
37
|
*/
|
|
30
38
|
/** Whether `declared` is a digest `parseSha512` can read. */
|
|
31
39
|
function isReadableSha512(declared) {
|
|
@@ -66,11 +74,20 @@ export const catalogArtifactSchema = z.strictObject({
|
|
|
66
74
|
}),
|
|
67
75
|
bytes: z.int().min(1).optional(),
|
|
68
76
|
});
|
|
69
|
-
/**
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
77
|
+
/**
|
|
78
|
+
* An extension point as the index lists it: the manifest's fields, and the
|
|
79
|
+
* curator's title and description in both languages.
|
|
80
|
+
*
|
|
81
|
+
* The text is the curator's rather than the plugin's own, as an entry's `name`
|
|
82
|
+
* is, because an addon's consent screen has to name the point before the host
|
|
83
|
+
* plugin's locale files exist on the instance (ADR 0030).
|
|
84
|
+
*/
|
|
85
|
+
export const catalogExtensionPointSchema = pluginExtensionPointSchema
|
|
86
|
+
.extend({
|
|
87
|
+
title: localizedTextSchema,
|
|
88
|
+
description: localizedTextSchema,
|
|
89
|
+
})
|
|
90
|
+
.strict();
|
|
74
91
|
/** Strict, and `.extend()` keeps it so for both kinds of entry. */
|
|
75
92
|
const baseEntrySchema = z.strictObject({
|
|
76
93
|
/**
|
|
@@ -87,7 +104,8 @@ const baseEntrySchema = z.strictObject({
|
|
|
87
104
|
/** Set on an entry that is still listed but should not be installed anew. */
|
|
88
105
|
deprecated: z.boolean().default(false),
|
|
89
106
|
});
|
|
90
|
-
export const catalogPluginEntrySchema = baseEntrySchema
|
|
107
|
+
export const catalogPluginEntrySchema = baseEntrySchema
|
|
108
|
+
.extend({
|
|
91
109
|
type: z.literal("plugin"),
|
|
92
110
|
/**
|
|
93
111
|
* The npm package name the tarball unpacks as. Needed because the installer
|
|
@@ -132,6 +150,99 @@ export const catalogPluginEntrySchema = baseEntrySchema.extend({
|
|
|
132
150
|
* definition of what it may contain is the point of that schema.
|
|
133
151
|
*/
|
|
134
152
|
oauthProtectedResource: pluginManifestSchema.shape.oauthProtectedResource,
|
|
153
|
+
/**
|
|
154
|
+
* The extension points the plugin offers, repeated from the manifest with
|
|
155
|
+
* the curator's text, so the host plugin's consent screen can say what its
|
|
156
|
+
* points accept before anything is downloaded (ADR 0030).
|
|
157
|
+
*
|
|
158
|
+
* In version 2 of the index only; see `catalogSchema`. Left without a
|
|
159
|
+
* default, so that a version 1 index carrying the key, even empty, can be
|
|
160
|
+
* told from one that does not.
|
|
161
|
+
*/
|
|
162
|
+
extensionPoints: declaredExtensionPointsSchema(catalogExtensionPointSchema).optional(),
|
|
163
|
+
/**
|
|
164
|
+
* The extension points of other plugins it extends, repeated on the same
|
|
165
|
+
* terms, so an addon's consent screen can say what it extends and what it
|
|
166
|
+
* hands over. Version 2 only.
|
|
167
|
+
*/
|
|
168
|
+
extends: declaredExtensionsSchema(pluginExtensionSchema.strict()).optional(),
|
|
169
|
+
/**
|
|
170
|
+
* Where the plugin connects to, repeated on the same terms as the
|
|
171
|
+
* declaration above it (ADR 0037).
|
|
172
|
+
*
|
|
173
|
+
* A field version 1 of the index does not define, so only an index of
|
|
174
|
+
* version 2 may carry it, and an index of version 1 that does is refused.
|
|
175
|
+
* Absent rather than defaulted, so that rule can tell an entry that left it
|
|
176
|
+
* out from one that declared none; a reader takes absent as none.
|
|
177
|
+
*/
|
|
178
|
+
recipients: declaredRecipientsSchema(pluginRecipientSchema.strict()).optional(),
|
|
179
|
+
/**
|
|
180
|
+
* The routes a device reaches with a device token, repeated on the same
|
|
181
|
+
* terms (ADR 0031).
|
|
182
|
+
*
|
|
183
|
+
* The consent screen names them - "can be reached by devices holding a token
|
|
184
|
+
* the board issues" - before anything is downloaded. In version 2 of the
|
|
185
|
+
* index only; see `catalogSchema`. Left without a default, so that a version 1
|
|
186
|
+
* index carrying the key, even empty, can be told from one that does not.
|
|
187
|
+
*/
|
|
188
|
+
deviceRoutes: declaredDeviceRoutesSchema(pluginDeviceRouteSchema.strict()).optional(),
|
|
189
|
+
/**
|
|
190
|
+
* That the plugin is an AI package, repeated on the same terms.
|
|
191
|
+
*
|
|
192
|
+
* It decides what the plugin's dispatch reaches and how the audit log names
|
|
193
|
+
* its writes, so the board reads it on the consent screen, and the install
|
|
194
|
+
* echo compares it, before anything is downloaded.
|
|
195
|
+
*
|
|
196
|
+
* Added within version 1 of the index rather than as a new version, because
|
|
197
|
+
* absent means the same as false: an index that lists no AI package need not
|
|
198
|
+
* carry the field and stays one an older instance reads. One that lists an
|
|
199
|
+
* AI package is refused whole by an older instance, which is the rule above
|
|
200
|
+
* doing its work - that instance would otherwise offer the plugin for
|
|
201
|
+
* consent without saying what it is, and dispatch it as a plain plugin.
|
|
202
|
+
*/
|
|
203
|
+
ai: pluginManifestSchema.shape.ai,
|
|
204
|
+
/**
|
|
205
|
+
* The licence a paid plugin reads, repeated on the same terms (ADR 0042).
|
|
206
|
+
*
|
|
207
|
+
* Above all its `audiences`: the services the plugin may present the
|
|
208
|
+
* association's licence to are a grant the board consents to, as it does
|
|
209
|
+
* `permissions`, so the consent screen states them and the install echo
|
|
210
|
+
* compares them before anything is downloaded. The manifest's own strict
|
|
211
|
+
* schema, so a misspelled field is refused here as it is there.
|
|
212
|
+
*
|
|
213
|
+
* Added within version 1 of the index on the `ai` field's terms: absent
|
|
214
|
+
* means the plugin reads no licence, and an index that lists a licensed
|
|
215
|
+
* plugin is refused whole by an instance from before the field.
|
|
216
|
+
*/
|
|
217
|
+
licence: pluginManifestSchema.shape.licence,
|
|
218
|
+
/**
|
|
219
|
+
* The day the release was published, which the update screen compares with
|
|
220
|
+
* the `updatesUntil` of the licence the instance holds. Required with
|
|
221
|
+
* `licence`, as in the manifest.
|
|
222
|
+
*/
|
|
223
|
+
released: pluginManifestSchema.shape.released,
|
|
224
|
+
})
|
|
225
|
+
.superRefine((entry, ctx) => {
|
|
226
|
+
if (entry.licence !== undefined && entry.released === undefined) {
|
|
227
|
+
ctx.addIssue({
|
|
228
|
+
code: "custom",
|
|
229
|
+
path: ["released"],
|
|
230
|
+
message: "an entry that declares a licence must say when it was released",
|
|
231
|
+
});
|
|
232
|
+
}
|
|
233
|
+
});
|
|
234
|
+
/**
|
|
235
|
+
* A plugin entry in version 2 of the index: version 1's, and the processing
|
|
236
|
+
* declaration.
|
|
237
|
+
*
|
|
238
|
+
* Repeated from the manifest on the terms the permissions are, because the
|
|
239
|
+
* consent screen shows it before anything is downloaded and the install seeds
|
|
240
|
+
* the record of processing activities from what that screen showed. Whether it
|
|
241
|
+
* is there is decided with the personal data, by the index as a whole below,
|
|
242
|
+
* since a refined object cannot be extended into the next version's entry.
|
|
243
|
+
*/
|
|
244
|
+
export const catalogPluginEntryV2Schema = catalogPluginEntrySchema.extend({
|
|
245
|
+
processing: pluginProcessingSchema.optional(),
|
|
135
246
|
});
|
|
136
247
|
/**
|
|
137
248
|
* A theme entry. Themes install through the same download-and-verify path and
|
|
@@ -152,13 +263,116 @@ export const catalogEntrySchema = z.discriminatedUnion("type", [
|
|
|
152
263
|
catalogPluginEntrySchema,
|
|
153
264
|
catalogThemeEntrySchema,
|
|
154
265
|
]);
|
|
155
|
-
export const
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
266
|
+
export const catalogEntryV2Schema = z.discriminatedUnion("type", [
|
|
267
|
+
catalogPluginEntryV2Schema,
|
|
268
|
+
catalogThemeEntrySchema,
|
|
269
|
+
]);
|
|
270
|
+
/** The index's rules about its entries taken together, in either version. */
|
|
271
|
+
function checkEntries(catalog, ctx) {
|
|
272
|
+
for (const [index, entry] of catalog.entries.entries()) {
|
|
273
|
+
if (entry.type !== "plugin") {
|
|
274
|
+
continue;
|
|
275
|
+
}
|
|
276
|
+
// The manifest's rule, so an entry the loader would refuse is never
|
|
277
|
+
// offered for consent.
|
|
278
|
+
for (const issue of proposeImportPersonalDataIssues(entry)) {
|
|
279
|
+
ctx.addIssue({
|
|
280
|
+
code: "custom",
|
|
281
|
+
path: ["entries", index, "personalData"],
|
|
282
|
+
message: issue.message,
|
|
283
|
+
});
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
for (const [index, entry] of catalog.entries.entries()) {
|
|
287
|
+
if (entry.type !== "plugin") {
|
|
288
|
+
continue;
|
|
289
|
+
}
|
|
290
|
+
/*
|
|
291
|
+
* A field version 1 does not define is refused there as any unknown key
|
|
292
|
+
* is, so an older instance and this one read the same index the same
|
|
293
|
+
* way.
|
|
294
|
+
*/
|
|
295
|
+
if (catalog.version === 1) {
|
|
296
|
+
for (const field of [
|
|
297
|
+
"extensionPoints",
|
|
298
|
+
"extends",
|
|
299
|
+
"deviceRoutes",
|
|
300
|
+
]) {
|
|
301
|
+
if (entry[field] !== undefined) {
|
|
302
|
+
ctx.addIssue({
|
|
303
|
+
code: "custom",
|
|
304
|
+
path: ["entries", index, field],
|
|
305
|
+
message: `${field} needs version 2 of the index`,
|
|
306
|
+
});
|
|
307
|
+
}
|
|
308
|
+
}
|
|
309
|
+
continue;
|
|
310
|
+
}
|
|
311
|
+
// The manifest's own rules, so an entry whose own declaration breaks
|
|
312
|
+
// one is never offered for consent.
|
|
313
|
+
for (const issue of extensionRuleIssues({
|
|
314
|
+
id: entry.id,
|
|
315
|
+
permissions: entry.permissions,
|
|
316
|
+
personalData: entry.personalData,
|
|
317
|
+
deviceRoutes: entry.deviceRoutes ?? [],
|
|
318
|
+
extensionPoints: entry.extensionPoints ?? [],
|
|
319
|
+
extends: entry.extends ?? [],
|
|
320
|
+
})) {
|
|
321
|
+
ctx.addIssue({
|
|
322
|
+
code: "custom",
|
|
323
|
+
path: ["entries", index, ...issue.path],
|
|
324
|
+
message: issue.message,
|
|
325
|
+
});
|
|
326
|
+
}
|
|
327
|
+
// The manifest's own rules, so an entry that the loader would refuse is
|
|
328
|
+
// never offered for consent.
|
|
329
|
+
for (const issue of deviceRouteRuleIssues({
|
|
330
|
+
deviceRoutes: entry.deviceRoutes ?? [],
|
|
331
|
+
oauthProtectedResource: entry.oauthProtectedResource,
|
|
332
|
+
permissions: entry.permissions,
|
|
333
|
+
})) {
|
|
334
|
+
ctx.addIssue({
|
|
335
|
+
code: "custom",
|
|
336
|
+
path: ["entries", index, ...issue.path],
|
|
337
|
+
message: issue.message,
|
|
338
|
+
});
|
|
339
|
+
}
|
|
340
|
+
}
|
|
341
|
+
/*
|
|
342
|
+
* A field is in the version that defines it and in no earlier one: an
|
|
343
|
+
* instance that reads only version 1 would refuse the entry, and an index
|
|
344
|
+
* claiming version 1 while carrying it is not one such an instance could
|
|
345
|
+
* read.
|
|
346
|
+
*/
|
|
347
|
+
if (catalog.version === 1) {
|
|
348
|
+
for (const [index, entry] of catalog.entries.entries()) {
|
|
349
|
+
if (entry.type === "plugin" && entry.recipients !== undefined) {
|
|
350
|
+
ctx.addIssue({
|
|
351
|
+
code: "custom",
|
|
352
|
+
path: ["entries", index, "recipients"],
|
|
353
|
+
message: "recipients is not in version 1 of the index; an entry that declares them is listed in version 2",
|
|
354
|
+
});
|
|
355
|
+
}
|
|
356
|
+
}
|
|
357
|
+
}
|
|
358
|
+
/*
|
|
359
|
+
* The manifest's rule on what a recipient may receive, so an entry the
|
|
360
|
+
* loader would refuse is not offered for consent with a category the
|
|
361
|
+
* plugin does not declare it handles. The comparison with the installed
|
|
362
|
+
* manifest comes later; this holds the entry to itself.
|
|
363
|
+
*/
|
|
364
|
+
for (const [index, entry] of catalog.entries.entries()) {
|
|
365
|
+
if (entry.type !== "plugin" || entry.recipients === undefined) {
|
|
366
|
+
continue;
|
|
367
|
+
}
|
|
368
|
+
for (const issue of recipientCategoryIssues(entry.recipients, entry.personalData)) {
|
|
369
|
+
ctx.addIssue({
|
|
370
|
+
code: "custom",
|
|
371
|
+
path: ["entries", index, ...issue.path],
|
|
372
|
+
message: issue.message,
|
|
373
|
+
});
|
|
374
|
+
}
|
|
375
|
+
}
|
|
162
376
|
/*
|
|
163
377
|
* An id names one entry in the whole index, not one per type. An install
|
|
164
378
|
* finds its entry by id and then refuses one of the wrong type, so a theme
|
|
@@ -178,7 +392,209 @@ export const catalogSchema = z
|
|
|
178
392
|
message: `"${entry.id}" is already the id of entry ${String(first)}; an id appears once in the index`,
|
|
179
393
|
});
|
|
180
394
|
}
|
|
395
|
+
}
|
|
396
|
+
const catalogV1Schema = z
|
|
397
|
+
.strictObject({
|
|
398
|
+
/** Index format version, so a future shape can be recognised and refused. */
|
|
399
|
+
version: z.literal(1),
|
|
400
|
+
entries: z.array(catalogEntrySchema).max(500),
|
|
401
|
+
})
|
|
402
|
+
.superRefine((catalog, ctx) => {
|
|
403
|
+
checkEntries(catalog, ctx);
|
|
404
|
+
});
|
|
405
|
+
const catalogV2Schema = z
|
|
406
|
+
.strictObject({
|
|
407
|
+
/**
|
|
408
|
+
* Version 2 adds the fields `CATALOG_INDEX_VERSIONS` lists to a plugin
|
|
409
|
+
* entry, `processing` (ADR 0035) among them, and changes nothing else.
|
|
410
|
+
* This package reads both versions; the catalog keeps serving version 1,
|
|
411
|
+
* without the entries that need version 2, to instances that have not
|
|
412
|
+
* upgraded.
|
|
413
|
+
*/
|
|
414
|
+
version: z.literal(2),
|
|
415
|
+
entries: z.array(catalogEntryV2Schema).max(500),
|
|
416
|
+
})
|
|
417
|
+
.superRefine((catalog, ctx) => {
|
|
418
|
+
checkEntries(catalog, ctx);
|
|
419
|
+
const plugins = new Map();
|
|
420
|
+
const pluginIndex = new Map();
|
|
421
|
+
for (const [index, entry] of catalog.entries.entries()) {
|
|
422
|
+
if (entry.type === "plugin" && !plugins.has(entry.id)) {
|
|
423
|
+
plugins.set(entry.id, entry);
|
|
424
|
+
pluginIndex.set(entry.id, index);
|
|
425
|
+
}
|
|
426
|
+
}
|
|
427
|
+
/** The addons already refused beside a plugin they extend. */
|
|
428
|
+
const pairRefused = new Set();
|
|
429
|
+
/*
|
|
430
|
+
* The manifest's own rule, both ways: an entry that declares personal data
|
|
431
|
+
* declares its processing, and one that declares none declares no
|
|
432
|
+
* processing. One that reads the address book declares personal data, so
|
|
433
|
+
* it has a processing a person can object to. Held here rather than only
|
|
434
|
+
* by the catalog's check of the package, so an index written by hand is
|
|
435
|
+
* held to it as well.
|
|
436
|
+
*/
|
|
437
|
+
for (const [index, entry] of catalog.entries.entries()) {
|
|
438
|
+
if (entry.type !== "plugin") {
|
|
439
|
+
continue;
|
|
440
|
+
}
|
|
441
|
+
const missing = missingProcessingProblem(entry);
|
|
442
|
+
if (missing !== null) {
|
|
443
|
+
ctx.addIssue({
|
|
444
|
+
code: "custom",
|
|
445
|
+
path: ["entries", index, "processing"],
|
|
446
|
+
message: missing,
|
|
447
|
+
});
|
|
448
|
+
}
|
|
449
|
+
const undeclared = undeclaredPersonalDataProblem(entry);
|
|
450
|
+
if (undeclared !== null) {
|
|
451
|
+
ctx.addIssue({
|
|
452
|
+
code: "custom",
|
|
453
|
+
path: ["entries", index, "personalData"],
|
|
454
|
+
message: undeclared,
|
|
455
|
+
});
|
|
456
|
+
}
|
|
457
|
+
if (entry.processing !== undefined && entry.personalData.length === 0) {
|
|
458
|
+
ctx.addIssue({
|
|
459
|
+
code: "custom",
|
|
460
|
+
path: ["entries", index, "processing"],
|
|
461
|
+
message: "a plugin that declares no personal data declares no processing",
|
|
462
|
+
});
|
|
463
|
+
}
|
|
464
|
+
/*
|
|
465
|
+
* The rule between an addon and a plugin it extends, where the index
|
|
466
|
+
* lists both, read from the two entries. One it does not list is held to
|
|
467
|
+
* it by the loader, which reads the installed manifests, as it holds
|
|
468
|
+
* one it lists.
|
|
469
|
+
*/
|
|
470
|
+
for (const [position, extension] of (entry.extends ?? []).entries()) {
|
|
471
|
+
const host = plugins.get(extension.plugin);
|
|
472
|
+
if (host === undefined) {
|
|
473
|
+
continue;
|
|
474
|
+
}
|
|
475
|
+
const named = {
|
|
476
|
+
addon: entry.id,
|
|
477
|
+
plugin: extension.plugin,
|
|
478
|
+
point: extension.point,
|
|
479
|
+
};
|
|
480
|
+
const unserved = extensionPointRefusal(extension, host.extensionPoints ?? []);
|
|
481
|
+
if (unserved !== null) {
|
|
482
|
+
pairRefused.add(entry.id);
|
|
483
|
+
const { field, message, detail } = unservedIssue(extension, unserved);
|
|
484
|
+
ctx.addIssue({
|
|
485
|
+
code: "custom",
|
|
486
|
+
path: ["entries", index, "extends", position, field],
|
|
487
|
+
message,
|
|
488
|
+
params: {
|
|
489
|
+
refusal: {
|
|
490
|
+
code: unserved.reason,
|
|
491
|
+
detail: { ...named, ...detail },
|
|
492
|
+
},
|
|
493
|
+
},
|
|
494
|
+
});
|
|
495
|
+
continue;
|
|
496
|
+
}
|
|
497
|
+
const refused = extensionPermissionsRefused(entry, host);
|
|
498
|
+
if (refused.length > 0) {
|
|
499
|
+
pairRefused.add(entry.id);
|
|
500
|
+
ctx.addIssue({
|
|
501
|
+
code: "custom",
|
|
502
|
+
path: ["entries", index, "extends", position, "plugin"],
|
|
503
|
+
message: host.permissions.includes("site:blocks")
|
|
504
|
+
? `${extension.plugin} asks for "site:blocks", so a plugin that extends it may not read the register or propose imports: ${refused.join(", ")}`
|
|
505
|
+
: `${extension.plugin} reads the register or proposes imports, so a plugin that asks for "site:blocks" may not extend it: ${refused.join(", ")}`,
|
|
506
|
+
params: {
|
|
507
|
+
refusal: {
|
|
508
|
+
code: "extension-permission-refused",
|
|
509
|
+
detail: { ...named, permissions: refused },
|
|
510
|
+
},
|
|
511
|
+
},
|
|
512
|
+
});
|
|
513
|
+
continue;
|
|
514
|
+
}
|
|
515
|
+
const categories = extensionHostPersonalDataRefused(entry, host);
|
|
516
|
+
if (categories.length > 0) {
|
|
517
|
+
pairRefused.add(entry.id);
|
|
518
|
+
ctx.addIssue({
|
|
519
|
+
code: "custom",
|
|
520
|
+
path: ["entries", index, "extends", position, "plugin"],
|
|
521
|
+
message: `${extension.plugin} handles personal data, so a plugin that asks for "site:blocks" may not extend it: ${categories.join(", ")}`,
|
|
522
|
+
params: {
|
|
523
|
+
refusal: {
|
|
524
|
+
code: "extension-host-personal-data-refused",
|
|
525
|
+
detail: { ...named, categories },
|
|
526
|
+
},
|
|
527
|
+
},
|
|
528
|
+
});
|
|
529
|
+
}
|
|
530
|
+
}
|
|
531
|
+
}
|
|
532
|
+
/*
|
|
533
|
+
* And the rule on the plugins joined by extensions, among those the index
|
|
534
|
+
* lists, as the loader reads it: beside the addons the rule above has not
|
|
535
|
+
* already refused.
|
|
536
|
+
*/
|
|
537
|
+
if (catalog.version === 2) {
|
|
538
|
+
const members = [...plugins.values()]
|
|
539
|
+
.filter((entry) => !pairRefused.has(entry.id))
|
|
540
|
+
.map((entry) => ({
|
|
541
|
+
id: entry.id,
|
|
542
|
+
permissions: entry.permissions,
|
|
543
|
+
extends: entry.extends ?? [],
|
|
544
|
+
}));
|
|
545
|
+
for (const [id, refusal] of extensionGroupRefusals(members)) {
|
|
546
|
+
ctx.addIssue({
|
|
547
|
+
code: "custom",
|
|
548
|
+
path: ["entries", pluginIndex.get(id) ?? 0, "extends"],
|
|
549
|
+
message: `the plugins it is joined to by extensions would hold one that asks for "site:blocks" (${refusal.website.join(", ")}) and one that reads the register or proposes imports (${refusal.register.join(", ")})`,
|
|
550
|
+
params: {
|
|
551
|
+
refusal: {
|
|
552
|
+
code: "extension-group-refused",
|
|
553
|
+
detail: {
|
|
554
|
+
addon: id,
|
|
555
|
+
website: refusal.website,
|
|
556
|
+
register: refusal.register,
|
|
557
|
+
},
|
|
558
|
+
},
|
|
559
|
+
},
|
|
560
|
+
});
|
|
561
|
+
}
|
|
562
|
+
}
|
|
181
563
|
});
|
|
564
|
+
/**
|
|
565
|
+
* The index versions this package reads.
|
|
566
|
+
*
|
|
567
|
+
* Version 2 adds the fields ADR 0030 lists: `extensionPoints` and `extends`
|
|
568
|
+
* (ADR 0030), `recipients` (ADR 0037) and `deviceRoutes` (ADR 0031), and
|
|
569
|
+
* `processing` (ADR 0035). An instance reads both, and the catalog serves
|
|
570
|
+
* version 1, without the entries that need version 2, to instances that have
|
|
571
|
+
* not upgraded.
|
|
572
|
+
*/
|
|
573
|
+
export const CATALOG_INDEX_VERSIONS = [1, 2];
|
|
574
|
+
/** The version of the index this SDK writes and reads first. */
|
|
575
|
+
export const CATALOG_INDEX_VERSION = 2;
|
|
576
|
+
export const catalogSchema = z.discriminatedUnion("version", [
|
|
577
|
+
catalogV1Schema,
|
|
578
|
+
catalogV2Schema,
|
|
579
|
+
]);
|
|
580
|
+
/**
|
|
581
|
+
* The refusals of an index that its reader is told in their own language.
|
|
582
|
+
*
|
|
583
|
+
* What the schema says about one entry's field is English for the catalog's
|
|
584
|
+
* curator, who fixes the index from it. These hold one entry against another,
|
|
585
|
+
* an addon against the plugin it extends or against the plugins joined to it,
|
|
586
|
+
* and are the loader's own refusals of the same pair, under the same codes. So
|
|
587
|
+
* the refusal carries its code and the values its sentence is completed with
|
|
588
|
+
* beside the English line, and whoever shows it translates the code.
|
|
589
|
+
*/
|
|
590
|
+
export const CATALOG_REFUSALS = [
|
|
591
|
+
"extension-point-unknown",
|
|
592
|
+
"extension-version-unsupported",
|
|
593
|
+
"extension-personal-data-refused",
|
|
594
|
+
"extension-permission-refused",
|
|
595
|
+
"extension-host-personal-data-refused",
|
|
596
|
+
"extension-group-refused",
|
|
597
|
+
];
|
|
182
598
|
/**
|
|
183
599
|
* Parses a catalog index.
|
|
184
600
|
*
|
|
@@ -195,9 +611,50 @@ export function parseCatalogIndex(input) {
|
|
|
195
611
|
if (result.success) {
|
|
196
612
|
return { ok: true, value: result.data };
|
|
197
613
|
}
|
|
614
|
+
const diagnostics = result.error.issues.map((issue) => ({
|
|
615
|
+
issue: `${issue.path.join(".") || "(root)"}: ${issue.message}`,
|
|
616
|
+
refusal: catalogRefusalOf(issue),
|
|
617
|
+
}));
|
|
198
618
|
return {
|
|
199
619
|
ok: false,
|
|
200
|
-
issues:
|
|
620
|
+
issues: diagnostics.map((diagnostic) => diagnostic.issue),
|
|
621
|
+
diagnostics,
|
|
201
622
|
};
|
|
202
623
|
}
|
|
624
|
+
function catalogRefusalOf(issue) {
|
|
625
|
+
if (issue.code !== "custom" || typeof issue.params !== "object") {
|
|
626
|
+
return null;
|
|
627
|
+
}
|
|
628
|
+
const refusal = issue.params
|
|
629
|
+
?.refusal;
|
|
630
|
+
return refusal !== undefined && CATALOG_REFUSALS.includes(refusal.code)
|
|
631
|
+
? refusal
|
|
632
|
+
: null;
|
|
633
|
+
}
|
|
634
|
+
/** The field, the curator's line and the values of a point's refusal. */
|
|
635
|
+
function unservedIssue(extension, unserved) {
|
|
636
|
+
switch (unserved.reason) {
|
|
637
|
+
case "extension-point-unknown":
|
|
638
|
+
return {
|
|
639
|
+
field: "point",
|
|
640
|
+
message: `${extension.plugin} declares no extension point "${extension.point}"`,
|
|
641
|
+
detail: {},
|
|
642
|
+
};
|
|
643
|
+
case "extension-version-unsupported":
|
|
644
|
+
return {
|
|
645
|
+
field: "version",
|
|
646
|
+
message: `"${extension.point}" of ${extension.plugin} is at version ${String(unserved.supported)}, not ${String(extension.version)}`,
|
|
647
|
+
detail: {
|
|
648
|
+
version: extension.version,
|
|
649
|
+
supported: unserved.supported,
|
|
650
|
+
},
|
|
651
|
+
};
|
|
652
|
+
case "extension-personal-data-refused":
|
|
653
|
+
return {
|
|
654
|
+
field: "personalData",
|
|
655
|
+
message: `"${extension.point}" of ${extension.plugin} does not accept ${unserved.categories.join(", ")}`,
|
|
656
|
+
detail: { categories: unserved.categories },
|
|
657
|
+
};
|
|
658
|
+
}
|
|
659
|
+
}
|
|
203
660
|
//# sourceMappingURL=catalog.js.map
|
package/dist/catalog.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"catalog.js","sourceRoot":"","sources":["../src/catalog.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,cAAc,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7D,OAAO,EACL,qBAAqB,EACrB,kBAAkB,EAClB,cAAc,EACd,oBAAoB,GACrB,MAAM,eAAe,CAAC;AACvB,OAAO,EACL,kBAAkB,EAClB,+BAA+B,GAChC,MAAM,kBAAkB,CAAC;AA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