@eudiplo/cli 9.1.0-main.e4e29b5 → 9.1.0-main.e69fe20
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/commands/completion/action.js +3 -1
- package/dist/commands/completion/action.js.map +1 -1
- package/dist/commands/config/portability/migrations.spec.js +4 -2
- package/dist/commands/config/portability/migrations.spec.js.map +1 -1
- package/dist/commands/config/portability/upgrade.d.ts.map +1 -1
- package/dist/commands/config/portability/upgrade.js +6 -2
- package/dist/commands/config/portability/upgrade.js.map +1 -1
- package/dist/commands/config/validate/action.d.ts.map +1 -1
- package/dist/commands/config/validate/action.js +2 -1
- package/dist/commands/config/validate/action.js.map +1 -1
- package/dist/commands/config/validate/registry.json +10 -0
- package/dist/commands/init/action.d.ts.map +1 -1
- package/dist/commands/init/action.js +1 -11
- package/dist/commands/init/action.js.map +1 -1
- package/dist/commands/instance/action.d.ts +2 -0
- package/dist/commands/instance/action.d.ts.map +1 -1
- package/dist/commands/instance/action.js +68 -12
- package/dist/commands/instance/action.js.map +1 -1
- package/dist/commands/instance/index.d.ts.map +1 -1
- package/dist/commands/instance/index.js +21 -3
- package/dist/commands/instance/index.js.map +1 -1
- package/dist/commands/open/action.d.ts.map +1 -1
- package/dist/commands/open/action.js +13 -2
- package/dist/commands/open/action.js.map +1 -1
- package/dist/commands/status/action.d.ts.map +1 -1
- package/dist/commands/status/action.js +2 -1
- package/dist/commands/status/action.js.map +1 -1
- package/dist/index.js +5435 -773
- package/dist/services/api-auth.d.ts.map +1 -1
- package/dist/services/api-auth.js +3 -2
- package/dist/services/api-auth.js.map +1 -1
- package/dist/services/browser.d.ts.map +1 -1
- package/dist/services/browser.js +3 -2
- package/dist/services/browser.js.map +1 -1
- package/dist/services/cli-config.d.ts +41 -1
- package/dist/services/cli-config.d.ts.map +1 -1
- package/dist/services/cli-config.js +217 -29
- package/dist/services/cli-config.js.map +1 -1
- package/dist/services/diagnostics.d.ts.map +1 -1
- package/dist/services/diagnostics.js +9 -8
- package/dist/services/diagnostics.js.map +1 -1
- package/dist/services/instance-selection.d.ts.map +1 -1
- package/dist/services/instance-selection.js +2 -5
- package/dist/services/instance-selection.js.map +1 -1
- package/dist/services/url.d.ts +21 -0
- package/dist/services/url.d.ts.map +1 -0
- package/dist/services/url.js +61 -0
- package/dist/services/url.js.map +1 -0
- package/package.json +4 -3
- package/templates/demo-config/clients/presentation-test.json +1 -1
- package/templates/demo-config/clients/test.json +6 -2
- package/templates/demo-config/key-chains/attestation.json +2 -1
- package/templates/demo-config/key-chains/status-list.json +5 -4
- package/templates/docker-compose.yml +2 -2
- package/templates/schemas/ClientConfigFile.schema.json +134 -1
- package/templates/schemas/CreateClientDto.schema.json +5 -1
- package/templates/schemas/CreateFederationTrustAnchorDto.schema.json +82 -0
- package/templates/schemas/CreateRegistrarConfigDto.schema.json +29 -0
- package/templates/schemas/CreateTenantDto.schema.json +5 -1
- package/templates/schemas/FederationTrustAnchorConfigFile.schema.json +60 -0
- package/templates/schemas/ImportTenantDto.schema.json +12 -0
- package/templates/schemas/IssuanceConfig.schema.json +120 -2
- package/templates/schemas/IssuanceConfigFile.schema.json +1434 -1
- package/templates/schemas/KeyChainConfigFile.schema.json +505 -119
- package/templates/schemas/KeyChainCreateDto.schema.json +11 -1
- package/templates/schemas/KeyChainImportDto.schema.json +9 -0
- package/templates/schemas/KmsConfigDto.schema.json +186 -0
- package/templates/schemas/KmsConfigFile.schema.json +1026 -1
- package/templates/schemas/RegistrarConfigFile.schema.json +101 -1
- package/templates/schemas/RotationPolicyCreateDto.schema.json +1 -1
- package/templates/schemas/TenantConfigFile.schema.json +224 -68
- package/templates/schemas/UpdateClientDto.schema.json +5 -1
- package/templates/schemas/UpdateFederationTrustAnchorDto.schema.json +70 -0
- package/templates/schemas/UpdateStatusListConfigDto.schema.json +5 -5
- package/templates/schemas/UpdateTenantDto.schema.json +20 -0
- package/templates/schemas.manifest.json +3 -0
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/** Throws unless `value` is an absolute HTTP(S) URL, as config loading requires. */
|
|
2
|
+
export declare function validateHttpUrl(value: string, label: string): void;
|
|
3
|
+
/** True when a URL carries user info such as `user:password@`. */
|
|
4
|
+
export declare function hasUserInfo(value: string): boolean;
|
|
5
|
+
/**
|
|
6
|
+
* Hides user info such as `user:password@` in a URL before it is printed.
|
|
7
|
+
* URLs without user info are returned exactly as configured. The masked form
|
|
8
|
+
* is built from the parsed URL, so spellings the URL parser accepts without
|
|
9
|
+
* `//`, such as `https:user:secret@host`, are masked too. A value that is not
|
|
10
|
+
* a URL is hidden entirely if it could contain user info.
|
|
11
|
+
*/
|
|
12
|
+
export declare function redactUrl(value: string): string;
|
|
13
|
+
/** Returns the URL without user info, for handing it to another program. */
|
|
14
|
+
export declare function stripUserInfo(url: URL): URL;
|
|
15
|
+
/**
|
|
16
|
+
* Describes a failed request without the user info of its URL. Node's fetch
|
|
17
|
+
* repeats the full URL in some errors, for example "Request cannot be
|
|
18
|
+
* constructed from a URL that includes credentials: <url>".
|
|
19
|
+
*/
|
|
20
|
+
export declare function describeRequestError(error: unknown, url: URL): string;
|
|
21
|
+
//# sourceMappingURL=url.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"url.d.ts","sourceRoot":"","sources":["../../src/services/url.ts"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,wBAAgB,eAAe,CAAC,KAAK,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,IAAI,CASlE;AAED,kEAAkE;AAClE,wBAAgB,WAAW,CAAC,KAAK,EAAE,MAAM,GAAG,OAAO,CAOlD;AAED;;;;;;GAMG;AACH,wBAAgB,SAAS,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAa/C;AAED,4EAA4E;AAC5E,wBAAgB,aAAa,CAAC,GAAG,EAAE,GAAG,GAAG,GAAG,CAK3C;AAED;;;;GAIG;AACH,wBAAgB,oBAAoB,CAAC,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,GAAG,GAAG,MAAM,CAGrE"}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
/** Throws unless `value` is an absolute HTTP(S) URL, as config loading requires. */
|
|
2
|
+
export function validateHttpUrl(value, label) {
|
|
3
|
+
try {
|
|
4
|
+
const url = new URL(value);
|
|
5
|
+
if (url.protocol !== "http:" && url.protocol !== "https:") {
|
|
6
|
+
throw new Error("Unsupported URL protocol.");
|
|
7
|
+
}
|
|
8
|
+
}
|
|
9
|
+
catch {
|
|
10
|
+
throw new Error(`${label} must be an absolute HTTP(S) URL.`);
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
/** True when a URL carries user info such as `user:password@`. */
|
|
14
|
+
export function hasUserInfo(value) {
|
|
15
|
+
try {
|
|
16
|
+
const url = new URL(value);
|
|
17
|
+
return url.username !== "" || url.password !== "";
|
|
18
|
+
}
|
|
19
|
+
catch {
|
|
20
|
+
return false;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
/**
|
|
24
|
+
* Hides user info such as `user:password@` in a URL before it is printed.
|
|
25
|
+
* URLs without user info are returned exactly as configured. The masked form
|
|
26
|
+
* is built from the parsed URL, so spellings the URL parser accepts without
|
|
27
|
+
* `//`, such as `https:user:secret@host`, are masked too. A value that is not
|
|
28
|
+
* a URL is hidden entirely if it could contain user info.
|
|
29
|
+
*/
|
|
30
|
+
export function redactUrl(value) {
|
|
31
|
+
let url;
|
|
32
|
+
try {
|
|
33
|
+
url = new URL(value);
|
|
34
|
+
}
|
|
35
|
+
catch {
|
|
36
|
+
return value.includes("@") ? "***" : value;
|
|
37
|
+
}
|
|
38
|
+
if (url.username === "" && url.password === "") {
|
|
39
|
+
return value;
|
|
40
|
+
}
|
|
41
|
+
url.username = "***";
|
|
42
|
+
url.password = "";
|
|
43
|
+
return url.href;
|
|
44
|
+
}
|
|
45
|
+
/** Returns the URL without user info, for handing it to another program. */
|
|
46
|
+
export function stripUserInfo(url) {
|
|
47
|
+
const stripped = new URL(url.href);
|
|
48
|
+
stripped.username = "";
|
|
49
|
+
stripped.password = "";
|
|
50
|
+
return stripped;
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* Describes a failed request without the user info of its URL. Node's fetch
|
|
54
|
+
* repeats the full URL in some errors, for example "Request cannot be
|
|
55
|
+
* constructed from a URL that includes credentials: <url>".
|
|
56
|
+
*/
|
|
57
|
+
export function describeRequestError(error, url) {
|
|
58
|
+
const message = error instanceof Error ? error.message : String(error);
|
|
59
|
+
return message.replaceAll(url.href, redactUrl(url.href));
|
|
60
|
+
}
|
|
61
|
+
//# sourceMappingURL=url.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"url.js","sourceRoot":"","sources":["../../src/services/url.ts"],"names":[],"mappings":"AAAA,oFAAoF;AACpF,MAAM,UAAU,eAAe,CAAC,KAAa,EAAE,KAAa;IACxD,IAAI,CAAC;QACD,MAAM,GAAG,GAAG,IAAI,GAAG,CAAC,KAAK,CAAC,CAAC;QAC3B,IAAI,GAAG,CAAC,QAAQ,KAAK,OAAO,IAAI,GAAG,CAAC,QAAQ,KAAK,QAAQ,EAAE,CAAC;YACxD,MAAM,IAAI,KAAK,CAAC,2BAA2B,CAAC,CAAC;QACjD,CAAC;IACL,CAAC;IAAC,MAAM,CAAC;QACL,MAAM,IAAI,KAAK,CAAC,GAAG,KAAK,mCAAmC,CAAC,CAAC;IACjE,CAAC;AACL,CAAC;AAED,kEAAkE;AAClE,MAAM,UAAU,WAAW,CAAC,KAAa;IACrC,IAAI,CAAC;QACD,MAAM,GAAG,GAAG,IAAI,GAAG,CAAC,KAAK,CAAC,CAAC;QAC3B,OAAO,GAAG,CAAC,QAAQ,KAAK,EAAE,IAAI,GAAG,CAAC,QAAQ,KAAK,EAAE,CAAC;IACtD,CAAC;IAAC,MAAM,CAAC;QACL,OAAO,KAAK,CAAC;IACjB,CAAC;AACL,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,SAAS,CAAC,KAAa;IACnC,IAAI,GAAQ,CAAC;IACb,IAAI,CAAC;QACD,GAAG,GAAG,IAAI,GAAG,CAAC,KAAK,CAAC,CAAC;IACzB,CAAC;IAAC,MAAM,CAAC;QACL,OAAO,KAAK,CAAC,QAAQ,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC;IAC/C,CAAC;IACD,IAAI,GAAG,CAAC,QAAQ,KAAK,EAAE,IAAI,GAAG,CAAC,QAAQ,KAAK,EAAE,EAAE,CAAC;QAC7C,OAAO,KAAK,CAAC;IACjB,CAAC;IACD,GAAG,CAAC,QAAQ,GAAG,KAAK,CAAC;IACrB,GAAG,CAAC,QAAQ,GAAG,EAAE,CAAC;IAClB,OAAO,GAAG,CAAC,IAAI,CAAC;AACpB,CAAC;AAED,4EAA4E;AAC5E,MAAM,UAAU,aAAa,CAAC,GAAQ;IAClC,MAAM,QAAQ,GAAG,IAAI,GAAG,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC;IACnC,QAAQ,CAAC,QAAQ,GAAG,EAAE,CAAC;IACvB,QAAQ,CAAC,QAAQ,GAAG,EAAE,CAAC;IACvB,OAAO,QAAQ,CAAC;AACpB,CAAC;AAED;;;;GAIG;AACH,MAAM,UAAU,oBAAoB,CAAC,KAAc,EAAE,GAAQ;IACzD,MAAM,OAAO,GAAG,KAAK,YAAY,KAAK,CAAC,CAAC,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,CAAC,MAAM,CAAC,KAAK,CAAC,CAAC;IACvE,OAAO,OAAO,CAAC,UAAU,CAAC,GAAG,CAAC,IAAI,EAAE,SAAS,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC;AAC7D,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@eudiplo/cli",
|
|
3
|
-
"version": "9.1.0-main.
|
|
3
|
+
"version": "9.1.0-main.e69fe20",
|
|
4
4
|
"description": "Deployment-aware command line tools for EUDIPLO",
|
|
5
5
|
"private": false,
|
|
6
6
|
"type": "module",
|
|
@@ -15,11 +15,12 @@
|
|
|
15
15
|
"scripts": {
|
|
16
16
|
"assets:sync": "node scripts/sync-cli-assets.cjs",
|
|
17
17
|
"assets:check": "node scripts/check-cli-assets.cjs",
|
|
18
|
+
"build:deps": "pnpm --silent --filter \"@eudiplo/cli^...\" build",
|
|
18
19
|
"build": "pnpm assets:sync && pnpm assets:check && tsc -p tsconfig.json",
|
|
19
20
|
"build:publish": "pnpm build && esbuild src/index.ts --bundle --platform=node --format=esm --target=node22.12 --alias:jsonc-parser=jsonc-parser/lib/esm/main.js --outfile=dist/index.js",
|
|
20
21
|
"build:sea:bundle": "pnpm assets:sync && pnpm assets:check && esbuild src/index.ts --bundle --platform=node --format=esm --target=node22.12 --alias:jsonc-parser=jsonc-parser/lib/esm/main.js --outfile=dist-sea/index.js",
|
|
21
22
|
"build:sea": "node scripts/build-cli-sea.mjs",
|
|
22
|
-
"dev": "tsx src/index.ts",
|
|
23
|
+
"dev": "pnpm -s build:deps && tsx src/index.ts",
|
|
23
24
|
"test": "vitest run --root ../.. --project cli",
|
|
24
25
|
"lint": "biome lint .",
|
|
25
26
|
"format": "biome format --write .",
|
|
@@ -64,6 +65,6 @@
|
|
|
64
65
|
"esbuild": "^0.28.2",
|
|
65
66
|
"tsx": "^4.23.15",
|
|
66
67
|
"typescript": "^7.0.2",
|
|
67
|
-
"vitest": "5.0.
|
|
68
|
+
"vitest": "5.0.4"
|
|
68
69
|
}
|
|
69
70
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
{
|
|
2
|
-
"$schema": "https://eudiplo.dev/schemas/
|
|
2
|
+
"$schema": "https://eudiplo.dev/schemas/v2/ClientConfigFile.schema.json",
|
|
3
3
|
"metadata": {
|
|
4
4
|
"generation": 1
|
|
5
5
|
},
|
|
@@ -13,7 +13,11 @@
|
|
|
13
13
|
"issuance:manage",
|
|
14
14
|
"presentation:request",
|
|
15
15
|
"presentation:manage",
|
|
16
|
-
"registrar:manage"
|
|
16
|
+
"registrar:manage",
|
|
17
|
+
"sessions:read",
|
|
18
|
+
"credentials:status",
|
|
19
|
+
"audit:read",
|
|
20
|
+
"keys:manage"
|
|
17
21
|
]
|
|
18
22
|
}
|
|
19
23
|
}
|
|
@@ -11,17 +11,18 @@
|
|
|
11
11
|
"type": "private-jwk",
|
|
12
12
|
"jwk": {
|
|
13
13
|
"crv": "P-256",
|
|
14
|
-
"d": "
|
|
14
|
+
"d": "iAUEObUwUI-QDXsFYH9SLm7D-yuEUsOD73YG_jBgLGk",
|
|
15
15
|
"kty": "EC",
|
|
16
|
-
"x": "
|
|
17
|
-
"y": "
|
|
16
|
+
"x": "sSdNHYiCOK0E8lNE9rUQLUN3MbVeDnxjRwVwRiI9BqY",
|
|
17
|
+
"y": "xRP83r38x_MYGsteGhUW25Q0XVXA-ZRXlP38a8URPDg",
|
|
18
18
|
"alg": "ES256"
|
|
19
19
|
}
|
|
20
20
|
},
|
|
21
21
|
"kmsProvider": "db",
|
|
22
22
|
"rotationPolicy": {
|
|
23
23
|
"certValidityDays": 30,
|
|
24
|
-
"enabled": true
|
|
24
|
+
"enabled": true,
|
|
25
|
+
"intervalDays": 20
|
|
25
26
|
}
|
|
26
27
|
}
|
|
27
28
|
}
|
|
@@ -89,7 +89,7 @@ services:
|
|
|
89
89
|
- eudiplo-network
|
|
90
90
|
|
|
91
91
|
rustfs:
|
|
92
|
-
image: rustfs/rustfs:1.0.
|
|
92
|
+
image: rustfs/rustfs:1.0.1
|
|
93
93
|
restart: always
|
|
94
94
|
profiles: ['s3', 'standard', 'full']
|
|
95
95
|
ports:
|
|
@@ -114,7 +114,7 @@ services:
|
|
|
114
114
|
|
|
115
115
|
# S3 bucket initialization using the AWS CLI
|
|
116
116
|
rustfs-init:
|
|
117
|
-
image: amazon/aws-cli:2.37.
|
|
117
|
+
image: amazon/aws-cli:2.37.10
|
|
118
118
|
profiles: ['s3', 'standard', 'full']
|
|
119
119
|
depends_on:
|
|
120
120
|
rustfs:
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"properties": {
|
|
10
10
|
"$schema": {
|
|
11
11
|
"type": "string",
|
|
12
|
-
"const": "https://eudiplo.dev/schemas/
|
|
12
|
+
"const": "https://eudiplo.dev/schemas/v2/ClientConfigFile.schema.json"
|
|
13
13
|
},
|
|
14
14
|
"metadata": {
|
|
15
15
|
"type": "object",
|
|
@@ -55,6 +55,139 @@
|
|
|
55
55
|
"spec"
|
|
56
56
|
],
|
|
57
57
|
"additionalProperties": false
|
|
58
|
+
},
|
|
59
|
+
{
|
|
60
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
61
|
+
"$id": "https://eudiplo.dev/schemas/v1/ClientConfigFile.schema.json",
|
|
62
|
+
"title": "ClientConfigFile",
|
|
63
|
+
"type": "object",
|
|
64
|
+
"properties": {
|
|
65
|
+
"$schema": {
|
|
66
|
+
"type": "string",
|
|
67
|
+
"const": "https://eudiplo.dev/schemas/v1/ClientConfigFile.schema.json"
|
|
68
|
+
},
|
|
69
|
+
"metadata": {
|
|
70
|
+
"type": "object",
|
|
71
|
+
"properties": {
|
|
72
|
+
"generation": {
|
|
73
|
+
"type": "integer",
|
|
74
|
+
"minimum": 1,
|
|
75
|
+
"description": "Monotonically increasing configuration generation."
|
|
76
|
+
},
|
|
77
|
+
"ownership": {
|
|
78
|
+
"type": "string",
|
|
79
|
+
"enum": [
|
|
80
|
+
"unmanaged",
|
|
81
|
+
"file-managed"
|
|
82
|
+
],
|
|
83
|
+
"description": "Requested ownership recorded when the document is applied."
|
|
84
|
+
}
|
|
85
|
+
},
|
|
86
|
+
"additionalProperties": false
|
|
87
|
+
},
|
|
88
|
+
"spec": {
|
|
89
|
+
"allOf": [
|
|
90
|
+
{
|
|
91
|
+
"$ref": "#/$defs/CreateClientDto"
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
"type": "object",
|
|
95
|
+
"required": [
|
|
96
|
+
"clientId"
|
|
97
|
+
],
|
|
98
|
+
"properties": {
|
|
99
|
+
"clientId": {
|
|
100
|
+
"type": "string",
|
|
101
|
+
"minLength": 1
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
]
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
"required": [
|
|
109
|
+
"$schema",
|
|
110
|
+
"spec"
|
|
111
|
+
],
|
|
112
|
+
"additionalProperties": false,
|
|
113
|
+
"$defs": {
|
|
114
|
+
"CreateClientDto": {
|
|
115
|
+
"type": "object",
|
|
116
|
+
"properties": {
|
|
117
|
+
"clientId": {
|
|
118
|
+
"type": "string",
|
|
119
|
+
"minLength": 1,
|
|
120
|
+
"pattern": "^[A-Za-z0-9._:-]+$",
|
|
121
|
+
"description": "Unique client identifier."
|
|
122
|
+
},
|
|
123
|
+
"secret": {
|
|
124
|
+
"description": "Optional client secret for confidential clients.",
|
|
125
|
+
"type": "string",
|
|
126
|
+
"minLength": 1
|
|
127
|
+
},
|
|
128
|
+
"description": {
|
|
129
|
+
"description": "Optional human-readable client description.",
|
|
130
|
+
"type": "string",
|
|
131
|
+
"minLength": 1
|
|
132
|
+
},
|
|
133
|
+
"roles": {
|
|
134
|
+
"minItems": 1,
|
|
135
|
+
"type": "array",
|
|
136
|
+
"items": {
|
|
137
|
+
"type": "string",
|
|
138
|
+
"enum": [
|
|
139
|
+
"presentation:manage",
|
|
140
|
+
"presentation:request",
|
|
141
|
+
"issuance:manage",
|
|
142
|
+
"issuance:offer",
|
|
143
|
+
"clients:manage",
|
|
144
|
+
"users:manage",
|
|
145
|
+
"tenants:manage",
|
|
146
|
+
"tenant:admin",
|
|
147
|
+
"registrar:manage"
|
|
148
|
+
]
|
|
149
|
+
},
|
|
150
|
+
"description": "Roles assigned to the client. At least one role is required."
|
|
151
|
+
},
|
|
152
|
+
"allowedPresentationConfigs": {
|
|
153
|
+
"description": "Optional allow-list of presentation config ids this client can use.",
|
|
154
|
+
"anyOf": [
|
|
155
|
+
{
|
|
156
|
+
"type": "array",
|
|
157
|
+
"items": {
|
|
158
|
+
"type": "string",
|
|
159
|
+
"minLength": 1
|
|
160
|
+
}
|
|
161
|
+
},
|
|
162
|
+
{
|
|
163
|
+
"type": "null"
|
|
164
|
+
}
|
|
165
|
+
]
|
|
166
|
+
},
|
|
167
|
+
"allowedIssuanceConfigs": {
|
|
168
|
+
"description": "Optional allow-list of issuance config ids this client can use.",
|
|
169
|
+
"anyOf": [
|
|
170
|
+
{
|
|
171
|
+
"type": "array",
|
|
172
|
+
"items": {
|
|
173
|
+
"type": "string",
|
|
174
|
+
"minLength": 1
|
|
175
|
+
}
|
|
176
|
+
},
|
|
177
|
+
{
|
|
178
|
+
"type": "null"
|
|
179
|
+
}
|
|
180
|
+
]
|
|
181
|
+
}
|
|
182
|
+
},
|
|
183
|
+
"required": [
|
|
184
|
+
"clientId",
|
|
185
|
+
"roles"
|
|
186
|
+
],
|
|
187
|
+
"additionalProperties": false,
|
|
188
|
+
"title": "CreateClientDto"
|
|
189
|
+
}
|
|
190
|
+
}
|
|
58
191
|
}
|
|
59
192
|
]
|
|
60
193
|
}
|
|
@@ -32,7 +32,11 @@
|
|
|
32
32
|
"users:manage",
|
|
33
33
|
"tenants:manage",
|
|
34
34
|
"tenant:admin",
|
|
35
|
-
"registrar:manage"
|
|
35
|
+
"registrar:manage",
|
|
36
|
+
"audit:read",
|
|
37
|
+
"sessions:read",
|
|
38
|
+
"credentials:status",
|
|
39
|
+
"keys:manage"
|
|
36
40
|
]
|
|
37
41
|
},
|
|
38
42
|
"description": "Roles assigned to the client. At least one role is required."
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"type": "object",
|
|
4
|
+
"properties": {
|
|
5
|
+
"id": {
|
|
6
|
+
"type": "string",
|
|
7
|
+
"minLength": 1,
|
|
8
|
+
"maxLength": 255,
|
|
9
|
+
"pattern": "^[A-Za-z0-9._-]+$",
|
|
10
|
+
"description": "Unique identifier of the trust anchor in the tenant."
|
|
11
|
+
},
|
|
12
|
+
"entityId": {
|
|
13
|
+
"type": "string",
|
|
14
|
+
"minLength": 1,
|
|
15
|
+
"maxLength": 2048,
|
|
16
|
+
"description": "Entity identifier of the trust anchor, exactly as configured in `federation.trustAnchors` and DCQL `openid_federation` values."
|
|
17
|
+
},
|
|
18
|
+
"description": {
|
|
19
|
+
"anyOf": [
|
|
20
|
+
{
|
|
21
|
+
"type": "string",
|
|
22
|
+
"minLength": 1,
|
|
23
|
+
"maxLength": 1000
|
|
24
|
+
},
|
|
25
|
+
{
|
|
26
|
+
"type": "null"
|
|
27
|
+
}
|
|
28
|
+
],
|
|
29
|
+
"description": "Optional description of the trust anchor."
|
|
30
|
+
},
|
|
31
|
+
"jwks": {
|
|
32
|
+
"type": "object",
|
|
33
|
+
"properties": {
|
|
34
|
+
"keys": {
|
|
35
|
+
"minItems": 1,
|
|
36
|
+
"maxItems": 20,
|
|
37
|
+
"type": "array",
|
|
38
|
+
"items": {
|
|
39
|
+
"type": "object",
|
|
40
|
+
"properties": {
|
|
41
|
+
"kty": {
|
|
42
|
+
"type": "string",
|
|
43
|
+
"enum": [
|
|
44
|
+
"EC",
|
|
45
|
+
"RSA",
|
|
46
|
+
"OKP"
|
|
47
|
+
],
|
|
48
|
+
"description": "Key type of the public federation key."
|
|
49
|
+
},
|
|
50
|
+
"kid": {
|
|
51
|
+
"type": "string",
|
|
52
|
+
"minLength": 1,
|
|
53
|
+
"maxLength": 256,
|
|
54
|
+
"description": "Key ID. Federation statements name their signing key with `kid`."
|
|
55
|
+
}
|
|
56
|
+
},
|
|
57
|
+
"required": [
|
|
58
|
+
"kty",
|
|
59
|
+
"kid"
|
|
60
|
+
],
|
|
61
|
+
"additionalProperties": {},
|
|
62
|
+
"description": "Public federation key of the trust anchor as a JWK."
|
|
63
|
+
},
|
|
64
|
+
"description": "The trust anchor's federation keys."
|
|
65
|
+
}
|
|
66
|
+
},
|
|
67
|
+
"required": [
|
|
68
|
+
"keys"
|
|
69
|
+
],
|
|
70
|
+
"additionalProperties": false,
|
|
71
|
+
"description": "JWK set with the federation keys of the trust anchor, obtained out of band (OpenID Federation 1.0 Section 10.2)."
|
|
72
|
+
}
|
|
73
|
+
},
|
|
74
|
+
"required": [
|
|
75
|
+
"id",
|
|
76
|
+
"entityId",
|
|
77
|
+
"jwks"
|
|
78
|
+
],
|
|
79
|
+
"additionalProperties": false,
|
|
80
|
+
"$id": "./CreateFederationTrustAnchorDto.schema.json",
|
|
81
|
+
"title": "CreateFederationTrustAnchorDto"
|
|
82
|
+
}
|
|
@@ -46,6 +46,35 @@
|
|
|
46
46
|
"type": "null"
|
|
47
47
|
}
|
|
48
48
|
]
|
|
49
|
+
},
|
|
50
|
+
"relyingPartyContact": {
|
|
51
|
+
"description": "Contact of the relying party, sent when EUDIPLO registers the relying party at the registrar. The registrar needs at least one contact value to issue access certificates. A relying party that is already registered keeps its contact.",
|
|
52
|
+
"anyOf": [
|
|
53
|
+
{
|
|
54
|
+
"type": "object",
|
|
55
|
+
"properties": {
|
|
56
|
+
"supportUri": {
|
|
57
|
+
"description": "https URL where the relying party can be contacted.",
|
|
58
|
+
"type": "string",
|
|
59
|
+
"format": "uri"
|
|
60
|
+
},
|
|
61
|
+
"email": {
|
|
62
|
+
"description": "Email address of the relying party.",
|
|
63
|
+
"type": "string",
|
|
64
|
+
"pattern": "^[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\\.[A-Za-z]{2,}$"
|
|
65
|
+
},
|
|
66
|
+
"phone": {
|
|
67
|
+
"description": "Phone number of the relying party.",
|
|
68
|
+
"type": "string",
|
|
69
|
+
"pattern": "^[+0-9()\\-\\s]{5,40}$"
|
|
70
|
+
}
|
|
71
|
+
},
|
|
72
|
+
"additionalProperties": false
|
|
73
|
+
},
|
|
74
|
+
{
|
|
75
|
+
"type": "null"
|
|
76
|
+
}
|
|
77
|
+
]
|
|
49
78
|
}
|
|
50
79
|
},
|
|
51
80
|
"required": [
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "./FederationTrustAnchorConfigFile.schema.json",
|
|
4
|
+
"title": "FederationTrustAnchorConfigFile",
|
|
5
|
+
"description": "Configuration file identified by its $schema URL.",
|
|
6
|
+
"oneOf": [
|
|
7
|
+
{
|
|
8
|
+
"type": "object",
|
|
9
|
+
"properties": {
|
|
10
|
+
"$schema": {
|
|
11
|
+
"type": "string",
|
|
12
|
+
"const": "https://eudiplo.dev/schemas/v1/FederationTrustAnchorConfigFile.schema.json"
|
|
13
|
+
},
|
|
14
|
+
"metadata": {
|
|
15
|
+
"type": "object",
|
|
16
|
+
"properties": {
|
|
17
|
+
"generation": {
|
|
18
|
+
"type": "integer",
|
|
19
|
+
"minimum": 1,
|
|
20
|
+
"description": "Monotonically increasing configuration generation."
|
|
21
|
+
},
|
|
22
|
+
"ownership": {
|
|
23
|
+
"type": "string",
|
|
24
|
+
"enum": [
|
|
25
|
+
"unmanaged",
|
|
26
|
+
"file-managed"
|
|
27
|
+
],
|
|
28
|
+
"description": "Requested ownership recorded when the document is applied."
|
|
29
|
+
}
|
|
30
|
+
},
|
|
31
|
+
"additionalProperties": false
|
|
32
|
+
},
|
|
33
|
+
"spec": {
|
|
34
|
+
"allOf": [
|
|
35
|
+
{
|
|
36
|
+
"$ref": "./CreateFederationTrustAnchorDto.schema.json"
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
"type": "object",
|
|
40
|
+
"required": [
|
|
41
|
+
"id"
|
|
42
|
+
],
|
|
43
|
+
"properties": {
|
|
44
|
+
"id": {
|
|
45
|
+
"type": "string",
|
|
46
|
+
"minLength": 1
|
|
47
|
+
}
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
]
|
|
51
|
+
}
|
|
52
|
+
},
|
|
53
|
+
"required": [
|
|
54
|
+
"$schema",
|
|
55
|
+
"spec"
|
|
56
|
+
],
|
|
57
|
+
"additionalProperties": false
|
|
58
|
+
}
|
|
59
|
+
]
|
|
60
|
+
}
|
|
@@ -81,6 +81,18 @@
|
|
|
81
81
|
}
|
|
82
82
|
},
|
|
83
83
|
"additionalProperties": false
|
|
84
|
+
},
|
|
85
|
+
"defaultKeyChains": {
|
|
86
|
+
"type": "object",
|
|
87
|
+
"properties": {
|
|
88
|
+
"access": {
|
|
89
|
+
"description": "ID of the access key chain used where no configuration names one: presentation requests of configurations without accessKeyChainId and the signed issuer metadata. Without it, EUDIPLO picks one of the tenant's access key chains by rule.",
|
|
90
|
+
"type": "string",
|
|
91
|
+
"minLength": 1
|
|
92
|
+
}
|
|
93
|
+
},
|
|
94
|
+
"additionalProperties": false,
|
|
95
|
+
"description": "The tenant's key chain per usage type, used where no configuration names one. A usage type without an entry uses a key chain picked by rule."
|
|
84
96
|
}
|
|
85
97
|
},
|
|
86
98
|
"required": [
|