@aepstore-dev/contracts 1.100.0 → 1.101.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/gen/auth.d.ts +67 -0
- package/gen/auth.js +6 -0
- package/gen/auth.ts +112 -0
- package/package.json +1 -1
- package/proto/auth.proto +70 -0
package/gen/auth.d.ts
CHANGED
|
@@ -78,6 +78,37 @@ export interface ResetUserTwoFactorRequest {
|
|
|
78
78
|
adminId: string;
|
|
79
79
|
reason: string;
|
|
80
80
|
}
|
|
81
|
+
export interface GeneratePasskeyRegistrationOptionsRequest {
|
|
82
|
+
userId: string;
|
|
83
|
+
}
|
|
84
|
+
export interface VerifyPasskeyRegistrationRequest {
|
|
85
|
+
userId: string;
|
|
86
|
+
challengeId: string;
|
|
87
|
+
/** Raw JSON returned by @simplewebauthn/browser startRegistration(). */
|
|
88
|
+
responseJson: string;
|
|
89
|
+
name: string;
|
|
90
|
+
}
|
|
91
|
+
export interface ListPasskeysRequest {
|
|
92
|
+
userId: string;
|
|
93
|
+
}
|
|
94
|
+
export interface DeletePasskeyRequest {
|
|
95
|
+
userId: string;
|
|
96
|
+
passkeyId: string;
|
|
97
|
+
}
|
|
98
|
+
export interface GeneratePasskeyAuthenticationOptionsRequest {
|
|
99
|
+
/**
|
|
100
|
+
* Username or email. V1 requires an existing account identifier and does
|
|
101
|
+
* not implement passkey-first/account-discovery registration.
|
|
102
|
+
*/
|
|
103
|
+
credentials: string;
|
|
104
|
+
}
|
|
105
|
+
export interface VerifyPasskeyAuthenticationRequest {
|
|
106
|
+
challengeId: string;
|
|
107
|
+
/** Raw JSON returned by @simplewebauthn/browser startAuthentication(). */
|
|
108
|
+
responseJson: string;
|
|
109
|
+
userAgent: string;
|
|
110
|
+
ip: string;
|
|
111
|
+
}
|
|
81
112
|
export interface AuthUser {
|
|
82
113
|
id: string;
|
|
83
114
|
username: string;
|
|
@@ -150,6 +181,30 @@ export interface ResetUserTwoFactorResponse {
|
|
|
150
181
|
previousType: TwoFactorType;
|
|
151
182
|
revokedSessions: number;
|
|
152
183
|
}
|
|
184
|
+
export interface PasskeyOptionsResponse {
|
|
185
|
+
/** PublicKeyCredentialCreationOptionsJSON or PublicKeyCredentialRequestOptionsJSON. */
|
|
186
|
+
optionsJson: string;
|
|
187
|
+
challengeId: string;
|
|
188
|
+
}
|
|
189
|
+
export interface PasskeyInfo {
|
|
190
|
+
id: string;
|
|
191
|
+
name: string;
|
|
192
|
+
createdAt: string;
|
|
193
|
+
lastUsedAt: string;
|
|
194
|
+
deviceType: string;
|
|
195
|
+
backedUp: boolean;
|
|
196
|
+
transports: string[];
|
|
197
|
+
}
|
|
198
|
+
export interface PasskeyRegistrationResponse {
|
|
199
|
+
ok: boolean;
|
|
200
|
+
passkey: PasskeyInfo | undefined;
|
|
201
|
+
}
|
|
202
|
+
export interface ListPasskeysResponse {
|
|
203
|
+
items: PasskeyInfo[];
|
|
204
|
+
}
|
|
205
|
+
export interface DeletePasskeyResponse {
|
|
206
|
+
ok: boolean;
|
|
207
|
+
}
|
|
153
208
|
export interface RestoreLoginRequest {
|
|
154
209
|
/** email or username */
|
|
155
210
|
credentials: string;
|
|
@@ -198,6 +253,12 @@ export interface AuthServiceClient {
|
|
|
198
253
|
getProfile(request: GetProfileRequest): Observable<AuthUser>;
|
|
199
254
|
cleanupExpiredTotpSetups(request: Empty): Observable<Empty>;
|
|
200
255
|
resetUserTwoFactor(request: ResetUserTwoFactorRequest): Observable<ResetUserTwoFactorResponse>;
|
|
256
|
+
generatePasskeyRegistrationOptions(request: GeneratePasskeyRegistrationOptionsRequest): Observable<PasskeyOptionsResponse>;
|
|
257
|
+
verifyPasskeyRegistration(request: VerifyPasskeyRegistrationRequest): Observable<PasskeyRegistrationResponse>;
|
|
258
|
+
listPasskeys(request: ListPasskeysRequest): Observable<ListPasskeysResponse>;
|
|
259
|
+
deletePasskey(request: DeletePasskeyRequest): Observable<DeletePasskeyResponse>;
|
|
260
|
+
generatePasskeyAuthenticationOptions(request: GeneratePasskeyAuthenticationOptionsRequest): Observable<PasskeyOptionsResponse>;
|
|
261
|
+
verifyPasskeyAuthentication(request: VerifyPasskeyAuthenticationRequest): Observable<AuthResult>;
|
|
201
262
|
/**
|
|
202
263
|
* Logout — kill refresh tokens. LogoutCurrent kills only the one whose
|
|
203
264
|
* HMAC matches; LogoutAll wipes every row for the user.
|
|
@@ -235,6 +296,12 @@ export interface AuthServiceController {
|
|
|
235
296
|
getProfile(request: GetProfileRequest): Promise<AuthUser> | Observable<AuthUser> | AuthUser;
|
|
236
297
|
cleanupExpiredTotpSetups(request: Empty): Promise<Empty> | Observable<Empty> | Empty;
|
|
237
298
|
resetUserTwoFactor(request: ResetUserTwoFactorRequest): Promise<ResetUserTwoFactorResponse> | Observable<ResetUserTwoFactorResponse> | ResetUserTwoFactorResponse;
|
|
299
|
+
generatePasskeyRegistrationOptions(request: GeneratePasskeyRegistrationOptionsRequest): Promise<PasskeyOptionsResponse> | Observable<PasskeyOptionsResponse> | PasskeyOptionsResponse;
|
|
300
|
+
verifyPasskeyRegistration(request: VerifyPasskeyRegistrationRequest): Promise<PasskeyRegistrationResponse> | Observable<PasskeyRegistrationResponse> | PasskeyRegistrationResponse;
|
|
301
|
+
listPasskeys(request: ListPasskeysRequest): Promise<ListPasskeysResponse> | Observable<ListPasskeysResponse> | ListPasskeysResponse;
|
|
302
|
+
deletePasskey(request: DeletePasskeyRequest): Promise<DeletePasskeyResponse> | Observable<DeletePasskeyResponse> | DeletePasskeyResponse;
|
|
303
|
+
generatePasskeyAuthenticationOptions(request: GeneratePasskeyAuthenticationOptionsRequest): Promise<PasskeyOptionsResponse> | Observable<PasskeyOptionsResponse> | PasskeyOptionsResponse;
|
|
304
|
+
verifyPasskeyAuthentication(request: VerifyPasskeyAuthenticationRequest): Promise<AuthResult> | Observable<AuthResult> | AuthResult;
|
|
238
305
|
/**
|
|
239
306
|
* Logout — kill refresh tokens. LogoutCurrent kills only the one whose
|
|
240
307
|
* HMAC matches; LogoutAll wipes every row for the user.
|
package/gen/auth.js
CHANGED
|
@@ -31,6 +31,12 @@ function AuthServiceControllerMethods() {
|
|
|
31
31
|
"getProfile",
|
|
32
32
|
"cleanupExpiredTotpSetups",
|
|
33
33
|
"resetUserTwoFactor",
|
|
34
|
+
"generatePasskeyRegistrationOptions",
|
|
35
|
+
"verifyPasskeyRegistration",
|
|
36
|
+
"listPasskeys",
|
|
37
|
+
"deletePasskey",
|
|
38
|
+
"generatePasskeyAuthenticationOptions",
|
|
39
|
+
"verifyPasskeyAuthentication",
|
|
34
40
|
"logoutCurrent",
|
|
35
41
|
"logoutAll",
|
|
36
42
|
"restoreLogin",
|
package/gen/auth.ts
CHANGED
|
@@ -98,6 +98,43 @@ export interface ResetUserTwoFactorRequest {
|
|
|
98
98
|
reason: string;
|
|
99
99
|
}
|
|
100
100
|
|
|
101
|
+
export interface GeneratePasskeyRegistrationOptionsRequest {
|
|
102
|
+
userId: string;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
export interface VerifyPasskeyRegistrationRequest {
|
|
106
|
+
userId: string;
|
|
107
|
+
challengeId: string;
|
|
108
|
+
/** Raw JSON returned by @simplewebauthn/browser startRegistration(). */
|
|
109
|
+
responseJson: string;
|
|
110
|
+
name: string;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
export interface ListPasskeysRequest {
|
|
114
|
+
userId: string;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
export interface DeletePasskeyRequest {
|
|
118
|
+
userId: string;
|
|
119
|
+
passkeyId: string;
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
export interface GeneratePasskeyAuthenticationOptionsRequest {
|
|
123
|
+
/**
|
|
124
|
+
* Username or email. V1 requires an existing account identifier and does
|
|
125
|
+
* not implement passkey-first/account-discovery registration.
|
|
126
|
+
*/
|
|
127
|
+
credentials: string;
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
export interface VerifyPasskeyAuthenticationRequest {
|
|
131
|
+
challengeId: string;
|
|
132
|
+
/** Raw JSON returned by @simplewebauthn/browser startAuthentication(). */
|
|
133
|
+
responseJson: string;
|
|
134
|
+
userAgent: string;
|
|
135
|
+
ip: string;
|
|
136
|
+
}
|
|
137
|
+
|
|
101
138
|
export interface AuthUser {
|
|
102
139
|
id: string;
|
|
103
140
|
username: string;
|
|
@@ -178,6 +215,35 @@ export interface ResetUserTwoFactorResponse {
|
|
|
178
215
|
revokedSessions: number;
|
|
179
216
|
}
|
|
180
217
|
|
|
218
|
+
export interface PasskeyOptionsResponse {
|
|
219
|
+
/** PublicKeyCredentialCreationOptionsJSON or PublicKeyCredentialRequestOptionsJSON. */
|
|
220
|
+
optionsJson: string;
|
|
221
|
+
challengeId: string;
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
export interface PasskeyInfo {
|
|
225
|
+
id: string;
|
|
226
|
+
name: string;
|
|
227
|
+
createdAt: string;
|
|
228
|
+
lastUsedAt: string;
|
|
229
|
+
deviceType: string;
|
|
230
|
+
backedUp: boolean;
|
|
231
|
+
transports: string[];
|
|
232
|
+
}
|
|
233
|
+
|
|
234
|
+
export interface PasskeyRegistrationResponse {
|
|
235
|
+
ok: boolean;
|
|
236
|
+
passkey: PasskeyInfo | undefined;
|
|
237
|
+
}
|
|
238
|
+
|
|
239
|
+
export interface ListPasskeysResponse {
|
|
240
|
+
items: PasskeyInfo[];
|
|
241
|
+
}
|
|
242
|
+
|
|
243
|
+
export interface DeletePasskeyResponse {
|
|
244
|
+
ok: boolean;
|
|
245
|
+
}
|
|
246
|
+
|
|
181
247
|
export interface RestoreLoginRequest {
|
|
182
248
|
/** email or username */
|
|
183
249
|
credentials: string;
|
|
@@ -242,6 +308,22 @@ export interface AuthServiceClient {
|
|
|
242
308
|
|
|
243
309
|
resetUserTwoFactor(request: ResetUserTwoFactorRequest): Observable<ResetUserTwoFactorResponse>;
|
|
244
310
|
|
|
311
|
+
generatePasskeyRegistrationOptions(
|
|
312
|
+
request: GeneratePasskeyRegistrationOptionsRequest,
|
|
313
|
+
): Observable<PasskeyOptionsResponse>;
|
|
314
|
+
|
|
315
|
+
verifyPasskeyRegistration(request: VerifyPasskeyRegistrationRequest): Observable<PasskeyRegistrationResponse>;
|
|
316
|
+
|
|
317
|
+
listPasskeys(request: ListPasskeysRequest): Observable<ListPasskeysResponse>;
|
|
318
|
+
|
|
319
|
+
deletePasskey(request: DeletePasskeyRequest): Observable<DeletePasskeyResponse>;
|
|
320
|
+
|
|
321
|
+
generatePasskeyAuthenticationOptions(
|
|
322
|
+
request: GeneratePasskeyAuthenticationOptionsRequest,
|
|
323
|
+
): Observable<PasskeyOptionsResponse>;
|
|
324
|
+
|
|
325
|
+
verifyPasskeyAuthentication(request: VerifyPasskeyAuthenticationRequest): Observable<AuthResult>;
|
|
326
|
+
|
|
245
327
|
/**
|
|
246
328
|
* Logout — kill refresh tokens. LogoutCurrent kills only the one whose
|
|
247
329
|
* HMAC matches; LogoutAll wipes every row for the user.
|
|
@@ -301,6 +383,30 @@ export interface AuthServiceController {
|
|
|
301
383
|
request: ResetUserTwoFactorRequest,
|
|
302
384
|
): Promise<ResetUserTwoFactorResponse> | Observable<ResetUserTwoFactorResponse> | ResetUserTwoFactorResponse;
|
|
303
385
|
|
|
386
|
+
generatePasskeyRegistrationOptions(
|
|
387
|
+
request: GeneratePasskeyRegistrationOptionsRequest,
|
|
388
|
+
): Promise<PasskeyOptionsResponse> | Observable<PasskeyOptionsResponse> | PasskeyOptionsResponse;
|
|
389
|
+
|
|
390
|
+
verifyPasskeyRegistration(
|
|
391
|
+
request: VerifyPasskeyRegistrationRequest,
|
|
392
|
+
): Promise<PasskeyRegistrationResponse> | Observable<PasskeyRegistrationResponse> | PasskeyRegistrationResponse;
|
|
393
|
+
|
|
394
|
+
listPasskeys(
|
|
395
|
+
request: ListPasskeysRequest,
|
|
396
|
+
): Promise<ListPasskeysResponse> | Observable<ListPasskeysResponse> | ListPasskeysResponse;
|
|
397
|
+
|
|
398
|
+
deletePasskey(
|
|
399
|
+
request: DeletePasskeyRequest,
|
|
400
|
+
): Promise<DeletePasskeyResponse> | Observable<DeletePasskeyResponse> | DeletePasskeyResponse;
|
|
401
|
+
|
|
402
|
+
generatePasskeyAuthenticationOptions(
|
|
403
|
+
request: GeneratePasskeyAuthenticationOptionsRequest,
|
|
404
|
+
): Promise<PasskeyOptionsResponse> | Observable<PasskeyOptionsResponse> | PasskeyOptionsResponse;
|
|
405
|
+
|
|
406
|
+
verifyPasskeyAuthentication(
|
|
407
|
+
request: VerifyPasskeyAuthenticationRequest,
|
|
408
|
+
): Promise<AuthResult> | Observable<AuthResult> | AuthResult;
|
|
409
|
+
|
|
304
410
|
/**
|
|
305
411
|
* Logout — kill refresh tokens. LogoutCurrent kills only the one whose
|
|
306
412
|
* HMAC matches; LogoutAll wipes every row for the user.
|
|
@@ -341,6 +447,12 @@ export function AuthServiceControllerMethods() {
|
|
|
341
447
|
"getProfile",
|
|
342
448
|
"cleanupExpiredTotpSetups",
|
|
343
449
|
"resetUserTwoFactor",
|
|
450
|
+
"generatePasskeyRegistrationOptions",
|
|
451
|
+
"verifyPasskeyRegistration",
|
|
452
|
+
"listPasskeys",
|
|
453
|
+
"deletePasskey",
|
|
454
|
+
"generatePasskeyAuthenticationOptions",
|
|
455
|
+
"verifyPasskeyAuthentication",
|
|
344
456
|
"logoutCurrent",
|
|
345
457
|
"logoutAll",
|
|
346
458
|
"restoreLogin",
|
package/package.json
CHANGED
package/proto/auth.proto
CHANGED
|
@@ -19,6 +19,12 @@ service AuthService {
|
|
|
19
19
|
rpc GetProfile(GetProfileRequest) returns (AuthUser);
|
|
20
20
|
rpc CleanupExpiredTotpSetups(Empty) returns (Empty);
|
|
21
21
|
rpc ResetUserTwoFactor(ResetUserTwoFactorRequest) returns (ResetUserTwoFactorResponse);
|
|
22
|
+
rpc GeneratePasskeyRegistrationOptions(GeneratePasskeyRegistrationOptionsRequest) returns (PasskeyOptionsResponse);
|
|
23
|
+
rpc VerifyPasskeyRegistration(VerifyPasskeyRegistrationRequest) returns (PasskeyRegistrationResponse);
|
|
24
|
+
rpc ListPasskeys(ListPasskeysRequest) returns (ListPasskeysResponse);
|
|
25
|
+
rpc DeletePasskey(DeletePasskeyRequest) returns (DeletePasskeyResponse);
|
|
26
|
+
rpc GeneratePasskeyAuthenticationOptions(GeneratePasskeyAuthenticationOptionsRequest) returns (PasskeyOptionsResponse);
|
|
27
|
+
rpc VerifyPasskeyAuthentication(VerifyPasskeyAuthenticationRequest) returns (AuthResult);
|
|
22
28
|
|
|
23
29
|
// Logout — kill refresh tokens. LogoutCurrent kills only the one whose
|
|
24
30
|
// HMAC matches; LogoutAll wipes every row for the user.
|
|
@@ -113,6 +119,41 @@ message ResetUserTwoFactorRequest {
|
|
|
113
119
|
string admin_id = 2;
|
|
114
120
|
string reason = 3;
|
|
115
121
|
}
|
|
122
|
+
|
|
123
|
+
message GeneratePasskeyRegistrationOptionsRequest {
|
|
124
|
+
string user_id = 1;
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
message VerifyPasskeyRegistrationRequest {
|
|
128
|
+
string user_id = 1;
|
|
129
|
+
string challenge_id = 2;
|
|
130
|
+
// Raw JSON returned by @simplewebauthn/browser startRegistration().
|
|
131
|
+
string response_json = 3;
|
|
132
|
+
string name = 4;
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
message ListPasskeysRequest {
|
|
136
|
+
string user_id = 1;
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
message DeletePasskeyRequest {
|
|
140
|
+
string user_id = 1;
|
|
141
|
+
string passkey_id = 2;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
message GeneratePasskeyAuthenticationOptionsRequest {
|
|
145
|
+
// Username or email. V1 requires an existing account identifier and does
|
|
146
|
+
// not implement passkey-first/account-discovery registration.
|
|
147
|
+
string credentials = 1;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
message VerifyPasskeyAuthenticationRequest {
|
|
151
|
+
string challenge_id = 1;
|
|
152
|
+
// Raw JSON returned by @simplewebauthn/browser startAuthentication().
|
|
153
|
+
string response_json = 2;
|
|
154
|
+
string user_agent = 3;
|
|
155
|
+
string ip = 4;
|
|
156
|
+
}
|
|
116
157
|
|
|
117
158
|
// ---------------------------------------------------------------------------
|
|
118
159
|
// Responses
|
|
@@ -195,6 +236,35 @@ message ResetUserTwoFactorResponse {
|
|
|
195
236
|
TwoFactorType previous_type = 2;
|
|
196
237
|
int32 revoked_sessions = 3;
|
|
197
238
|
}
|
|
239
|
+
|
|
240
|
+
message PasskeyOptionsResponse {
|
|
241
|
+
// PublicKeyCredentialCreationOptionsJSON or PublicKeyCredentialRequestOptionsJSON.
|
|
242
|
+
string options_json = 1;
|
|
243
|
+
string challenge_id = 2;
|
|
244
|
+
}
|
|
245
|
+
|
|
246
|
+
message PasskeyInfo {
|
|
247
|
+
string id = 1;
|
|
248
|
+
string name = 2;
|
|
249
|
+
string created_at = 3;
|
|
250
|
+
string last_used_at = 4;
|
|
251
|
+
string device_type = 5;
|
|
252
|
+
bool backed_up = 6;
|
|
253
|
+
repeated string transports = 7;
|
|
254
|
+
}
|
|
255
|
+
|
|
256
|
+
message PasskeyRegistrationResponse {
|
|
257
|
+
bool ok = 1;
|
|
258
|
+
PasskeyInfo passkey = 2;
|
|
259
|
+
}
|
|
260
|
+
|
|
261
|
+
message ListPasskeysResponse {
|
|
262
|
+
repeated PasskeyInfo items = 1;
|
|
263
|
+
}
|
|
264
|
+
|
|
265
|
+
message DeletePasskeyResponse {
|
|
266
|
+
bool ok = 1;
|
|
267
|
+
}
|
|
198
268
|
|
|
199
269
|
message RestoreLoginRequest {
|
|
200
270
|
string credentials = 1; // email or username
|