@ploaness/governance 1.1.0 → 1.3.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/dist/a11y-hit-target.d.ts.map +1 -1
- package/dist/a11y-hit-target.js +1 -21
- package/dist/a11y-hit-target.js.map +1 -1
- package/dist/a11y-incomplete.d.ts.map +1 -1
- package/dist/a11y-incomplete.js +1 -18
- package/dist/a11y-incomplete.js.map +1 -1
- package/dist/access-boundary.d.ts +43 -1
- package/dist/access-boundary.d.ts.map +1 -1
- package/dist/access-boundary.js +146 -5
- package/dist/access-boundary.js.map +1 -1
- package/dist/admin-view-coverage.d.ts.map +1 -1
- package/dist/admin-view-coverage.js +1 -17
- package/dist/admin-view-coverage.js.map +1 -1
- package/dist/asset-policy.d.ts.map +1 -1
- package/dist/asset-policy.js +1 -23
- package/dist/asset-policy.js.map +1 -1
- package/dist/axe-coverage.d.ts +3 -4
- package/dist/axe-coverage.d.ts.map +1 -1
- package/dist/axe-coverage.js +18 -51
- package/dist/axe-coverage.js.map +1 -1
- package/dist/blocklist-entries.d.ts +36 -0
- package/dist/blocklist-entries.d.ts.map +1 -0
- package/dist/blocklist-entries.js +338 -0
- package/dist/blocklist-entries.js.map +1 -0
- package/dist/blocklist.d.ts +91 -0
- package/dist/blocklist.d.ts.map +1 -0
- package/dist/blocklist.js +187 -0
- package/dist/blocklist.js.map +1 -0
- package/dist/checkov-check.d.ts +9 -0
- package/dist/checkov-check.d.ts.map +1 -0
- package/dist/checkov-check.js +4 -0
- package/dist/checkov-check.js.map +1 -0
- package/dist/checkov-checks-aws.d.ts +4 -0
- package/dist/checkov-checks-aws.d.ts.map +1 -0
- package/dist/checkov-checks-aws.js +93 -0
- package/dist/checkov-checks-aws.js.map +1 -0
- package/dist/checkov-checks-azure.d.ts +4 -0
- package/dist/checkov-checks-azure.d.ts.map +1 -0
- package/dist/checkov-checks-azure.js +32 -0
- package/dist/checkov-checks-azure.js.map +1 -0
- package/dist/checkov-checks-google.d.ts +6 -0
- package/dist/checkov-checks-google.d.ts.map +1 -0
- package/dist/checkov-checks-google.js +53 -0
- package/dist/checkov-checks-google.js.map +1 -0
- package/dist/checkov-policy.d.ts +63 -0
- package/dist/checkov-policy.d.ts.map +1 -0
- package/dist/checkov-policy.js +105 -0
- package/dist/checkov-policy.js.map +1 -0
- package/dist/container-failure.d.ts.map +1 -1
- package/dist/container-failure.js +1 -18
- package/dist/container-failure.js.map +1 -1
- package/dist/container-files.d.ts +16 -0
- package/dist/container-files.d.ts.map +1 -1
- package/dist/container-files.js +23 -8
- package/dist/container-files.js.map +1 -1
- package/dist/container-images.d.ts +43 -0
- package/dist/container-images.d.ts.map +1 -0
- package/dist/container-images.js +157 -0
- package/dist/container-images.js.map +1 -0
- package/dist/dependency-freshness.d.ts +8 -0
- package/dist/dependency-freshness.d.ts.map +1 -1
- package/dist/dependency-freshness.js +2 -18
- package/dist/dependency-freshness.js.map +1 -1
- package/dist/doc-blocks.d.ts.map +1 -1
- package/dist/doc-blocks.js +1 -13
- package/dist/doc-blocks.js.map +1 -1
- package/dist/editorconfig-policy.d.ts +7 -0
- package/dist/editorconfig-policy.d.ts.map +1 -1
- package/dist/editorconfig-policy.js +19 -12
- package/dist/editorconfig-policy.js.map +1 -1
- package/dist/environment-coherence.d.ts +59 -5
- package/dist/environment-coherence.d.ts.map +1 -1
- package/dist/environment-coherence.js +107 -27
- package/dist/environment-coherence.js.map +1 -1
- package/dist/environment-files.d.ts.map +1 -1
- package/dist/environment-files.js +1 -19
- package/dist/environment-files.js.map +1 -1
- package/dist/file-roles.d.ts +7 -2
- package/dist/file-roles.d.ts.map +1 -1
- package/dist/file-roles.js +10 -9
- package/dist/file-roles.js.map +1 -1
- package/dist/freshness-repair.d.ts +82 -0
- package/dist/freshness-repair.d.ts.map +1 -0
- package/dist/freshness-repair.js +91 -0
- package/dist/freshness-repair.js.map +1 -0
- package/dist/generated-denial.d.ts.map +1 -1
- package/dist/generated-denial.js +1 -9
- package/dist/generated-denial.js.map +1 -1
- package/dist/generated-drift.d.ts.map +1 -1
- package/dist/generated-drift.js +1 -12
- package/dist/generated-drift.js.map +1 -1
- package/dist/harness-package.d.ts +13 -0
- package/dist/harness-package.d.ts.map +1 -0
- package/dist/harness-package.js +20 -0
- package/dist/harness-package.js.map +1 -0
- package/dist/history-policy.d.ts.map +1 -1
- package/dist/history-policy.js +1 -7
- package/dist/history-policy.js.map +1 -1
- package/dist/image-assets.d.ts.map +1 -1
- package/dist/image-assets.js +1 -10
- package/dist/image-assets.js.map +1 -1
- package/dist/index.d.ts +20 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +20 -0
- package/dist/index.js.map +1 -1
- package/dist/install-policy.d.ts +21 -0
- package/dist/install-policy.d.ts.map +1 -1
- package/dist/install-policy.js +53 -1
- package/dist/install-policy.js.map +1 -1
- package/dist/jsx-accessibility-scope.d.ts +17 -0
- package/dist/jsx-accessibility-scope.d.ts.map +1 -0
- package/dist/jsx-accessibility-scope.js +36 -0
- package/dist/jsx-accessibility-scope.js.map +1 -0
- package/dist/jsx-accessibility.d.ts +13 -0
- package/dist/jsx-accessibility.d.ts.map +1 -0
- package/dist/jsx-accessibility.js +188 -0
- package/dist/jsx-accessibility.js.map +1 -0
- package/dist/network-policy.d.ts.map +1 -1
- package/dist/network-policy.js +1 -12
- package/dist/network-policy.js.map +1 -1
- package/dist/oxlint-policy.d.ts +16 -0
- package/dist/oxlint-policy.d.ts.map +1 -0
- package/dist/oxlint-policy.js +28 -0
- package/dist/oxlint-policy.js.map +1 -0
- package/dist/oxlint-report.d.ts +29 -0
- package/dist/oxlint-report.d.ts.map +1 -0
- package/dist/oxlint-report.js +84 -0
- package/dist/oxlint-report.js.map +1 -0
- package/dist/oxlint-scope.d.ts +13 -0
- package/dist/oxlint-scope.d.ts.map +1 -0
- package/dist/oxlint-scope.js +46 -0
- package/dist/oxlint-scope.js.map +1 -0
- package/dist/oxlint-suppressions.d.ts +17 -0
- package/dist/oxlint-suppressions.d.ts.map +1 -0
- package/dist/oxlint-suppressions.js +72 -0
- package/dist/oxlint-suppressions.js.map +1 -0
- package/dist/paired-assets.d.ts.map +1 -1
- package/dist/paired-assets.js.map +1 -1
- package/dist/payload-access.d.ts +6 -0
- package/dist/payload-access.d.ts.map +1 -1
- package/dist/payload-access.js +166 -9
- package/dist/payload-access.js.map +1 -1
- package/dist/payload-bootstrap.d.ts +52 -0
- package/dist/payload-bootstrap.d.ts.map +1 -0
- package/dist/payload-bootstrap.js +195 -0
- package/dist/payload-bootstrap.js.map +1 -0
- package/dist/payload-configs.d.ts +0 -1
- package/dist/payload-configs.d.ts.map +1 -1
- package/dist/payload-configs.js +36 -17
- package/dist/payload-configs.js.map +1 -1
- package/dist/payload-database.d.ts +80 -0
- package/dist/payload-database.d.ts.map +1 -0
- package/dist/payload-database.js +164 -0
- package/dist/payload-database.js.map +1 -0
- package/dist/payload-defaults.d.ts +128 -0
- package/dist/payload-defaults.d.ts.map +1 -0
- package/dist/payload-defaults.js +295 -0
- package/dist/payload-defaults.js.map +1 -0
- package/dist/payload-policy.d.ts +21 -0
- package/dist/payload-policy.d.ts.map +1 -1
- package/dist/payload-policy.js +92 -43
- package/dist/payload-policy.js.map +1 -1
- package/dist/relationship-cleanup.d.ts.map +1 -1
- package/dist/relationship-cleanup.js +16 -16
- package/dist/relationship-cleanup.js.map +1 -1
- package/dist/release-age.d.ts.map +1 -1
- package/dist/release-age.js +1 -16
- package/dist/release-age.js.map +1 -1
- package/dist/request-limits.d.ts.map +1 -1
- package/dist/request-limits.js +1 -11
- package/dist/request-limits.js.map +1 -1
- package/dist/route-map.d.ts.map +1 -1
- package/dist/route-map.js +1 -16
- package/dist/route-map.js.map +1 -1
- package/dist/run-plan.d.ts.map +1 -1
- package/dist/run-plan.js +1 -19
- package/dist/run-plan.js.map +1 -1
- package/dist/secret-policy.d.ts.map +1 -1
- package/dist/secret-policy.js +1 -11
- package/dist/secret-policy.js.map +1 -1
- package/dist/settings-layering.d.ts +8 -30
- package/dist/settings-layering.d.ts.map +1 -1
- package/dist/settings-layering.js +19 -48
- package/dist/settings-layering.js.map +1 -1
- package/dist/settings.d.ts +9 -2
- package/dist/settings.d.ts.map +1 -1
- package/dist/settings.js.map +1 -1
- package/dist/shell-files.d.ts +45 -0
- package/dist/shell-files.d.ts.map +1 -0
- package/dist/shell-files.js +105 -0
- package/dist/shell-files.js.map +1 -0
- package/dist/source-security.d.ts +10 -0
- package/dist/source-security.d.ts.map +1 -1
- package/dist/source-security.js +88 -1
- package/dist/source-security.js.map +1 -1
- package/dist/source-text.d.ts +2 -0
- package/dist/source-text.d.ts.map +1 -1
- package/dist/source-text.js +7 -16
- package/dist/source-text.js.map +1 -1
- package/dist/terraform-files.d.ts +29 -0
- package/dist/terraform-files.d.ts.map +1 -0
- package/dist/terraform-files.js +50 -0
- package/dist/terraform-files.js.map +1 -0
- package/dist/terraform-policy.d.ts +13 -0
- package/dist/terraform-policy.d.ts.map +1 -0
- package/dist/terraform-policy.js +261 -0
- package/dist/terraform-policy.js.map +1 -0
- package/dist/terraform-providers.d.ts +28 -0
- package/dist/terraform-providers.d.ts.map +1 -0
- package/dist/terraform-providers.js +68 -0
- package/dist/terraform-providers.js.map +1 -0
- package/dist/toolchain-pins.d.ts +1 -1
- package/dist/toolchain-pins.d.ts.map +1 -1
- package/dist/toolchain-pins.js +11 -21
- package/dist/toolchain-pins.js.map +1 -1
- package/dist/version-policy.d.ts +7 -8
- package/dist/version-policy.d.ts.map +1 -1
- package/dist/version-policy.js +15 -26
- package/dist/version-policy.js.map +1 -1
- package/dist/vulnerability-policy.d.ts.map +1 -1
- package/dist/vulnerability-policy.js +1 -11
- package/dist/vulnerability-policy.js.map +1 -1
- package/dist/wiring-policy.d.ts.map +1 -1
- package/dist/wiring-policy.js +4 -1
- package/dist/wiring-policy.js.map +1 -1
- package/dist/wiring-violation.d.ts.map +1 -1
- package/dist/wiring-violation.js +1 -6
- package/dist/wiring-violation.js.map +1 -1
- package/dist/workspace-policy.d.ts.map +1 -1
- package/dist/workspace-policy.js +3 -9
- package/dist/workspace-policy.js.map +1 -1
- package/dist/yaml-blocks.d.ts +10 -0
- package/dist/yaml-blocks.d.ts.map +1 -1
- package/dist/yaml-blocks.js +20 -0
- package/dist/yaml-blocks.js.map +1 -1
- package/package.json +2 -2
package/dist/axe-coverage.js
CHANGED
|
@@ -1,23 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
//
|
|
4
|
-
|
|
5
|
-
// of an application route the anonymous link crawl never reached. Neither can be answered by ploaness
|
|
6
|
-
// itself - it cannot sign in, and it cannot press the button that creates a record - so both answer it
|
|
7
|
-
// the same way: the project is required to have written the scan somewhere a check can see.
|
|
8
|
-
//
|
|
9
|
-
// It is one module rather than two copies because the load-bearing part is easy to omit and expensive
|
|
10
|
-
// to omit. `routeText` strips import specifiers before any route is searched for, and the comment on
|
|
11
|
-
// `MODULE_SPECIFIER` records what happened without it: `@/lib/calendar/interval` contains `/calendar`,
|
|
12
|
-
// so every unit spec of a `calendar` module looked like a test driving the view, and one that also
|
|
13
|
-
// imported the shared axe helper then answered for a view nothing scans. A second copy that forgot
|
|
14
|
-
// that line would ship the same false pass again.
|
|
15
|
-
import { stripComments } from './source-text.js';
|
|
16
|
-
// What proves a file reaches axe. The builder's class name covers the Playwright and WebdriverIO
|
|
17
|
-
// packages alike, the scoped package name covers a bare import, and `axe.run` covers the browser
|
|
18
|
-
// script form. A project driving axe some fourth way is asked to say so rather than assumed to have
|
|
19
|
-
// nothing.
|
|
20
|
-
const AXE_MARKERS = ['AxeBuilder', '@axe-core', 'axe.run'];
|
|
1
|
+
import path from 'node:path';
|
|
2
|
+
import { maskLiterals, stripComments, withoutComments } from './source-text.js';
|
|
3
|
+
// Recognize axe identifiers in code, excluding comments, strings, and regex literals.
|
|
4
|
+
const AXE_MARKERS = ['AxeBuilder', 'axe.run'];
|
|
21
5
|
const REGEX_METACHARACTERS = /[$()*+.?[\\\]^{|}]/gu;
|
|
22
6
|
const escaped = (text) => text.replaceAll(REGEX_METACHARACTERS, String.raw `\$&`);
|
|
23
7
|
// An import specifier is a path too, and `@/lib/calendar/interval` contains `/calendar`. Read as a
|
|
@@ -27,24 +11,7 @@ const escaped = (text) => text.replaceAll(REGEX_METACHARACTERS, String.raw `\$&`
|
|
|
27
11
|
// removed before the search; `importedSources` reads the specifiers from the original text, where
|
|
28
12
|
// they still are.
|
|
29
13
|
const MODULE_SPECIFIER = /\b(?:from|import)\s*(?:\(\s*)?['"][^'"]*['"]/gu;
|
|
30
|
-
|
|
31
|
-
// because a `//` inside a pattern would otherwise open a comment that never closes - correct for a
|
|
32
|
-
// lexer, and fatal here: `page.waitForURL(/\/welcome$/u)` is how a Playwright specification names the
|
|
33
|
-
// address it is waiting for, and blanking it made the commonest idiom in the file invisible. So the
|
|
34
|
-
// literals are put back, extracted from the original text and searched alongside it.
|
|
35
|
-
//
|
|
36
|
-
// The pattern admits a little more than a real literal does - a division written with spaces around
|
|
37
|
-
// it can look like one - which only ever adds text to search, never removes it. What it costs is
|
|
38
|
-
// narrow and worth naming: a route spelled as a regular expression INSIDE a comment is no longer told
|
|
39
|
-
// apart from one in code, and will answer for its page. Refusing regular expressions altogether was
|
|
40
|
-
// the alternative, and it fails the ordinary case to close a hole nobody falls into by accident.
|
|
41
|
-
const REGEX_LITERAL = /(?<![\w)\]])\/(?![/*])(?:\\.|\[(?:\\.|[^\]\\])*\]|[^/\\\n[])+\/[dgimsuvy]*/gu;
|
|
42
|
-
// Comments go first, because a route named in one explaining why a page is NOT scanned would
|
|
43
|
-
// otherwise answer for that page.
|
|
44
|
-
const routeText = (source) => [
|
|
45
|
-
stripComments(source).replaceAll(MODULE_SPECIFIER, ''),
|
|
46
|
-
...(source.match(REGEX_LITERAL) ?? []),
|
|
47
|
-
].join('\n');
|
|
14
|
+
const routeText = (source) => withoutComments(source).replaceAll(MODULE_SPECIFIER, '');
|
|
48
15
|
/**
|
|
49
16
|
* Whether a specification names one route.
|
|
50
17
|
*
|
|
@@ -69,26 +36,26 @@ export const containsRoute = (source, route) => new RegExp(String.raw `${escaped
|
|
|
69
36
|
* @returns true when the text builds a URL below that prefix.
|
|
70
37
|
*/
|
|
71
38
|
export const containsBuiltRoute = (source, prefix) => routeText(source).includes(`${prefix === '/' ? '' : prefix}/\${`);
|
|
72
|
-
const carriesAxe = (source) => AXE_MARKERS.some((marker) => source.includes(marker));
|
|
39
|
+
const carriesAxe = (source) => AXE_MARKERS.some((marker) => maskLiterals(source).includes(marker));
|
|
73
40
|
const RELATIVE_IMPORT = /\bfrom\s*['"](\.[^'"]*)['"]/gu;
|
|
74
|
-
//
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
41
|
+
// Resolve from the importing file, without accessing the filesystem. All candidates were already read.
|
|
42
|
+
const matchesFile = (specifier, importer, candidate) => {
|
|
43
|
+
const resolved = path.posix.normalize(path.posix.join(path.posix.dirname(importer), specifier));
|
|
44
|
+
const stem = resolved.replace(/\.[cm]?jsx?$/u, '');
|
|
45
|
+
return [
|
|
46
|
+
resolved,
|
|
47
|
+
...['.ts', '.tsx', '.mts', '.cts', '/index.ts', '/index.tsx'].map((suffix) => `${stem}${suffix}`),
|
|
48
|
+
].includes(candidate);
|
|
81
49
|
};
|
|
82
|
-
const importedSources = (spec, everyFile) => [...spec.source.matchAll(RELATIVE_IMPORT)].flatMap((match) => everyFile.filter((candidate) => matchesFile(match[1] ?? '', candidate.path)));
|
|
50
|
+
const importedSources = (spec, everyFile) => [...stripComments(spec.source).matchAll(RELATIVE_IMPORT)].flatMap((match) => everyFile.filter((candidate) => matchesFile(match[1] ?? '', spec.path, candidate.path)));
|
|
83
51
|
/**
|
|
84
52
|
* Whether a specification scans with axe, directly or through a helper it imports.
|
|
85
53
|
*
|
|
86
|
-
*
|
|
87
|
-
*
|
|
88
|
-
* would trade a rule anyone can predict for one nobody can.
|
|
54
|
+
* This is static source evidence through at most one helper import. It does not establish execution;
|
|
55
|
+
* the end-to-end suite must run the scan.
|
|
89
56
|
* @param spec the specification being judged.
|
|
90
57
|
* @param everyFile every file it may import a scan from, the specifications included.
|
|
91
|
-
* @returns true when
|
|
58
|
+
* @returns true when the source names axe directly or through an imported helper.
|
|
92
59
|
*/
|
|
93
60
|
export const reachesAxe = (spec, everyFile) => carriesAxe(spec.source) ||
|
|
94
61
|
importedSources(spec, everyFile).some((imported) => carriesAxe(imported.source));
|
package/dist/axe-coverage.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"axe-coverage.js","sourceRoot":"","sources":["../src/axe-coverage.ts"],"names":[],"mappings":"AAAA,
|
|
1
|
+
{"version":3,"file":"axe-coverage.js","sourceRoot":"","sources":["../src/axe-coverage.ts"],"names":[],"mappings":"AAAA,OAAO,IAAI,MAAM,WAAW,CAAA;AAC5B,OAAO,EAAE,YAAY,EAAE,aAAa,EAAE,eAAe,EAAE,MAAM,kBAAkB,CAAA;AAQ/E,sFAAsF;AACtF,MAAM,WAAW,GAAsB,CAAC,YAAY,EAAE,SAAS,CAAC,CAAA;AAEhE,MAAM,oBAAoB,GAAW,sBAAsB,CAAA;AAE3D,MAAM,OAAO,GAAG,CAAC,IAAY,EAAU,EAAE,CAAC,IAAI,CAAC,UAAU,CAAC,oBAAoB,EAAE,MAAM,CAAC,GAAG,CAAA,KAAK,CAAC,CAAA;AAEhG,mGAAmG;AACnG,oGAAoG;AACpG,mGAAmG;AACnG,gGAAgG;AAChG,kGAAkG;AAClG,kBAAkB;AAClB,MAAM,gBAAgB,GAAW,gDAAgD,CAAA;AAEjF,MAAM,SAAS,GAAG,CAAC,MAAc,EAAU,EAAE,CAC3C,eAAe,CAAC,MAAM,CAAC,CAAC,UAAU,CAAC,gBAAgB,EAAE,EAAE,CAAC,CAAA;AAE1D;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG,CAAC,MAAc,EAAE,KAAa,EAAW,EAAE,CACtE,IAAI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AG,CACtB,IAAgB,EAChB,SAAgC,EACT,EAAE,CACzB,CAAC,GAAG,aAAa,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC,QAAQ,CAAC,eAAe,CAAC,CAAC,CAAC,OAAO,CAC/D,CAAC,KAAsB,EAAgB,EAAE,CACvC,SAAS,CAAC,MAAM,CAAC,CAAC,SAAqB,EAAW,EAAE,CAClD,WAAW,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,EAAE,EAAE,IAAI,CAAC,IAAI,EAAE,SAAS,CAAC,IAAI,CAAC,CACvD,CACJ,CAAA;AAEH;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,UAAU,GAAG,CAAC,IAAgB,EAAE,SAAgC,EAAW,EAAE,CACxF,UAAU,CAAC,IAAI,CAAC,MAAM,CAAC;IACvB,eAAe,CAAC,IAAI,EAAE,SAAS,CAAC,CAAC,IAAI,CAAC,CAAC,QAAoB,EAAW,EAAE,CACtE,UAAU,CAAC,QAAQ,CAAC,MAAM,CAAC,CAC5B,CAAA"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
/** One image repository ploaness refuses, and what a project pulls instead. */
|
|
2
|
+
export interface BlockedImage {
|
|
3
|
+
/**
|
|
4
|
+
* The repository in normalised form: no `docker.io/`, no `library/`, a registry host kept for any
|
|
5
|
+
* other registry. A trailing `*` matches every repository under that prefix.
|
|
6
|
+
*/
|
|
7
|
+
readonly repository: string;
|
|
8
|
+
/** The first tag the refusal applies to, when the repository was once permissively licensed. */
|
|
9
|
+
readonly from?: string;
|
|
10
|
+
/** A tag pattern that stays allowed, for a repository publishing an open-source variant beside the default. */
|
|
11
|
+
readonly allowedTag?: RegExp;
|
|
12
|
+
readonly reason: string;
|
|
13
|
+
readonly replacement: string;
|
|
14
|
+
}
|
|
15
|
+
/** One npm package ploaness refuses, and what a project depends on instead. */
|
|
16
|
+
export interface BlockedPackage {
|
|
17
|
+
/** The package name; a trailing `*` matches every name under that prefix, `@scope/*` a whole scope. */
|
|
18
|
+
readonly name: string;
|
|
19
|
+
/** The first version the refusal applies to, when the package was once permissively licensed. */
|
|
20
|
+
readonly from?: string;
|
|
21
|
+
readonly reason: string;
|
|
22
|
+
readonly replacement: string;
|
|
23
|
+
}
|
|
24
|
+
/** One system package ploaness refuses in a Dockerfile install line. */
|
|
25
|
+
export interface BlockedSystemPackage {
|
|
26
|
+
readonly name: string;
|
|
27
|
+
readonly reason: string;
|
|
28
|
+
readonly replacement: string;
|
|
29
|
+
}
|
|
30
|
+
/** The image repositories ploaness refuses, in the order the report lists them. */
|
|
31
|
+
export declare const BLOCKED_IMAGES: readonly BlockedImage[];
|
|
32
|
+
/** The npm packages ploaness refuses, in the order the report lists them. */
|
|
33
|
+
export declare const BLOCKED_PACKAGES: readonly BlockedPackage[];
|
|
34
|
+
/** The system packages a Dockerfile may not install. */
|
|
35
|
+
export declare const BLOCKED_SYSTEM_PACKAGES: readonly BlockedSystemPackage[];
|
|
36
|
+
//# sourceMappingURL=blocklist-entries.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"blocklist-entries.d.ts","sourceRoot":"","sources":["../src/blocklist-entries.ts"],"names":[],"mappings":"AAeA,+EAA+E;AAC/E,MAAM,WAAW,YAAY;IAC3B;;;OAGG;IACH,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAA;IAC3B,gGAAgG;IAChG,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAA;IACtB,+GAA+G;IAC/G,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAA;IAC5B,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAA;CAC7B;AAED,+EAA+E;AAC/E,MAAM,WAAW,cAAc;IAC7B,uGAAuG;IACvG,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;IACrB,iGAAiG;IACjG,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAA;IACtB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAA;CAC7B;AAED,wEAAwE;AACxE,MAAM,WAAW,oBAAoB;IACnC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;IACrB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAA;IACvB,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAA;CAC7B;AAkCD,mFAAmF;AACnF,eAAO,MAAM,cAAc,EAAE,SAAS,YAAY,EAwMjD,CAAA;AAED,6EAA6E;AAC7E,eAAO,MAAM,gBAAgB,EAAE,SAAS,cAAc,EAmGrD,CAAA;AAED,wDAAwD;AACxD,eAAO,MAAM,uBAAuB,EAAE,SAAS,oBAAoB,EAOlE,CAAA"}
|
|
@@ -0,0 +1,338 @@
|
|
|
1
|
+
// What ploaness refuses by name, whatever a manifest declares as its licence.
|
|
2
|
+
//
|
|
3
|
+
// The licence allowlist judges an npm package by the identifier its own manifest carries, and that is
|
|
4
|
+
// the wrong question for three families. A driver is permissively licensed while the only server it can
|
|
5
|
+
// reach is not (the MongoDB driver is Apache 2.0; the MongoDB server is SSPL). A package downloads a
|
|
6
|
+
// binary at install or first run under terms its manifest never mentions (puppeteer fetches Chrome for
|
|
7
|
+
// Testing). And a container image has no manifest at all, so nothing judged it: a compose file could pull
|
|
8
|
+
// MinIO or Redis 8 through a harness that refuses an AGPL npm package. Retired analyzers are also
|
|
9
|
+
// refused when the harness already owns their checks.
|
|
10
|
+
//
|
|
11
|
+
// Every entry names the reason and the replacement, because a refusal that stops a build without saying
|
|
12
|
+
// what to use instead sends the reader to the same search this table already did. Where a project turned
|
|
13
|
+
// non-permissive at a known release, the entry carries that floor and earlier releases are left to the
|
|
14
|
+
// licence gate. No project setting widens or narrows the list: a rule a project can edit is not a rule.
|
|
15
|
+
const MONGODB_REASON = 'the MongoDB server is SSPL, which is not an open-source licence, and this exists only to reach it';
|
|
16
|
+
const MONGODB_REPLACEMENT = 'the postgres image with @payloadcms/db-postgres';
|
|
17
|
+
const REDIS_REASON = 'Redis 7.4 onward is RSALv2, SSPLv1 or AGPLv3, none of which is a permissive open-source licence';
|
|
18
|
+
const REDIS_REPLACEMENT = 'valkey/valkey, which the redis and ioredis clients speak to unchanged';
|
|
19
|
+
const ELASTIC_REASON = 'Elastic binaries are Elastic License 2.0 from 7.11, and this exists only to reach them';
|
|
20
|
+
const ELASTIC_REPLACEMENT = 'opensearchproject/opensearch and opensearchproject/opensearch-dashboards with @opensearch-project/opensearch';
|
|
21
|
+
const MINIO_REASON = 'MinIO is AGPL and its community edition is archived, with no images and no security fixes';
|
|
22
|
+
const OBJECT_STORAGE_REPLACEMENT = 'rustfs/rustfs or chrislusf/seaweedfs';
|
|
23
|
+
const HASHICORP_REASON = 'HashiCorp relicensed to the Business Source License, which is not open source';
|
|
24
|
+
const HASHICORP_REPLACEMENT = 'openbao/openbao for Vault, ghcr.io/opentofu/opentofu for Terraform';
|
|
25
|
+
const PROPRIETARY_DATABASE_REASON = 'a proprietary database server, for which Payload has no adapter';
|
|
26
|
+
const POSTGRES_REPLACEMENT = 'the postgres image';
|
|
27
|
+
const GHOSTSCRIPT_REASON = 'Ghostscript is AGPL, and this is a thin wrapper around it';
|
|
28
|
+
const PDF_REPLACEMENT = 'pdfjs-dist with @napi-rs/canvas';
|
|
29
|
+
const NOTHING_REPLACEMENT = 'nothing; a Payload project has no place for it';
|
|
30
|
+
/** The image repositories ploaness refuses, in the order the report lists them. */
|
|
31
|
+
export const BLOCKED_IMAGES = [
|
|
32
|
+
{ repository: 'mongo', reason: MONGODB_REASON, replacement: MONGODB_REPLACEMENT },
|
|
33
|
+
{ repository: 'mongodb/*', reason: MONGODB_REASON, replacement: MONGODB_REPLACEMENT },
|
|
34
|
+
{ repository: 'redis', from: '7.4', reason: REDIS_REASON, replacement: REDIS_REPLACEMENT },
|
|
35
|
+
{ repository: 'redis/*', reason: REDIS_REASON, replacement: REDIS_REPLACEMENT },
|
|
36
|
+
{ repository: 'redislabs/*', reason: REDIS_REASON, replacement: REDIS_REPLACEMENT },
|
|
37
|
+
{
|
|
38
|
+
repository: 'elasticsearch',
|
|
39
|
+
from: '7.11',
|
|
40
|
+
reason: ELASTIC_REASON,
|
|
41
|
+
replacement: ELASTIC_REPLACEMENT,
|
|
42
|
+
},
|
|
43
|
+
{ repository: 'kibana', from: '7.11', reason: ELASTIC_REASON, replacement: ELASTIC_REPLACEMENT },
|
|
44
|
+
{
|
|
45
|
+
repository: 'logstash',
|
|
46
|
+
from: '7.11',
|
|
47
|
+
reason: ELASTIC_REASON,
|
|
48
|
+
replacement: ELASTIC_REPLACEMENT,
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
repository: 'docker.elastic.co/*',
|
|
52
|
+
from: '7.11',
|
|
53
|
+
reason: ELASTIC_REASON,
|
|
54
|
+
replacement: ELASTIC_REPLACEMENT,
|
|
55
|
+
},
|
|
56
|
+
{ repository: 'minio/*', reason: MINIO_REASON, replacement: OBJECT_STORAGE_REPLACEMENT },
|
|
57
|
+
{ repository: 'quay.io/minio/*', reason: MINIO_REASON, replacement: OBJECT_STORAGE_REPLACEMENT },
|
|
58
|
+
{ repository: 'pgsty/minio', reason: MINIO_REASON, replacement: OBJECT_STORAGE_REPLACEMENT },
|
|
59
|
+
{
|
|
60
|
+
repository: 'localstack/*',
|
|
61
|
+
reason: 'the LocalStack community edition is archived, and the unified image needs an account token and is free ' +
|
|
62
|
+
'only for non-commercial use',
|
|
63
|
+
replacement: 'rustfs/rustfs for S3 and motoserver/moto for other AWS APIs',
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
repository: 'gresau/localstack-persist',
|
|
67
|
+
reason: 'a repackaging of the archived LocalStack community edition',
|
|
68
|
+
replacement: 'rustfs/rustfs for S3 and motoserver/moto for other AWS APIs',
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
repository: 'cockroachdb/cockroach',
|
|
72
|
+
from: '24.3',
|
|
73
|
+
reason: 'CockroachDB 24.3 onward is under a proprietary licence with mandatory telemetry',
|
|
74
|
+
replacement: POSTGRES_REPLACEMENT,
|
|
75
|
+
},
|
|
76
|
+
{
|
|
77
|
+
repository: 'hashicorp/vault',
|
|
78
|
+
from: '1.15',
|
|
79
|
+
reason: HASHICORP_REASON,
|
|
80
|
+
replacement: HASHICORP_REPLACEMENT,
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
repository: 'hashicorp/consul',
|
|
84
|
+
from: '1.16',
|
|
85
|
+
reason: HASHICORP_REASON,
|
|
86
|
+
replacement: HASHICORP_REPLACEMENT,
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
repository: 'hashicorp/nomad',
|
|
90
|
+
from: '1.6',
|
|
91
|
+
reason: HASHICORP_REASON,
|
|
92
|
+
replacement: HASHICORP_REPLACEMENT,
|
|
93
|
+
},
|
|
94
|
+
{
|
|
95
|
+
repository: 'hashicorp/terraform',
|
|
96
|
+
from: '1.6',
|
|
97
|
+
reason: HASHICORP_REASON,
|
|
98
|
+
replacement: HASHICORP_REPLACEMENT,
|
|
99
|
+
},
|
|
100
|
+
{
|
|
101
|
+
repository: 'hashicorp/packer',
|
|
102
|
+
from: '1.10',
|
|
103
|
+
reason: HASHICORP_REASON,
|
|
104
|
+
replacement: HASHICORP_REPLACEMENT,
|
|
105
|
+
},
|
|
106
|
+
{
|
|
107
|
+
repository: 'redpandadata/*',
|
|
108
|
+
reason: 'Redpanda is under the Business Source License, which is not open source',
|
|
109
|
+
replacement: 'apache/kafka or nats',
|
|
110
|
+
},
|
|
111
|
+
{
|
|
112
|
+
repository: 'vectorized/*',
|
|
113
|
+
reason: 'Redpanda is under the Business Source License, which is not open source',
|
|
114
|
+
replacement: 'apache/kafka or nats',
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
repository: 'timescale/timescaledb',
|
|
118
|
+
allowedTag: /-oss(?:-|$)/,
|
|
119
|
+
reason: 'the default Timescale images carry Timescale License code, which is not open source',
|
|
120
|
+
replacement: 'a tag ending in -oss, or the postgres image',
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
repository: 'timescale/timescaledb-ha',
|
|
124
|
+
allowedTag: /-oss(?:-|$)/,
|
|
125
|
+
reason: 'the default Timescale images carry Timescale License code, which is not open source',
|
|
126
|
+
replacement: 'a tag ending in -oss, or the postgres image',
|
|
127
|
+
},
|
|
128
|
+
{
|
|
129
|
+
repository: 'getsentry/*',
|
|
130
|
+
from: '23.11',
|
|
131
|
+
reason: 'self-hosted Sentry is under the Functional Source License, which is not open source',
|
|
132
|
+
replacement: 'glitchtip/glitchtip, or Sentry as a service through the MIT @sentry SDKs',
|
|
133
|
+
},
|
|
134
|
+
{
|
|
135
|
+
repository: 'n8nio/*',
|
|
136
|
+
reason: 'n8n is under the Sustainable Use License, which is not open source',
|
|
137
|
+
replacement: NOTHING_REPLACEMENT,
|
|
138
|
+
},
|
|
139
|
+
{
|
|
140
|
+
repository: 'directus/directus',
|
|
141
|
+
reason: 'Directus is under the Business Source License, which is not open source',
|
|
142
|
+
replacement: 'Payload',
|
|
143
|
+
},
|
|
144
|
+
{
|
|
145
|
+
repository: 'mcr.microsoft.com/mssql/*',
|
|
146
|
+
reason: PROPRIETARY_DATABASE_REASON,
|
|
147
|
+
replacement: POSTGRES_REPLACEMENT,
|
|
148
|
+
},
|
|
149
|
+
{
|
|
150
|
+
repository: 'container-registry.oracle.com/database/*',
|
|
151
|
+
reason: PROPRIETARY_DATABASE_REASON,
|
|
152
|
+
replacement: POSTGRES_REPLACEMENT,
|
|
153
|
+
},
|
|
154
|
+
{
|
|
155
|
+
repository: 'gvenzl/oracle-*',
|
|
156
|
+
reason: PROPRIETARY_DATABASE_REASON,
|
|
157
|
+
replacement: POSTGRES_REPLACEMENT,
|
|
158
|
+
},
|
|
159
|
+
{
|
|
160
|
+
repository: 'ibmcom/db2',
|
|
161
|
+
reason: PROPRIETARY_DATABASE_REASON,
|
|
162
|
+
replacement: POSTGRES_REPLACEMENT,
|
|
163
|
+
},
|
|
164
|
+
{
|
|
165
|
+
repository: 'icr.io/db2_community/*',
|
|
166
|
+
reason: PROPRIETARY_DATABASE_REASON,
|
|
167
|
+
replacement: POSTGRES_REPLACEMENT,
|
|
168
|
+
},
|
|
169
|
+
{
|
|
170
|
+
repository: 'ghcr.io/apollographql/router',
|
|
171
|
+
reason: 'the Apollo Router is Elastic License 2.0, which is not open source',
|
|
172
|
+
replacement: '@graphql-hive/gateway or @graphql-mesh',
|
|
173
|
+
},
|
|
174
|
+
{
|
|
175
|
+
repository: 'bitnami/*',
|
|
176
|
+
reason: 'the Bitnami catalogue was deleted in 2025, so a tag here cannot be pulled reproducibly',
|
|
177
|
+
replacement: 'the upstream official image of the same service',
|
|
178
|
+
},
|
|
179
|
+
{
|
|
180
|
+
repository: 'bitnamilegacy/*',
|
|
181
|
+
reason: 'the Bitnami legacy images are frozen with unfixed vulnerabilities',
|
|
182
|
+
replacement: 'the upstream official image of the same service',
|
|
183
|
+
},
|
|
184
|
+
{
|
|
185
|
+
repository: 'bitnamisecure/*',
|
|
186
|
+
reason: 'the Bitnami secure images publish only a latest tag, so a pull cannot be pinned',
|
|
187
|
+
replacement: 'the upstream official image of the same service',
|
|
188
|
+
},
|
|
189
|
+
{
|
|
190
|
+
repository: 'dxflrs/garage',
|
|
191
|
+
reason: 'Garage is AGPL, and a permissively licensed object store exists',
|
|
192
|
+
replacement: OBJECT_STORAGE_REPLACEMENT,
|
|
193
|
+
},
|
|
194
|
+
{
|
|
195
|
+
repository: 'citusdata/citus',
|
|
196
|
+
reason: 'Citus is AGPL, and plain PostgreSQL serves a Payload project',
|
|
197
|
+
replacement: POSTGRES_REPLACEMENT,
|
|
198
|
+
},
|
|
199
|
+
{
|
|
200
|
+
repository: 'grafana/grafana',
|
|
201
|
+
reason: 'Grafana is AGPL, and a permissively licensed dashboard exists',
|
|
202
|
+
replacement: 'persesdev/perses',
|
|
203
|
+
},
|
|
204
|
+
{
|
|
205
|
+
repository: 'grafana/loki',
|
|
206
|
+
reason: 'Loki is AGPL, and a permissively licensed log store exists',
|
|
207
|
+
replacement: 'victoriametrics/victoria-logs',
|
|
208
|
+
},
|
|
209
|
+
{
|
|
210
|
+
repository: 'grafana/tempo',
|
|
211
|
+
reason: 'Tempo is AGPL, and a permissively licensed trace store exists',
|
|
212
|
+
replacement: 'jaegertracing/jaeger',
|
|
213
|
+
},
|
|
214
|
+
{
|
|
215
|
+
repository: 'grafana/mimir',
|
|
216
|
+
reason: 'Mimir is AGPL, and a permissively licensed metrics store exists',
|
|
217
|
+
replacement: 'prom/prometheus or victoriametrics/victoria-metrics',
|
|
218
|
+
},
|
|
219
|
+
{
|
|
220
|
+
repository: 'plausible/*',
|
|
221
|
+
reason: 'Plausible is AGPL, and a permissively licensed analytics service exists',
|
|
222
|
+
replacement: 'ghcr.io/umami-software/umami',
|
|
223
|
+
},
|
|
224
|
+
{
|
|
225
|
+
repository: 'metabase/metabase',
|
|
226
|
+
reason: 'Metabase is AGPL',
|
|
227
|
+
replacement: NOTHING_REPLACEMENT,
|
|
228
|
+
},
|
|
229
|
+
];
|
|
230
|
+
/** The npm packages ploaness refuses, in the order the report lists them. */
|
|
231
|
+
export const BLOCKED_PACKAGES = [
|
|
232
|
+
{
|
|
233
|
+
name: 'eslint-plugin-jsx-a11y',
|
|
234
|
+
reason: 'the retired JSX accessibility analyzer duplicates checks owned by the ploaness Oxlint gate',
|
|
235
|
+
replacement: 'the harness-owned oxlint gate; remove the legacy plugin dependency',
|
|
236
|
+
},
|
|
237
|
+
{
|
|
238
|
+
name: '@payloadcms/db-mongodb',
|
|
239
|
+
reason: MONGODB_REASON,
|
|
240
|
+
replacement: '@payloadcms/db-postgres',
|
|
241
|
+
},
|
|
242
|
+
{ name: 'mongodb', reason: MONGODB_REASON, replacement: '@payloadcms/db-postgres' },
|
|
243
|
+
{ name: 'mongoose', reason: MONGODB_REASON, replacement: '@payloadcms/db-postgres' },
|
|
244
|
+
{
|
|
245
|
+
name: 'mongodb-memory-server*',
|
|
246
|
+
reason: 'downloads the SSPL MongoDB server binary at install time',
|
|
247
|
+
replacement: '@payloadcms/db-postgres against the compose database',
|
|
248
|
+
},
|
|
249
|
+
{ name: '@mongodb-js/*', reason: MONGODB_REASON, replacement: '@payloadcms/db-postgres' },
|
|
250
|
+
{
|
|
251
|
+
name: 'mongodb-client-encryption',
|
|
252
|
+
reason: MONGODB_REASON,
|
|
253
|
+
replacement: '@payloadcms/db-postgres',
|
|
254
|
+
},
|
|
255
|
+
{
|
|
256
|
+
name: '@elastic/elasticsearch',
|
|
257
|
+
reason: ELASTIC_REASON,
|
|
258
|
+
replacement: '@opensearch-project/opensearch',
|
|
259
|
+
},
|
|
260
|
+
{
|
|
261
|
+
name: '@elastic/eui',
|
|
262
|
+
reason: 'Elastic UI is dual-licensed SSPL and Elastic License 2.0, neither of which is permissive',
|
|
263
|
+
replacement: '@payloadcms/ui',
|
|
264
|
+
},
|
|
265
|
+
{ name: 'elastic-apm-node', reason: ELASTIC_REASON, replacement: '@opentelemetry/sdk-node' },
|
|
266
|
+
{
|
|
267
|
+
name: 'puppeteer',
|
|
268
|
+
reason: 'downloads Chrome for Testing under Google terms, which are not open source',
|
|
269
|
+
replacement: 'playwright, or puppeteer-core pointed at the Chromium Playwright installs',
|
|
270
|
+
},
|
|
271
|
+
{ name: 'pdf2pic', reason: GHOSTSCRIPT_REASON, replacement: PDF_REPLACEMENT },
|
|
272
|
+
{ name: 'node-gs', reason: GHOSTSCRIPT_REASON, replacement: PDF_REPLACEMENT },
|
|
273
|
+
{ name: 'ghostscript4js', reason: GHOSTSCRIPT_REASON, replacement: PDF_REPLACEMENT },
|
|
274
|
+
{ name: 'mupdf', reason: 'MuPDF is AGPL', replacement: PDF_REPLACEMENT },
|
|
275
|
+
{
|
|
276
|
+
name: 'n8n',
|
|
277
|
+
reason: 'n8n is under the Sustainable Use License, which is not open source',
|
|
278
|
+
replacement: NOTHING_REPLACEMENT,
|
|
279
|
+
},
|
|
280
|
+
{
|
|
281
|
+
name: 'n8n-*',
|
|
282
|
+
reason: 'an n8n extension serves only the Sustainable Use License host',
|
|
283
|
+
replacement: NOTHING_REPLACEMENT,
|
|
284
|
+
},
|
|
285
|
+
{
|
|
286
|
+
name: 'directus',
|
|
287
|
+
reason: 'Directus is under the Business Source License, which is not open source',
|
|
288
|
+
replacement: 'payload',
|
|
289
|
+
},
|
|
290
|
+
{ name: 'mssql', reason: PROPRIETARY_DATABASE_REASON, replacement: 'pg' },
|
|
291
|
+
{ name: 'tedious', reason: PROPRIETARY_DATABASE_REASON, replacement: 'pg' },
|
|
292
|
+
{ name: 'oracledb', reason: PROPRIETARY_DATABASE_REASON, replacement: 'pg' },
|
|
293
|
+
{ name: 'ibm_db', reason: PROPRIETARY_DATABASE_REASON, replacement: 'pg' },
|
|
294
|
+
{
|
|
295
|
+
name: 'ua-parser-js',
|
|
296
|
+
from: '2.0.0',
|
|
297
|
+
reason: 'ua-parser-js 2 is AGPL with a paid exemption',
|
|
298
|
+
replacement: 'ua-parser-js 1, or bowser',
|
|
299
|
+
},
|
|
300
|
+
{
|
|
301
|
+
name: 'mapbox-gl',
|
|
302
|
+
from: '2.0.0',
|
|
303
|
+
reason: 'Mapbox GL JS 2 onward is under proprietary Mapbox terms',
|
|
304
|
+
replacement: 'maplibre-gl',
|
|
305
|
+
},
|
|
306
|
+
{
|
|
307
|
+
name: 'tinymce',
|
|
308
|
+
from: '7.0.0',
|
|
309
|
+
reason: 'TinyMCE 7 onward is GPL or commercial',
|
|
310
|
+
replacement: '@payloadcms/richtext-lexical',
|
|
311
|
+
},
|
|
312
|
+
{
|
|
313
|
+
name: '@ckeditor/*',
|
|
314
|
+
reason: 'CKEditor 5 is GPL or commercial',
|
|
315
|
+
replacement: '@payloadcms/richtext-lexical',
|
|
316
|
+
},
|
|
317
|
+
{
|
|
318
|
+
name: 'highcharts',
|
|
319
|
+
reason: 'Highcharts is under a proprietary licence',
|
|
320
|
+
replacement: 'chart.js or echarts',
|
|
321
|
+
},
|
|
322
|
+
{
|
|
323
|
+
name: '@apollo/gateway',
|
|
324
|
+
from: '2.0.0',
|
|
325
|
+
reason: 'Apollo Gateway 2 onward is Elastic License 2.0, which is not open source',
|
|
326
|
+
replacement: '@graphql-hive/gateway',
|
|
327
|
+
},
|
|
328
|
+
];
|
|
329
|
+
/** The system packages a Dockerfile may not install. */
|
|
330
|
+
export const BLOCKED_SYSTEM_PACKAGES = [
|
|
331
|
+
{ name: 'ghostscript', reason: 'Ghostscript is AGPL', replacement: PDF_REPLACEMENT },
|
|
332
|
+
{ name: 'mupdf', reason: 'MuPDF is AGPL', replacement: PDF_REPLACEMENT },
|
|
333
|
+
{ name: 'mupdf-tools', reason: 'MuPDF is AGPL', replacement: PDF_REPLACEMENT },
|
|
334
|
+
{ name: 'mongodb-org', reason: MONGODB_REASON, replacement: MONGODB_REPLACEMENT },
|
|
335
|
+
{ name: 'mongodb-org-server', reason: MONGODB_REASON, replacement: MONGODB_REPLACEMENT },
|
|
336
|
+
{ name: 'mongodb-mongosh', reason: MONGODB_REASON, replacement: MONGODB_REPLACEMENT },
|
|
337
|
+
];
|
|
338
|
+
//# sourceMappingURL=blocklist-entries.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"blocklist-entries.js","sourceRoot":"","sources":["../src/blocklist-entries.ts"],"names":[],"mappings":"AAAA,8EAA8E;AAC9E,EAAE;AACF,sGAAsG;AACtG,wGAAwG;AACxG,qGAAqG;AACrG,uGAAuG;AACvG,0GAA0G;AAC1G,kGAAkG;AAClG,sDAAsD;AACtD,EAAE;AACF,wGAAwG;AACxG,yGAAyG;AACzG,uGAAuG;AACvG,wGAAwG;AAkCxG,MAAM,cAAc,GAClB,mGAAmG,CAAA;AACrG,MAAM,mBAAmB,GAAW,iDAAiD,CAAA;AAErF,MAAM,YAAY,GAChB,iGAAiG,CAAA;AACnG,MAAM,iBAAiB,GACrB,uEAAuE,CAAA;AAEzE,MAAM,cAAc,GAClB,wFAAwF,CAAA;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AoC;IACtE,EAAE,IAAI,EAAE,aAAa,EAAE,MAAM,EAAE,qBAAqB,EAAE,WAAW,EAAE,eAAe,EAAE;IACpF,EAAE,IAAI,EAAE,OAAO,EAAE,MAAM,EAAE,eAAe,EAAE,WAAW,EAAE,eAAe,EAAE;IACxE,EAAE,IAAI,EAAE,aAAa,EAAE,MAAM,EAAE,eAAe,EAAE,WAAW,EAAE,eAAe,EAAE;IAC9E,EAAE,IAAI,EAAE,aAAa,EAAE,MAAM,EAAE,cAAc,EAAE,WAAW,EAAE,mBAAmB,EAAE;IACjF,EAAE,IAAI,EAAE,oBAAoB,EAAE,MAAM,EAAE,cAAc,EAAE,WAAW,EAAE,mBAAmB,EAAE;IACxF,EAAE,IAAI,EAAE,iBAAiB,EAAE,MAAM,EAAE,cAAc,EAAE,WAAW,EAAE,mBAAmB,EAAE;CACtF,CAAA"}
|
|
@@ -0,0 +1,91 @@
|
|
|
1
|
+
import { type DependencyStatus } from './dependency-freshness.js';
|
|
2
|
+
/** One refusal, ready to be printed beside the file that carries the subject. */
|
|
3
|
+
export interface Refusal {
|
|
4
|
+
/** The reference, the `name@version`, or the system package as written. */
|
|
5
|
+
readonly subject: string;
|
|
6
|
+
readonly reason: string;
|
|
7
|
+
readonly replacement: string;
|
|
8
|
+
}
|
|
9
|
+
/** An image reference split into the parts the rule reads. */
|
|
10
|
+
export interface ImageReference {
|
|
11
|
+
readonly raw: string;
|
|
12
|
+
/** The repository in the normalised form `blocklist-entries.ts` uses. */
|
|
13
|
+
readonly repository: string;
|
|
14
|
+
readonly tag: string | undefined;
|
|
15
|
+
readonly digest: string | undefined;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* Split an image reference as a Dockerfile, a workflow, or a compose model writes it.
|
|
19
|
+
* @param raw the reference, such as `docker.io/library/redis:7.4.1@sha256:...`.
|
|
20
|
+
* @returns the normalised repository, and the tag and digest when present.
|
|
21
|
+
*/
|
|
22
|
+
export declare const parseImageReference: (raw: string) => ImageReference;
|
|
23
|
+
/**
|
|
24
|
+
* Whether a reference may resolve to a different image tomorrow: no digest, and no tag or `latest`.
|
|
25
|
+
* @param raw the reference as written.
|
|
26
|
+
* @returns true when nothing in the reference pins what is pulled.
|
|
27
|
+
*/
|
|
28
|
+
export declare const isMutableImageReference: (raw: string) => boolean;
|
|
29
|
+
/**
|
|
30
|
+
* Whether an image reference names a refused repository at a refused tag.
|
|
31
|
+
* @param raw the reference as written.
|
|
32
|
+
* @returns the refusal, or undefined when the image is not one ploaness refuses.
|
|
33
|
+
*/
|
|
34
|
+
export declare const refuseImage: (raw: string) => Refusal | undefined;
|
|
35
|
+
/**
|
|
36
|
+
* Whether an installed package at a version is one ploaness refuses.
|
|
37
|
+
* @param name the package name.
|
|
38
|
+
* @param version the resolved version.
|
|
39
|
+
* @returns the refusal, or undefined when the package is not one ploaness refuses at that version.
|
|
40
|
+
*/
|
|
41
|
+
export declare const refusePackage: (name: string, version: string) => Refusal | undefined;
|
|
42
|
+
/**
|
|
43
|
+
* The refused system packages a Dockerfile installs.
|
|
44
|
+
* @param text the Dockerfile body.
|
|
45
|
+
* @returns one refusal per refused package, in file order.
|
|
46
|
+
*/
|
|
47
|
+
export declare const refuseSystemPackages: (text: string) => readonly Refusal[];
|
|
48
|
+
/** One package of the resolved set, at every version the install carries. */
|
|
49
|
+
export interface InstalledPackage {
|
|
50
|
+
readonly name: string;
|
|
51
|
+
readonly versions: readonly string[];
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* The resolved set as `pnpm licenses list --json` reports it: grouped by licence, each entry carrying
|
|
55
|
+
* the name and the versions installed.
|
|
56
|
+
* @param json the command's stdout.
|
|
57
|
+
* @returns every installed package, or undefined when the text is not that inventory.
|
|
58
|
+
*/
|
|
59
|
+
export declare const packagesInLicenseInventory: (json: string) => readonly InstalledPackage[] | undefined;
|
|
60
|
+
/**
|
|
61
|
+
* The refusals across an installed set.
|
|
62
|
+
* @param packages the resolved set.
|
|
63
|
+
* @returns one refusal per refused name and version, in inventory order.
|
|
64
|
+
*/
|
|
65
|
+
export declare const refuseInstalledPackages: (packages: readonly InstalledPackage[]) => readonly Refusal[];
|
|
66
|
+
/** A declared coordinate whose newest release the freshness bound may not demand. */
|
|
67
|
+
export interface RefusedLatest {
|
|
68
|
+
readonly status: DependencyStatus;
|
|
69
|
+
/** Why the newest release is out of reach, in the words the report prints. */
|
|
70
|
+
readonly note: string;
|
|
71
|
+
}
|
|
72
|
+
/** The statuses freshness measures, and the ones whose newest release it may not point at. */
|
|
73
|
+
export interface FreshnessScope {
|
|
74
|
+
readonly measurable: readonly DependencyStatus[];
|
|
75
|
+
readonly refused: readonly RefusedLatest[];
|
|
76
|
+
}
|
|
77
|
+
/**
|
|
78
|
+
* Split the declared coordinates into those freshness may measure and those whose newest release is
|
|
79
|
+
* refused, which freshness must not demand.
|
|
80
|
+
* @param statuses every declared coordinate with what the registry answered for it.
|
|
81
|
+
* @returns the measurable statuses, and the refused ones with the note the report prints.
|
|
82
|
+
*/
|
|
83
|
+
export declare const scopeFreshness: (statuses: readonly DependencyStatus[]) => FreshnessScope;
|
|
84
|
+
/**
|
|
85
|
+
* The refusals of a repository's own JSON summary, kept exported so the CLI prints the same words.
|
|
86
|
+
* @param refusal one refusal.
|
|
87
|
+
* @param location the file or inventory that carries the subject.
|
|
88
|
+
* @returns one finding line.
|
|
89
|
+
*/
|
|
90
|
+
export declare const describeRefusal: (refusal: Refusal, location: string) => string;
|
|
91
|
+
//# sourceMappingURL=blocklist.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"blocklist.d.ts","sourceRoot":"","sources":["../src/blocklist.ts"],"names":[],"mappings":"AAoBA,OAAO,EAAE,KAAK,gBAAgB,EAAoC,MAAM,2BAA2B,CAAA;AAInG,iFAAiF;AACjF,MAAM,WAAW,OAAO;IACtB,2EAA2E;IAC3E,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAA;IACxB,QAAQ,CAAC,MAAM,EAAE,MAA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