@idp.global/interfaces 21.0.0 → 23.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/changelog.md +22 -0
- package/dist_ts/00_commitinfo_data.js +1 -1
- package/dist_ts/request/admin.d.ts +103 -16
- package/package.json +1 -1
- package/ts/00_commitinfo_data.ts +1 -1
- package/ts/request/admin.ts +123 -16
package/changelog.md
CHANGED
|
@@ -1,5 +1,23 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## 2026-07-18 - 23.0.0
|
|
4
|
+
|
|
5
|
+
### Breaking Changes
|
|
6
|
+
|
|
7
|
+
- require two-step OIDC signing-key rotation approvals (admin)
|
|
8
|
+
- Require operationId for rotateOidcSigningKey requests and return rotation status metadata.
|
|
9
|
+
- Add approveOidcSigningKeyRotation request contract with expected active key validation.
|
|
10
|
+
- Expose completion-only rotation results such as approvedAt, resultingActiveKid, and retiringKids.
|
|
11
|
+
|
|
12
|
+
## 2026-07-18 - 22.0.0
|
|
13
|
+
|
|
14
|
+
### Breaking Changes
|
|
15
|
+
|
|
16
|
+
- require encrypted delivery envelopes for confidential app secrets (admin)
|
|
17
|
+
- Require confidential global app creation and credential regeneration to provide an operationId and RSA-OAEP-256 public key.
|
|
18
|
+
- Replace plaintext clientSecret responses with durable encrypted secretDelivery envelopes.
|
|
19
|
+
- Add acknowledgeAppSecretDelivery request to close pending deliveries after ciphertext verification.
|
|
20
|
+
|
|
3
21
|
## 2026-07-18 - 21.0.0
|
|
4
22
|
|
|
5
23
|
### Breaking Changes
|
|
@@ -20,6 +38,10 @@
|
|
|
20
38
|
|
|
21
39
|
### Breaking Changes
|
|
22
40
|
|
|
41
|
+
- require operation-bound encrypted delivery for confidential OIDC client secrets
|
|
42
|
+
- Confidential global-App creation and client-secret rotation now require a caller-stable operation ID plus a canonical RSA-OAEP-256 delivery public key.
|
|
43
|
+
- Responses return a durable encrypted delivery envelope instead of plaintext secret material.
|
|
44
|
+
- Add an explicit acknowledgement request that irreversibly closes delivery after the caller verifies the ciphertext hash.
|
|
23
45
|
- require an authenticated password change to carry the caller's JWT in
|
|
24
46
|
addition to the current password; recovery-token password resets remain a
|
|
25
47
|
separate mutually exclusive request shape
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
*/
|
|
4
4
|
export const commitinfo = {
|
|
5
5
|
name: '@idp.global/interfaces',
|
|
6
|
-
version: '
|
|
6
|
+
version: '23.0.0',
|
|
7
7
|
description: 'Shared TypeScript interfaces and TypedRequest contracts for the idp.global ecosystem.'
|
|
8
8
|
};
|
|
9
9
|
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiMDBfY29tbWl0aW5mb19kYXRhLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vdHMvMDBfY29tbWl0aW5mb19kYXRhLnRzIl0sIm5hbWVzIjpbXSwibWFwcGluZ3MiOiJBQUFBOztHQUVHO0FBQ0gsTUFBTSxDQUFDLE1BQU0sVUFBVSxHQUFHO0lBQ3hCLElBQUksRUFBRSx3QkFBd0I7SUFDOUIsT0FBTyxFQUFFLFFBQVE7SUFDakIsV0FBVyxFQUFFLHVGQUF1RjtDQUNyRyxDQUFBIn0=
|
|
@@ -1,5 +1,54 @@
|
|
|
1
1
|
import * as plugins from '../plugins.js';
|
|
2
2
|
import * as dto from '../dto/index.js';
|
|
3
|
+
export type TSecretDeliveryAlgorithm = 'RSA-OAEP-256';
|
|
4
|
+
/** Caller-held RSA public key used to seal one-time secret material. */
|
|
5
|
+
export interface ISecretDeliveryRequest {
|
|
6
|
+
algorithm: TSecretDeliveryAlgorithm;
|
|
7
|
+
/** Canonical DER SubjectPublicKeyInfo encoded as standard padded base64. */
|
|
8
|
+
publicKeySpkiBase64: string;
|
|
9
|
+
}
|
|
10
|
+
/**
|
|
11
|
+
* Durable delivery receipt. Pending envelopes can be retried byte-for-byte
|
|
12
|
+
* until the caller acknowledges their ciphertext hash.
|
|
13
|
+
*/
|
|
14
|
+
export type TSecretDeliveryEnvelope = {
|
|
15
|
+
operationId: string;
|
|
16
|
+
algorithm: TSecretDeliveryAlgorithm;
|
|
17
|
+
publicKeySha256: string;
|
|
18
|
+
ciphertextSha256: string;
|
|
19
|
+
createdAt: number;
|
|
20
|
+
} & ({
|
|
21
|
+
status: 'pending';
|
|
22
|
+
ciphertextBase64: string;
|
|
23
|
+
acknowledgedAt?: never;
|
|
24
|
+
} | {
|
|
25
|
+
status: 'acknowledged';
|
|
26
|
+
ciphertextBase64?: never;
|
|
27
|
+
acknowledgedAt: number;
|
|
28
|
+
});
|
|
29
|
+
type TCreateGlobalAppBaseRequest = {
|
|
30
|
+
jwt: string;
|
|
31
|
+
name: string;
|
|
32
|
+
description: string;
|
|
33
|
+
logoUrl: string;
|
|
34
|
+
appUrl: string;
|
|
35
|
+
category: string;
|
|
36
|
+
redirectUris: string[];
|
|
37
|
+
postLogoutRedirectUris: string[];
|
|
38
|
+
allowedScopes: string[];
|
|
39
|
+
grantTypes: dto.IGlobalAppDto['data']['oauthCredentials']['grantTypes'];
|
|
40
|
+
oidcSettings: dto.IGlobalAppDto['data']['oidcSettings'];
|
|
41
|
+
};
|
|
42
|
+
export type TCreateGlobalAppRequest = TCreateGlobalAppBaseRequest & ({
|
|
43
|
+
clientType: 'public';
|
|
44
|
+
operationId?: never;
|
|
45
|
+
secretDelivery?: never;
|
|
46
|
+
} | {
|
|
47
|
+
clientType: 'confidential';
|
|
48
|
+
/** Caller-stable idempotency key for creation and secret delivery. */
|
|
49
|
+
operationId: string;
|
|
50
|
+
secretDelivery: ISecretDeliveryRequest;
|
|
51
|
+
});
|
|
3
52
|
/**
|
|
4
53
|
* Check if the current user is a global admin
|
|
5
54
|
*/
|
|
@@ -32,23 +81,10 @@ export interface IReq_GetGlobalAppStats extends plugins.typedRequestInterfaces.i
|
|
|
32
81
|
*/
|
|
33
82
|
export interface IReq_CreateGlobalApp extends plugins.typedRequestInterfaces.implementsTR<plugins.typedRequestInterfaces.ITypedRequest, IReq_CreateGlobalApp> {
|
|
34
83
|
method: 'createGlobalApp';
|
|
35
|
-
request:
|
|
36
|
-
jwt: string;
|
|
37
|
-
name: string;
|
|
38
|
-
description: string;
|
|
39
|
-
logoUrl: string;
|
|
40
|
-
appUrl: string;
|
|
41
|
-
category: string;
|
|
42
|
-
clientType: dto.IGlobalAppDto['data']['oauthCredentials']['clientType'];
|
|
43
|
-
redirectUris: string[];
|
|
44
|
-
postLogoutRedirectUris: string[];
|
|
45
|
-
allowedScopes: string[];
|
|
46
|
-
grantTypes: dto.IGlobalAppDto['data']['oauthCredentials']['grantTypes'];
|
|
47
|
-
oidcSettings: dto.IGlobalAppDto['data']['oidcSettings'];
|
|
48
|
-
};
|
|
84
|
+
request: TCreateGlobalAppRequest;
|
|
49
85
|
response: {
|
|
50
86
|
app: dto.IGlobalAppDto;
|
|
51
|
-
|
|
87
|
+
secretDelivery?: TSecretDeliveryEnvelope;
|
|
52
88
|
};
|
|
53
89
|
}
|
|
54
90
|
/**
|
|
@@ -100,22 +136,72 @@ export interface IReq_RegenerateAppCredentials extends plugins.typedRequestInter
|
|
|
100
136
|
request: {
|
|
101
137
|
jwt: string;
|
|
102
138
|
appId: string;
|
|
139
|
+
/** Caller-stable idempotency key for this exact rotation request. */
|
|
140
|
+
operationId: string;
|
|
141
|
+
secretDelivery: ISecretDeliveryRequest;
|
|
103
142
|
gracePeriodSeconds?: number;
|
|
104
143
|
};
|
|
105
144
|
response: {
|
|
106
145
|
clientId: string;
|
|
107
|
-
|
|
146
|
+
secretDelivery: TSecretDeliveryEnvelope;
|
|
108
147
|
retiringSecretsValidUntil?: number;
|
|
109
148
|
};
|
|
110
149
|
}
|
|
150
|
+
/**
|
|
151
|
+
* Irreversibly closes a pending encrypted delivery after the caller has
|
|
152
|
+
* decrypted and stored the secret.
|
|
153
|
+
*/
|
|
154
|
+
export interface IReq_AcknowledgeAppSecretDelivery extends plugins.typedRequestInterfaces.implementsTR<plugins.typedRequestInterfaces.ITypedRequest, IReq_AcknowledgeAppSecretDelivery> {
|
|
155
|
+
method: 'acknowledgeAppSecretDelivery';
|
|
156
|
+
request: {
|
|
157
|
+
jwt: string;
|
|
158
|
+
appId: string;
|
|
159
|
+
operationId: string;
|
|
160
|
+
ciphertextSha256: string;
|
|
161
|
+
};
|
|
162
|
+
response: {
|
|
163
|
+
acknowledgedAt: number;
|
|
164
|
+
};
|
|
165
|
+
}
|
|
111
166
|
export interface IReq_RotateOidcSigningKey extends plugins.typedRequestInterfaces.implementsTR<plugins.typedRequestInterfaces.ITypedRequest, IReq_RotateOidcSigningKey> {
|
|
112
167
|
method: 'rotateOidcSigningKey';
|
|
113
168
|
request: {
|
|
114
169
|
jwt: string;
|
|
170
|
+
/** Caller-stable idempotency key for this exact rotation request. */
|
|
171
|
+
operationId: string;
|
|
115
172
|
};
|
|
116
173
|
response: {
|
|
174
|
+
status: 'pending' | 'completed' | 'expired';
|
|
175
|
+
operationId: string;
|
|
176
|
+
activeKid: string;
|
|
177
|
+
requestedAt: number;
|
|
178
|
+
expiresAt: number;
|
|
179
|
+
/** Present only when a distinct administrator completed the request. */
|
|
180
|
+
approvedAt?: number;
|
|
181
|
+
/** Present only when the request completed and identifies its new active key. */
|
|
182
|
+
resultingActiveKid?: string;
|
|
183
|
+
/** Present only when the request completed. */
|
|
184
|
+
retiringKids?: string[];
|
|
185
|
+
};
|
|
186
|
+
}
|
|
187
|
+
/**
|
|
188
|
+
* Approve and execute a pending OIDC signing-key rotation requested by a
|
|
189
|
+
* different global administrator.
|
|
190
|
+
*/
|
|
191
|
+
export interface IReq_ApproveOidcSigningKeyRotation extends plugins.typedRequestInterfaces.implementsTR<plugins.typedRequestInterfaces.ITypedRequest, IReq_ApproveOidcSigningKeyRotation> {
|
|
192
|
+
method: 'approveOidcSigningKeyRotation';
|
|
193
|
+
request: {
|
|
194
|
+
jwt: string;
|
|
195
|
+
/** Must exactly match the caller-stable id of the pending request. */
|
|
196
|
+
operationId: string;
|
|
197
|
+
/** Binds approval to the key that was active when the request was reviewed. */
|
|
198
|
+
expectedActiveKid: string;
|
|
199
|
+
};
|
|
200
|
+
response: {
|
|
201
|
+
operationId: string;
|
|
117
202
|
activeKid: string;
|
|
118
203
|
retiringKids: string[];
|
|
204
|
+
approvedAt: number;
|
|
119
205
|
};
|
|
120
206
|
}
|
|
121
207
|
export interface IReq_SetOrganizationSuspension extends plugins.typedRequestInterfaces.implementsTR<plugins.typedRequestInterfaces.ITypedRequest, IReq_SetOrganizationSuspension> {
|
|
@@ -204,3 +290,4 @@ export interface IReq_GetGlobalOrgStats extends plugins.typedRequestInterfaces.i
|
|
|
204
290
|
total: number;
|
|
205
291
|
};
|
|
206
292
|
}
|
|
293
|
+
export {};
|
package/package.json
CHANGED
package/ts/00_commitinfo_data.ts
CHANGED
package/ts/request/admin.ts
CHANGED
|
@@ -1,6 +1,66 @@
|
|
|
1
1
|
import * as plugins from '../plugins.js';
|
|
2
2
|
import * as dto from '../dto/index.js';
|
|
3
3
|
|
|
4
|
+
export type TSecretDeliveryAlgorithm = 'RSA-OAEP-256';
|
|
5
|
+
|
|
6
|
+
/** Caller-held RSA public key used to seal one-time secret material. */
|
|
7
|
+
export interface ISecretDeliveryRequest {
|
|
8
|
+
algorithm: TSecretDeliveryAlgorithm;
|
|
9
|
+
/** Canonical DER SubjectPublicKeyInfo encoded as standard padded base64. */
|
|
10
|
+
publicKeySpkiBase64: string;
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* Durable delivery receipt. Pending envelopes can be retried byte-for-byte
|
|
15
|
+
* until the caller acknowledges their ciphertext hash.
|
|
16
|
+
*/
|
|
17
|
+
export type TSecretDeliveryEnvelope = {
|
|
18
|
+
operationId: string;
|
|
19
|
+
algorithm: TSecretDeliveryAlgorithm;
|
|
20
|
+
publicKeySha256: string;
|
|
21
|
+
ciphertextSha256: string;
|
|
22
|
+
createdAt: number;
|
|
23
|
+
} & (
|
|
24
|
+
| {
|
|
25
|
+
status: 'pending';
|
|
26
|
+
ciphertextBase64: string;
|
|
27
|
+
acknowledgedAt?: never;
|
|
28
|
+
}
|
|
29
|
+
| {
|
|
30
|
+
status: 'acknowledged';
|
|
31
|
+
ciphertextBase64?: never;
|
|
32
|
+
acknowledgedAt: number;
|
|
33
|
+
}
|
|
34
|
+
);
|
|
35
|
+
|
|
36
|
+
type TCreateGlobalAppBaseRequest = {
|
|
37
|
+
jwt: string;
|
|
38
|
+
name: string;
|
|
39
|
+
description: string;
|
|
40
|
+
logoUrl: string;
|
|
41
|
+
appUrl: string;
|
|
42
|
+
category: string;
|
|
43
|
+
redirectUris: string[];
|
|
44
|
+
postLogoutRedirectUris: string[];
|
|
45
|
+
allowedScopes: string[];
|
|
46
|
+
grantTypes: dto.IGlobalAppDto['data']['oauthCredentials']['grantTypes'];
|
|
47
|
+
oidcSettings: dto.IGlobalAppDto['data']['oidcSettings'];
|
|
48
|
+
};
|
|
49
|
+
|
|
50
|
+
export type TCreateGlobalAppRequest = TCreateGlobalAppBaseRequest & (
|
|
51
|
+
| {
|
|
52
|
+
clientType: 'public';
|
|
53
|
+
operationId?: never;
|
|
54
|
+
secretDelivery?: never;
|
|
55
|
+
}
|
|
56
|
+
| {
|
|
57
|
+
clientType: 'confidential';
|
|
58
|
+
/** Caller-stable idempotency key for creation and secret delivery. */
|
|
59
|
+
operationId: string;
|
|
60
|
+
secretDelivery: ISecretDeliveryRequest;
|
|
61
|
+
}
|
|
62
|
+
);
|
|
63
|
+
|
|
4
64
|
/**
|
|
5
65
|
* Check if the current user is a global admin
|
|
6
66
|
*/
|
|
@@ -47,23 +107,10 @@ export interface IReq_CreateGlobalApp
|
|
|
47
107
|
IReq_CreateGlobalApp
|
|
48
108
|
> {
|
|
49
109
|
method: 'createGlobalApp';
|
|
50
|
-
request:
|
|
51
|
-
jwt: string;
|
|
52
|
-
name: string;
|
|
53
|
-
description: string;
|
|
54
|
-
logoUrl: string;
|
|
55
|
-
appUrl: string;
|
|
56
|
-
category: string;
|
|
57
|
-
clientType: dto.IGlobalAppDto['data']['oauthCredentials']['clientType'];
|
|
58
|
-
redirectUris: string[];
|
|
59
|
-
postLogoutRedirectUris: string[];
|
|
60
|
-
allowedScopes: string[];
|
|
61
|
-
grantTypes: dto.IGlobalAppDto['data']['oauthCredentials']['grantTypes'];
|
|
62
|
-
oidcSettings: dto.IGlobalAppDto['data']['oidcSettings'];
|
|
63
|
-
};
|
|
110
|
+
request: TCreateGlobalAppRequest;
|
|
64
111
|
response: {
|
|
65
112
|
app: dto.IGlobalAppDto;
|
|
66
|
-
|
|
113
|
+
secretDelivery?: TSecretDeliveryEnvelope;
|
|
67
114
|
};
|
|
68
115
|
}
|
|
69
116
|
|
|
@@ -130,15 +177,39 @@ export interface IReq_RegenerateAppCredentials
|
|
|
130
177
|
request: {
|
|
131
178
|
jwt: string;
|
|
132
179
|
appId: string;
|
|
180
|
+
/** Caller-stable idempotency key for this exact rotation request. */
|
|
181
|
+
operationId: string;
|
|
182
|
+
secretDelivery: ISecretDeliveryRequest;
|
|
133
183
|
gracePeriodSeconds?: number;
|
|
134
184
|
};
|
|
135
185
|
response: {
|
|
136
186
|
clientId: string;
|
|
137
|
-
|
|
187
|
+
secretDelivery: TSecretDeliveryEnvelope;
|
|
138
188
|
retiringSecretsValidUntil?: number;
|
|
139
189
|
};
|
|
140
190
|
}
|
|
141
191
|
|
|
192
|
+
/**
|
|
193
|
+
* Irreversibly closes a pending encrypted delivery after the caller has
|
|
194
|
+
* decrypted and stored the secret.
|
|
195
|
+
*/
|
|
196
|
+
export interface IReq_AcknowledgeAppSecretDelivery
|
|
197
|
+
extends plugins.typedRequestInterfaces.implementsTR<
|
|
198
|
+
plugins.typedRequestInterfaces.ITypedRequest,
|
|
199
|
+
IReq_AcknowledgeAppSecretDelivery
|
|
200
|
+
> {
|
|
201
|
+
method: 'acknowledgeAppSecretDelivery';
|
|
202
|
+
request: {
|
|
203
|
+
jwt: string;
|
|
204
|
+
appId: string;
|
|
205
|
+
operationId: string;
|
|
206
|
+
ciphertextSha256: string;
|
|
207
|
+
};
|
|
208
|
+
response: {
|
|
209
|
+
acknowledgedAt: number;
|
|
210
|
+
};
|
|
211
|
+
}
|
|
212
|
+
|
|
142
213
|
export interface IReq_RotateOidcSigningKey
|
|
143
214
|
extends plugins.typedRequestInterfaces.implementsTR<
|
|
144
215
|
plugins.typedRequestInterfaces.ITypedRequest,
|
|
@@ -147,10 +218,46 @@ export interface IReq_RotateOidcSigningKey
|
|
|
147
218
|
method: 'rotateOidcSigningKey';
|
|
148
219
|
request: {
|
|
149
220
|
jwt: string;
|
|
221
|
+
/** Caller-stable idempotency key for this exact rotation request. */
|
|
222
|
+
operationId: string;
|
|
150
223
|
};
|
|
151
224
|
response: {
|
|
225
|
+
status: 'pending' | 'completed' | 'expired';
|
|
226
|
+
operationId: string;
|
|
227
|
+
activeKid: string;
|
|
228
|
+
requestedAt: number;
|
|
229
|
+
expiresAt: number;
|
|
230
|
+
/** Present only when a distinct administrator completed the request. */
|
|
231
|
+
approvedAt?: number;
|
|
232
|
+
/** Present only when the request completed and identifies its new active key. */
|
|
233
|
+
resultingActiveKid?: string;
|
|
234
|
+
/** Present only when the request completed. */
|
|
235
|
+
retiringKids?: string[];
|
|
236
|
+
};
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
/**
|
|
240
|
+
* Approve and execute a pending OIDC signing-key rotation requested by a
|
|
241
|
+
* different global administrator.
|
|
242
|
+
*/
|
|
243
|
+
export interface IReq_ApproveOidcSigningKeyRotation
|
|
244
|
+
extends plugins.typedRequestInterfaces.implementsTR<
|
|
245
|
+
plugins.typedRequestInterfaces.ITypedRequest,
|
|
246
|
+
IReq_ApproveOidcSigningKeyRotation
|
|
247
|
+
> {
|
|
248
|
+
method: 'approveOidcSigningKeyRotation';
|
|
249
|
+
request: {
|
|
250
|
+
jwt: string;
|
|
251
|
+
/** Must exactly match the caller-stable id of the pending request. */
|
|
252
|
+
operationId: string;
|
|
253
|
+
/** Binds approval to the key that was active when the request was reviewed. */
|
|
254
|
+
expectedActiveKid: string;
|
|
255
|
+
};
|
|
256
|
+
response: {
|
|
257
|
+
operationId: string;
|
|
152
258
|
activeKid: string;
|
|
153
259
|
retiringKids: string[];
|
|
260
|
+
approvedAt: number;
|
|
154
261
|
};
|
|
155
262
|
}
|
|
156
263
|
|