@structured-id/ui-core 1.3.0 → 3.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.
Files changed (152) hide show
  1. package/README.md +22 -10
  2. package/package.json +25 -43
  3. package/src/components/SidStatusBadge.vue +1 -5
  4. package/src/composables/useAccountTransport.test.ts +2 -1
  5. package/src/composables/useGrpc.test.ts +17 -14
  6. package/src/composables/useGrpc.ts +4 -2
  7. package/src/index.ts +2 -120
  8. package/src/profile/components/ConsentManager.vue +5 -1
  9. package/src/profile/components/ProfileEditor.vue +1 -1
  10. package/src/profile/components/SecuritySettings.vue +5 -1
  11. package/src/profile/components/SessionList.vue +2 -1
  12. package/src/profile/components/SidRegistrationForm.test.ts +173 -1
  13. package/src/profile/components/SidRegistrationForm.vue +88 -32
  14. package/src/profile/components/index.ts +1 -4
  15. package/src/profile/composables/index.ts +1 -0
  16. package/src/profile/composables/operationPlan.test.ts +155 -0
  17. package/src/profile/composables/operationPlan.ts +218 -0
  18. package/src/profile/composables/useAccountApi.ts +4 -4
  19. package/src/profile/composables/useAuth.test.ts +312 -31
  20. package/src/profile/composables/useAuth.ts +176 -30
  21. package/src/profile/composables/useAuthApi.opaque.test.ts +13 -6
  22. package/src/profile/composables/useAuthApi.ts +40 -18
  23. package/src/profile/composables/useCurrentPasswordRequirement.test.ts +196 -0
  24. package/src/profile/composables/useCurrentPasswordRequirement.ts +95 -0
  25. package/src/profile/composables/useEnrollmentApi.test.ts +7 -3
  26. package/src/profile/composables/useEnrollmentApi.ts +3 -5
  27. package/src/profile/composables/useIdentityApi.ts +4 -4
  28. package/src/profile/composables/useSecurityLevel.test.ts +1 -1
  29. package/src/profile/composables/useSecurityLevel.ts +1 -1
  30. package/src/quasar/SidPasswordCeremony.test.ts +253 -0
  31. package/src/quasar/SidPasswordCeremony.vue +456 -0
  32. package/src/quasar/index.ts +2 -0
  33. package/src/utils/rpcRefusal.test.ts +4 -4
  34. package/src/utils/rpcRefusal.ts +8 -4
  35. package/dist/browser-vp/index.cjs +0 -349
  36. package/dist/browser-vp/index.d.cts +0 -276
  37. package/dist/browser-vp/index.d.ts +0 -276
  38. package/dist/browser-vp/index.js +0 -349
  39. package/dist/chunk-C3Q766CY.cjs +0 -125
  40. package/dist/chunk-J5YXRXB5.js +0 -125
  41. package/dist/index.cjs +0 -23581
  42. package/dist/index.d.cts +0 -11539
  43. package/dist/index.d.ts +0 -11539
  44. package/dist/index.js +0 -23581
  45. package/dist/storage-4CB2JTLW.cjs +0 -22
  46. package/dist/storage-THRWREZP.js +0 -22
  47. package/src/browser-vp/crypto.ts +0 -253
  48. package/src/browser-vp/index.test.ts +0 -10
  49. package/src/browser-vp/index.ts +0 -116
  50. package/src/browser-vp/prf.ts +0 -179
  51. package/src/browser-vp/storage.test.ts +0 -9
  52. package/src/browser-vp/storage.ts +0 -163
  53. package/src/browser-vp/types.ts +0 -95
  54. package/src/browser-vp/vp.test.ts +0 -43
  55. package/src/browser-vp/vp.ts +0 -111
  56. package/src/generated/google/api/http.ts +0 -687
  57. package/src/generated/google/api/httpbody.ts +0 -159
  58. package/src/generated/google/protobuf/any.ts +0 -326
  59. package/src/generated/google/protobuf/descriptor.ts +0 -4865
  60. package/src/generated/google/protobuf/duration.ts +0 -230
  61. package/src/generated/google/protobuf/empty.ts +0 -94
  62. package/src/generated/google/protobuf/struct.ts +0 -484
  63. package/src/generated/google/protobuf/timestamp.ts +0 -287
  64. package/src/generated/google/rpc/error_details.ts +0 -1386
  65. package/src/generated/google/rpc/status.ts +0 -127
  66. package/src/generated/sid/v1/account/account.client.ts +0 -527
  67. package/src/generated/sid/v1/account/account.ts +0 -3261
  68. package/src/generated/sid/v1/admin/admin.client.ts +0 -139
  69. package/src/generated/sid/v1/admin/admin.ts +0 -781
  70. package/src/generated/sid/v1/admin/admin_roles.client.ts +0 -181
  71. package/src/generated/sid/v1/admin/admin_roles.ts +0 -1606
  72. package/src/generated/sid/v1/admin/analytics.client.ts +0 -106
  73. package/src/generated/sid/v1/admin/analytics.ts +0 -1017
  74. package/src/generated/sid/v1/admin/branding.client.ts +0 -166
  75. package/src/generated/sid/v1/admin/branding.ts +0 -1906
  76. package/src/generated/sid/v1/admin/enrollment.client.ts +0 -177
  77. package/src/generated/sid/v1/admin/enrollment.ts +0 -1766
  78. package/src/generated/sid/v1/admin/events.client.ts +0 -195
  79. package/src/generated/sid/v1/admin/events.ts +0 -1900
  80. package/src/generated/sid/v1/admin/flow.client.ts +0 -183
  81. package/src/generated/sid/v1/admin/flow.ts +0 -1552
  82. package/src/generated/sid/v1/admin/keys.client.ts +0 -107
  83. package/src/generated/sid/v1/admin/keys.ts +0 -931
  84. package/src/generated/sid/v1/admin/login_experience.client.ts +0 -160
  85. package/src/generated/sid/v1/admin/login_experience.ts +0 -1061
  86. package/src/generated/sid/v1/admin/migration.client.ts +0 -127
  87. package/src/generated/sid/v1/admin/migration.ts +0 -1948
  88. package/src/generated/sid/v1/admin/notifications.client.ts +0 -134
  89. package/src/generated/sid/v1/admin/notifications.ts +0 -1273
  90. package/src/generated/sid/v1/admin/operations.client.ts +0 -241
  91. package/src/generated/sid/v1/admin/operations.ts +0 -2633
  92. package/src/generated/sid/v1/admin/organizations.client.ts +0 -57
  93. package/src/generated/sid/v1/admin/organizations.ts +0 -332
  94. package/src/generated/sid/v1/admin/provisioning.client.ts +0 -232
  95. package/src/generated/sid/v1/admin/provisioning.ts +0 -1383
  96. package/src/generated/sid/v1/admin/scopes.client.ts +0 -171
  97. package/src/generated/sid/v1/admin/scopes.ts +0 -1324
  98. package/src/generated/sid/v1/admin/security.client.ts +0 -410
  99. package/src/generated/sid/v1/admin/security.ts +0 -4077
  100. package/src/generated/sid/v1/admin/sessions.client.ts +0 -114
  101. package/src/generated/sid/v1/admin/sessions.ts +0 -923
  102. package/src/generated/sid/v1/admin/settings.client.ts +0 -351
  103. package/src/generated/sid/v1/admin/settings.ts +0 -2458
  104. package/src/generated/sid/v1/admin/user_profile.client.ts +0 -57
  105. package/src/generated/sid/v1/admin/user_profile.ts +0 -730
  106. package/src/generated/sid/v1/admin/webhooks.client.ts +0 -269
  107. package/src/generated/sid/v1/admin/webhooks.ts +0 -2804
  108. package/src/generated/sid/v1/attestation/attestation.client.ts +0 -115
  109. package/src/generated/sid/v1/attestation/attestation.ts +0 -813
  110. package/src/generated/sid/v1/authn/auth.client.ts +0 -943
  111. package/src/generated/sid/v1/authn/auth.ts +0 -9719
  112. package/src/generated/sid/v1/authn/flows.client.ts +0 -413
  113. package/src/generated/sid/v1/authn/flows.ts +0 -3205
  114. package/src/generated/sid/v1/authn/issuer.client.ts +0 -489
  115. package/src/generated/sid/v1/authn/issuer.ts +0 -1600
  116. package/src/generated/sid/v1/authn/password_history.client.ts +0 -57
  117. package/src/generated/sid/v1/authn/password_history.ts +0 -578
  118. package/src/generated/sid/v1/authn/system_integration.client.ts +0 -73
  119. package/src/generated/sid/v1/authn/system_integration.ts +0 -218
  120. package/src/generated/sid/v1/authz/authz.client.ts +0 -459
  121. package/src/generated/sid/v1/authz/authz.ts +0 -6524
  122. package/src/generated/sid/v1/authz/forward_auth.client.ts +0 -97
  123. package/src/generated/sid/v1/authz/forward_auth.ts +0 -79
  124. package/src/generated/sid/v1/authz/governance.client.ts +0 -102
  125. package/src/generated/sid/v1/authz/governance.ts +0 -875
  126. package/src/generated/sid/v1/common/errors.ts +0 -710
  127. package/src/generated/sid/v1/common/pagination.ts +0 -152
  128. package/src/generated/sid/v1/common/transport.ts +0 -227
  129. package/src/generated/sid/v1/common/types.ts +0 -151
  130. package/src/generated/sid/v1/events/event_stream.client.ts +0 -67
  131. package/src/generated/sid/v1/events/event_stream.ts +0 -375
  132. package/src/generated/sid/v1/federation/upstream.client.ts +0 -142
  133. package/src/generated/sid/v1/federation/upstream.ts +0 -1736
  134. package/src/generated/sid/v1/identity/identity.client.ts +0 -467
  135. package/src/generated/sid/v1/identity/identity.ts +0 -5676
  136. package/src/generated/sid/v1/ids/ids.ts +0 -395
  137. package/src/generated/sid/v1/machine/machine_user.client.ts +0 -219
  138. package/src/generated/sid/v1/machine/machine_user.ts +0 -2364
  139. package/src/generated/sid/v1/machine/pat.client.ts +0 -130
  140. package/src/generated/sid/v1/machine/pat.ts +0 -1083
  141. package/src/generated/sid/v1/projects/projects.client.ts +0 -404
  142. package/src/generated/sid/v1/projects/projects.ts +0 -4446
  143. package/src/generated/sid/v1/scim/scim.client.ts +0 -520
  144. package/src/generated/sid/v1/scim/scim.ts +0 -3182
  145. package/src/generated/sid/v1/test/test.client.ts +0 -232
  146. package/src/generated/sid/v1/test/test.ts +0 -1136
  147. package/src/transport/adaptive.test.ts +0 -728
  148. package/src/transport/adaptive.ts +0 -308
  149. package/src/transport/framing.test.ts +0 -227
  150. package/src/transport/framing.ts +0 -98
  151. package/src/transport/webtransport.test.ts +0 -728
  152. package/src/transport/webtransport.ts +0 -323
@@ -1,489 +0,0 @@
1
- // @generated by protobuf-ts 2.11.1 with parameter client_generic,generate_dependencies
2
- // @generated from protobuf file "sid/v1/authn/issuer.proto" (package "sid.v1.authn", syntax proto3)
3
- // tslint:disable
4
- import { OidcIssuerService } from "./issuer";
5
- import type { ProtectedResourceTarget } from "./issuer";
6
- import type { GetProtectedResourceRequest } from "./issuer";
7
- import type { OidcIssuer } from "./issuer";
8
- import type { GetOidcIssuerRequest } from "./issuer";
9
- import type { RpcTransport } from "@protobuf-ts/runtime-rpc";
10
- import type { ServiceInfo } from "@protobuf-ts/runtime-rpc";
11
- import { OidcProviderService } from "./issuer";
12
- import type { RegistrationRequest } from "./issuer";
13
- import type { EndSessionRequest } from "./issuer";
14
- import type { ProtocolRequest } from "./issuer";
15
- import type { HttpBody } from "../../../google/api/httpbody";
16
- import type { OAuth2AuthorizeRequest } from "./auth";
17
- import type { UserInfo } from "./issuer";
18
- import type { JsonWebKeySet } from "./issuer";
19
- import { stackIntercept } from "@protobuf-ts/runtime-rpc";
20
- import type { ProviderMetadata } from "./issuer";
21
- import type { IssuerHandleRequest } from "./issuer";
22
- import type { UnaryCall } from "@protobuf-ts/runtime-rpc";
23
- import type { RpcOptions } from "@protobuf-ts/runtime-rpc";
24
- /**
25
- * OidcProviderService publishes one issuer's metadata and signing keys to its
26
- * relying parties. Every document belongs to the issuer the handle names; an
27
- * unknown handle is NOT_FOUND with ErrorInfo reason OIDC_ISSUER_NOT_FOUND and
28
- * never falls back to another issuer. There is no issuer-less document.
29
- *
30
- * @generated from protobuf service sid.v1.authn.OidcProviderService
31
- */
32
- export interface IOidcProviderServiceClient {
33
- /**
34
- * The issuer's metadata (OpenID Connect Discovery 1.0 §3–4, RFC 8414 §2–3).
35
- * One document answers both discovery algorithms: the OIDC location under
36
- * the issuer path and the RFC 8414 well-known location with the issuer path
37
- * appended.
38
- *
39
- * @generated from protobuf rpc: GetProviderMetadata
40
- */
41
- getProviderMetadata(input: IssuerHandleRequest, options?: RpcOptions): UnaryCall<IssuerHandleRequest, ProviderMetadata>;
42
- /**
43
- * The issuer's JSON Web Key Set (RFC 7517 §5): the public keys that verify
44
- * its tokens. The response metadata carries `cache-control` for HTTP caches.
45
- *
46
- * @generated from protobuf rpc: GetJwks
47
- */
48
- getJwks(input: IssuerHandleRequest, options?: RpcOptions): UnaryCall<IssuerHandleRequest, JsonWebKeySet>;
49
- /**
50
- * UserInfo (OIDC Core 1.0 §5.3) over GET. The access token travels in the
51
- * `authorization` metadata, `Bearer` (RFC 6750 §2.1) or `DPoP` with a proof
52
- * in the `dpop` metadata (RFC 9449 §7.1); only tokens this issuer signed are
53
- * accepted. A refused token is UNAUTHENTICATED with a `www-authenticate`
54
- * response metadata challenge (RFC 6750 §3, RFC 9449 §7.1). GET and POST
55
- * are separate RPCs because a DPoP proof names the request method.
56
- *
57
- * @generated from protobuf rpc: GetUserInfo
58
- */
59
- getUserInfo(input: IssuerHandleRequest, options?: RpcOptions): UnaryCall<IssuerHandleRequest, UserInfo>;
60
- /**
61
- * UserInfo over POST (OIDC Core 1.0 §5.3.1); the same answer as GetUserInfo.
62
- *
63
- * @generated from protobuf rpc: PostUserInfo
64
- */
65
- postUserInfo(input: IssuerHandleRequest, options?: RpcOptions): UnaryCall<IssuerHandleRequest, UserInfo>;
66
- /**
67
- * The browser authorization endpoint (RFC 6749 §3.1) over GET, the query
68
- * parameters bound to the request fields. The answer is an HTTP redirect
69
- * (`x-http-code` 303 and `location` response metadata, RFC 9700 §4.11): to
70
- * the client's registered redirect URI with `code` or `error`, `state` and
71
- * `iss` (RFC 9207 §2), or, when the user must sign in first, to the sign-in
72
- * page with this request to return to. A request whose client or exact
73
- * redirect URI is not established is answered with a page and never
74
- * redirected (RFC 6749 §4.1.2.1). The signed-in user's token, when a
75
- * gateway holds one, travels in the `authorization` metadata.
76
- *
77
- * @generated from protobuf rpc: GetAuthorize
78
- */
79
- getAuthorize(input: OAuth2AuthorizeRequest, options?: RpcOptions): UnaryCall<OAuth2AuthorizeRequest, HttpBody>;
80
- /**
81
- * The authorization endpoint over POST with a form body (OIDC Core 1.0
82
- * §3.1.2.1); the same answer as GetAuthorize. Parameters it does not know
83
- * are ignored (RFC 6749 §3.1).
84
- *
85
- * @generated from protobuf rpc: PostAuthorize
86
- */
87
- postAuthorize(input: ProtocolRequest, options?: RpcOptions): UnaryCall<ProtocolRequest, HttpBody>;
88
- /**
89
- * RP-Initiated Logout (OIDC RP-Initiated Logout 1.0 §2) over GET. The
90
- * browser's IdP session is read from its `__Host-sid_session` cookie
91
- * (`cookie` metadata). A valid `id_token_hint` of this issuer ends the
92
- * application session it names; when that session reuses the browser's
93
- * IdP session, single sign-on ends too and the answer clears the cookie.
94
- * Otherwise ending the browser's IdP session needs the user's confirmation
95
- * (§2): the answer is a page with a form that confirms it by POST. A
96
- * `post_logout_redirect_uri` is followed only for a valid `id_token_hint`
97
- * whose client registered exactly that URI (§3): the answer is then a 303
98
- * to it with `state`, or, while the browser's IdP session remains, the
99
- * confirmation page, which returns there after either choice. Otherwise the
100
- * answer is a page.
101
- *
102
- * @generated from protobuf rpc: GetEndSession
103
- */
104
- getEndSession(input: EndSessionRequest, options?: RpcOptions): UnaryCall<EndSessionRequest, HttpBody>;
105
- /**
106
- * RP-Initiated Logout over POST with a form body: the same parameters as
107
- * GetEndSession, plus `confirmation`, the one-time value of the
108
- * confirmation page's form, which ends the browser's IdP session it was
109
- * issued for and returns to the post-logout redirect URI that page was
110
- * shown for, if any.
111
- *
112
- * @generated from protobuf rpc: PostEndSession
113
- */
114
- postEndSession(input: ProtocolRequest, options?: RpcOptions): UnaryCall<ProtocolRequest, HttpBody>;
115
- // The endpoints below are the HTTP form of AuthService's OAuth RPCs, with
116
- // the same logic: the request body is the `application/x-www-form-urlencoded`
117
- // form the RFC defines, the answer is the RFC's JSON with its HTTP status in
118
- // the `x-http-code` response metadata and its headers (`cache-control`,
119
- // `pragma`, `www-authenticate`) as response metadata. A refusal is an OK
120
- // gRPC call carrying the RFC error body; typed gRPC clients use AuthService.
121
- // HTTP Basic client authentication travels in the `authorization` metadata,
122
- // a DPoP proof in `dpop`.
123
-
124
- /**
125
- * Token endpoint (RFC 6749 §3.2): every grant, including the device_code
126
- * grant (RFC 8628 §3.4). Success is RFC 6749 §5.1 JSON with
127
- * `cache-control: no-store`; a refusal is RFC 6749 §5.2 or RFC 8628 §3.5
128
- * JSON, 401 with a `www-authenticate` challenge for `invalid_client` when
129
- * the client used HTTP Basic, 400 otherwise.
130
- *
131
- * @generated from protobuf rpc: Token
132
- */
133
- token(input: ProtocolRequest, options?: RpcOptions): UnaryCall<ProtocolRequest, HttpBody>;
134
- /**
135
- * Token introspection (RFC 7662 §2): RFC 7662 §2.2 JSON, `{"active":false}`
136
- * for any token this issuer does not vouch for.
137
- *
138
- * @generated from protobuf rpc: Introspect
139
- */
140
- introspect(input: ProtocolRequest, options?: RpcOptions): UnaryCall<ProtocolRequest, HttpBody>;
141
- /**
142
- * Token revocation (RFC 7009 §2): 200 with an empty body, also for a token
143
- * that is unknown or already revoked (RFC 7009 §2.2).
144
- *
145
- * @generated from protobuf rpc: Revoke
146
- */
147
- revoke(input: ProtocolRequest, options?: RpcOptions): UnaryCall<ProtocolRequest, HttpBody>;
148
- /**
149
- * Device authorization (RFC 8628 §3.1): RFC 8628 §3.2 JSON; a refusal is
150
- * RFC 6749 §5.2 JSON as at the token endpoint.
151
- *
152
- * @generated from protobuf rpc: DeviceAuthorization
153
- */
154
- deviceAuthorization(input: ProtocolRequest, options?: RpcOptions): UnaryCall<ProtocolRequest, HttpBody>;
155
- // The registration endpoints below are the HTTP form of ProjectService's
156
- // dynamic registration RPCs, with the same logic. Bodies are
157
- // `application/json` client metadata (RFC 7591 §2); the initial access
158
- // token or registration access token travels as a bearer token in the
159
- // `authorization` metadata. A refusal is an OK gRPC call carrying the RFC
160
- // error body with its HTTP status in `x-http-code`.
161
-
162
- /**
163
- * Client registration (RFC 7591 §3.1). Success is 201 with every
164
- * registered metadata value, the credentials and the management location
165
- * (RFC 7591 §3.2.1, RFC 7592 §3); invalid metadata is 400 with
166
- * `invalid_client_metadata` or `invalid_redirect_uri` (RFC 7591 §3.2.2); a
167
- * missing or invalid initial access token is 401 (RFC 6750 §3.1).
168
- *
169
- * @generated from protobuf rpc: Register
170
- */
171
- register(input: ProtocolRequest, options?: RpcOptions): UnaryCall<ProtocolRequest, HttpBody>;
172
- /**
173
- * Read a registration (RFC 7592 §2.1): the client's current metadata as at
174
- * registration, without its secret. An invalid registration access token,
175
- * or a client this issuer does not have, is 401 (RFC 7592 §2.1).
176
- *
177
- * @generated from protobuf rpc: ReadRegistration
178
- */
179
- readRegistration(input: RegistrationRequest, options?: RpcOptions): UnaryCall<RegistrationRequest, HttpBody>;
180
- /**
181
- * Update a registration (RFC 7592 §2.2): the body replaces the client's
182
- * metadata and is validated as a registration; a refused update changes
183
- * nothing.
184
- *
185
- * @generated from protobuf rpc: UpdateRegistration
186
- */
187
- updateRegistration(input: RegistrationRequest, options?: RpcOptions): UnaryCall<RegistrationRequest, HttpBody>;
188
- /**
189
- * Delete a registration (RFC 7592 §2.3): 204 with no body.
190
- *
191
- * @generated from protobuf rpc: DeleteRegistration
192
- */
193
- deleteRegistration(input: RegistrationRequest, options?: RpcOptions): UnaryCall<RegistrationRequest, HttpBody>;
194
- }
195
- /**
196
- * OidcProviderService publishes one issuer's metadata and signing keys to its
197
- * relying parties. Every document belongs to the issuer the handle names; an
198
- * unknown handle is NOT_FOUND with ErrorInfo reason OIDC_ISSUER_NOT_FOUND and
199
- * never falls back to another issuer. There is no issuer-less document.
200
- *
201
- * @generated from protobuf service sid.v1.authn.OidcProviderService
202
- */
203
- export class OidcProviderServiceClient implements IOidcProviderServiceClient, ServiceInfo {
204
- typeName = OidcProviderService.typeName;
205
- methods = OidcProviderService.methods;
206
- options = OidcProviderService.options;
207
- constructor(private readonly _transport: RpcTransport) {
208
- }
209
- /**
210
- * The issuer's metadata (OpenID Connect Discovery 1.0 §3–4, RFC 8414 §2–3).
211
- * One document answers both discovery algorithms: the OIDC location under
212
- * the issuer path and the RFC 8414 well-known location with the issuer path
213
- * appended.
214
- *
215
- * @generated from protobuf rpc: GetProviderMetadata
216
- */
217
- getProviderMetadata(input: IssuerHandleRequest, options?: RpcOptions): UnaryCall<IssuerHandleRequest, ProviderMetadata> {
218
- const method = this.methods[0], opt = this._transport.mergeOptions(options);
219
- return stackIntercept<IssuerHandleRequest, ProviderMetadata>("unary", this._transport, method, opt, input);
220
- }
221
- /**
222
- * The issuer's JSON Web Key Set (RFC 7517 §5): the public keys that verify
223
- * its tokens. The response metadata carries `cache-control` for HTTP caches.
224
- *
225
- * @generated from protobuf rpc: GetJwks
226
- */
227
- getJwks(input: IssuerHandleRequest, options?: RpcOptions): UnaryCall<IssuerHandleRequest, JsonWebKeySet> {
228
- const method = this.methods[1], opt = this._transport.mergeOptions(options);
229
- return stackIntercept<IssuerHandleRequest, JsonWebKeySet>("unary", this._transport, method, opt, input);
230
- }
231
- /**
232
- * UserInfo (OIDC Core 1.0 §5.3) over GET. The access token travels in the
233
- * `authorization` metadata, `Bearer` (RFC 6750 §2.1) or `DPoP` with a proof
234
- * in the `dpop` metadata (RFC 9449 §7.1); only tokens this issuer signed are
235
- * accepted. A refused token is UNAUTHENTICATED with a `www-authenticate`
236
- * response metadata challenge (RFC 6750 §3, RFC 9449 §7.1). GET and POST
237
- * are separate RPCs because a DPoP proof names the request method.
238
- *
239
- * @generated from protobuf rpc: GetUserInfo
240
- */
241
- getUserInfo(input: IssuerHandleRequest, options?: RpcOptions): UnaryCall<IssuerHandleRequest, UserInfo> {
242
- const method = this.methods[2], opt = this._transport.mergeOptions(options);
243
- return stackIntercept<IssuerHandleRequest, UserInfo>("unary", this._transport, method, opt, input);
244
- }
245
- /**
246
- * UserInfo over POST (OIDC Core 1.0 §5.3.1); the same answer as GetUserInfo.
247
- *
248
- * @generated from protobuf rpc: PostUserInfo
249
- */
250
- postUserInfo(input: IssuerHandleRequest, options?: RpcOptions): UnaryCall<IssuerHandleRequest, UserInfo> {
251
- const method = this.methods[3], opt = this._transport.mergeOptions(options);
252
- return stackIntercept<IssuerHandleRequest, UserInfo>("unary", this._transport, method, opt, input);
253
- }
254
- /**
255
- * The browser authorization endpoint (RFC 6749 §3.1) over GET, the query
256
- * parameters bound to the request fields. The answer is an HTTP redirect
257
- * (`x-http-code` 303 and `location` response metadata, RFC 9700 §4.11): to
258
- * the client's registered redirect URI with `code` or `error`, `state` and
259
- * `iss` (RFC 9207 §2), or, when the user must sign in first, to the sign-in
260
- * page with this request to return to. A request whose client or exact
261
- * redirect URI is not established is answered with a page and never
262
- * redirected (RFC 6749 §4.1.2.1). The signed-in user's token, when a
263
- * gateway holds one, travels in the `authorization` metadata.
264
- *
265
- * @generated from protobuf rpc: GetAuthorize
266
- */
267
- getAuthorize(input: OAuth2AuthorizeRequest, options?: RpcOptions): UnaryCall<OAuth2AuthorizeRequest, HttpBody> {
268
- const method = this.methods[4], opt = this._transport.mergeOptions(options);
269
- return stackIntercept<OAuth2AuthorizeRequest, HttpBody>("unary", this._transport, method, opt, input);
270
- }
271
- /**
272
- * The authorization endpoint over POST with a form body (OIDC Core 1.0
273
- * §3.1.2.1); the same answer as GetAuthorize. Parameters it does not know
274
- * are ignored (RFC 6749 §3.1).
275
- *
276
- * @generated from protobuf rpc: PostAuthorize
277
- */
278
- postAuthorize(input: ProtocolRequest, options?: RpcOptions): UnaryCall<ProtocolRequest, HttpBody> {
279
- const method = this.methods[5], opt = this._transport.mergeOptions(options);
280
- return stackIntercept<ProtocolRequest, HttpBody>("unary", this._transport, method, opt, input);
281
- }
282
- /**
283
- * RP-Initiated Logout (OIDC RP-Initiated Logout 1.0 §2) over GET. The
284
- * browser's IdP session is read from its `__Host-sid_session` cookie
285
- * (`cookie` metadata). A valid `id_token_hint` of this issuer ends the
286
- * application session it names; when that session reuses the browser's
287
- * IdP session, single sign-on ends too and the answer clears the cookie.
288
- * Otherwise ending the browser's IdP session needs the user's confirmation
289
- * (§2): the answer is a page with a form that confirms it by POST. A
290
- * `post_logout_redirect_uri` is followed only for a valid `id_token_hint`
291
- * whose client registered exactly that URI (§3): the answer is then a 303
292
- * to it with `state`, or, while the browser's IdP session remains, the
293
- * confirmation page, which returns there after either choice. Otherwise the
294
- * answer is a page.
295
- *
296
- * @generated from protobuf rpc: GetEndSession
297
- */
298
- getEndSession(input: EndSessionRequest, options?: RpcOptions): UnaryCall<EndSessionRequest, HttpBody> {
299
- const method = this.methods[6], opt = this._transport.mergeOptions(options);
300
- return stackIntercept<EndSessionRequest, HttpBody>("unary", this._transport, method, opt, input);
301
- }
302
- /**
303
- * RP-Initiated Logout over POST with a form body: the same parameters as
304
- * GetEndSession, plus `confirmation`, the one-time value of the
305
- * confirmation page's form, which ends the browser's IdP session it was
306
- * issued for and returns to the post-logout redirect URI that page was
307
- * shown for, if any.
308
- *
309
- * @generated from protobuf rpc: PostEndSession
310
- */
311
- postEndSession(input: ProtocolRequest, options?: RpcOptions): UnaryCall<ProtocolRequest, HttpBody> {
312
- const method = this.methods[7], opt = this._transport.mergeOptions(options);
313
- return stackIntercept<ProtocolRequest, HttpBody>("unary", this._transport, method, opt, input);
314
- }
315
- // The endpoints below are the HTTP form of AuthService's OAuth RPCs, with
316
- // the same logic: the request body is the `application/x-www-form-urlencoded`
317
- // form the RFC defines, the answer is the RFC's JSON with its HTTP status in
318
- // the `x-http-code` response metadata and its headers (`cache-control`,
319
- // `pragma`, `www-authenticate`) as response metadata. A refusal is an OK
320
- // gRPC call carrying the RFC error body; typed gRPC clients use AuthService.
321
- // HTTP Basic client authentication travels in the `authorization` metadata,
322
- // a DPoP proof in `dpop`.
323
-
324
- /**
325
- * Token endpoint (RFC 6749 §3.2): every grant, including the device_code
326
- * grant (RFC 8628 §3.4). Success is RFC 6749 §5.1 JSON with
327
- * `cache-control: no-store`; a refusal is RFC 6749 §5.2 or RFC 8628 §3.5
328
- * JSON, 401 with a `www-authenticate` challenge for `invalid_client` when
329
- * the client used HTTP Basic, 400 otherwise.
330
- *
331
- * @generated from protobuf rpc: Token
332
- */
333
- token(input: ProtocolRequest, options?: RpcOptions): UnaryCall<ProtocolRequest, HttpBody> {
334
- const method = this.methods[8], opt = this._transport.mergeOptions(options);
335
- return stackIntercept<ProtocolRequest, HttpBody>("unary", this._transport, method, opt, input);
336
- }
337
- /**
338
- * Token introspection (RFC 7662 §2): RFC 7662 §2.2 JSON, `{"active":false}`
339
- * for any token this issuer does not vouch for.
340
- *
341
- * @generated from protobuf rpc: Introspect
342
- */
343
- introspect(input: ProtocolRequest, options?: RpcOptions): UnaryCall<ProtocolRequest, HttpBody> {
344
- const method = this.methods[9], opt = this._transport.mergeOptions(options);
345
- return stackIntercept<ProtocolRequest, HttpBody>("unary", this._transport, method, opt, input);
346
- }
347
- /**
348
- * Token revocation (RFC 7009 §2): 200 with an empty body, also for a token
349
- * that is unknown or already revoked (RFC 7009 §2.2).
350
- *
351
- * @generated from protobuf rpc: Revoke
352
- */
353
- revoke(input: ProtocolRequest, options?: RpcOptions): UnaryCall<ProtocolRequest, HttpBody> {
354
- const method = this.methods[10], opt = this._transport.mergeOptions(options);
355
- return stackIntercept<ProtocolRequest, HttpBody>("unary", this._transport, method, opt, input);
356
- }
357
- /**
358
- * Device authorization (RFC 8628 §3.1): RFC 8628 §3.2 JSON; a refusal is
359
- * RFC 6749 §5.2 JSON as at the token endpoint.
360
- *
361
- * @generated from protobuf rpc: DeviceAuthorization
362
- */
363
- deviceAuthorization(input: ProtocolRequest, options?: RpcOptions): UnaryCall<ProtocolRequest, HttpBody> {
364
- const method = this.methods[11], opt = this._transport.mergeOptions(options);
365
- return stackIntercept<ProtocolRequest, HttpBody>("unary", this._transport, method, opt, input);
366
- }
367
- // The registration endpoints below are the HTTP form of ProjectService's
368
- // dynamic registration RPCs, with the same logic. Bodies are
369
- // `application/json` client metadata (RFC 7591 §2); the initial access
370
- // token or registration access token travels as a bearer token in the
371
- // `authorization` metadata. A refusal is an OK gRPC call carrying the RFC
372
- // error body with its HTTP status in `x-http-code`.
373
-
374
- /**
375
- * Client registration (RFC 7591 §3.1). Success is 201 with every
376
- * registered metadata value, the credentials and the management location
377
- * (RFC 7591 §3.2.1, RFC 7592 §3); invalid metadata is 400 with
378
- * `invalid_client_metadata` or `invalid_redirect_uri` (RFC 7591 §3.2.2); a
379
- * missing or invalid initial access token is 401 (RFC 6750 §3.1).
380
- *
381
- * @generated from protobuf rpc: Register
382
- */
383
- register(input: ProtocolRequest, options?: RpcOptions): UnaryCall<ProtocolRequest, HttpBody> {
384
- const method = this.methods[12], opt = this._transport.mergeOptions(options);
385
- return stackIntercept<ProtocolRequest, HttpBody>("unary", this._transport, method, opt, input);
386
- }
387
- /**
388
- * Read a registration (RFC 7592 §2.1): the client's current metadata as at
389
- * registration, without its secret. An invalid registration access token,
390
- * or a client this issuer does not have, is 401 (RFC 7592 §2.1).
391
- *
392
- * @generated from protobuf rpc: ReadRegistration
393
- */
394
- readRegistration(input: RegistrationRequest, options?: RpcOptions): UnaryCall<RegistrationRequest, HttpBody> {
395
- const method = this.methods[13], opt = this._transport.mergeOptions(options);
396
- return stackIntercept<RegistrationRequest, HttpBody>("unary", this._transport, method, opt, input);
397
- }
398
- /**
399
- * Update a registration (RFC 7592 §2.2): the body replaces the client's
400
- * metadata and is validated as a registration; a refused update changes
401
- * nothing.
402
- *
403
- * @generated from protobuf rpc: UpdateRegistration
404
- */
405
- updateRegistration(input: RegistrationRequest, options?: RpcOptions): UnaryCall<RegistrationRequest, HttpBody> {
406
- const method = this.methods[14], opt = this._transport.mergeOptions(options);
407
- return stackIntercept<RegistrationRequest, HttpBody>("unary", this._transport, method, opt, input);
408
- }
409
- /**
410
- * Delete a registration (RFC 7592 §2.3): 204 with no body.
411
- *
412
- * @generated from protobuf rpc: DeleteRegistration
413
- */
414
- deleteRegistration(input: RegistrationRequest, options?: RpcOptions): UnaryCall<RegistrationRequest, HttpBody> {
415
- const method = this.methods[15], opt = this._transport.mergeOptions(options);
416
- return stackIntercept<RegistrationRequest, HttpBody>("unary", this._transport, method, opt, input);
417
- }
418
- }
419
- /**
420
- * OidcIssuerService lets services that verify an issuer's tokens resolve the
421
- * issuer and its keys by handle, and the registered resource a token must be
422
- * issued for.
423
- *
424
- * Internal only, no HTTP annotation: relying parties use OidcProviderService.
425
- *
426
- * @generated from protobuf service sid.v1.authn.OidcIssuerService
427
- */
428
- export interface IOidcIssuerServiceClient {
429
- /**
430
- * Look up an issuer by handle. An unknown handle is NOT_FOUND with
431
- * ErrorInfo reason OIDC_ISSUER_NOT_FOUND and a ResourceInfo naming the
432
- * handle; the caller refuses the request and never falls back to another
433
- * issuer.
434
- *
435
- * @generated from protobuf rpc: GetOidcIssuer
436
- */
437
- getOidcIssuer(input: GetOidcIssuerRequest, options?: RpcOptions): UnaryCall<GetOidcIssuerRequest, OidcIssuer>;
438
- /**
439
- * Resolve the protected resource a route of the ingress configuration names
440
- * before a token is accepted for it. The resource must be registered under
441
- * this issuer: an unknown issuer or indicator is NOT_FOUND with ErrorInfo
442
- * reason RESOURCE_NOT_FOUND and a ResourceInfo naming the indicator. The
443
- * caller refuses the route and never falls back to another target.
444
- *
445
- * @generated from protobuf rpc: GetProtectedResource
446
- */
447
- getProtectedResource(input: GetProtectedResourceRequest, options?: RpcOptions): UnaryCall<GetProtectedResourceRequest, ProtectedResourceTarget>;
448
- }
449
- /**
450
- * OidcIssuerService lets services that verify an issuer's tokens resolve the
451
- * issuer and its keys by handle, and the registered resource a token must be
452
- * issued for.
453
- *
454
- * Internal only, no HTTP annotation: relying parties use OidcProviderService.
455
- *
456
- * @generated from protobuf service sid.v1.authn.OidcIssuerService
457
- */
458
- export class OidcIssuerServiceClient implements IOidcIssuerServiceClient, ServiceInfo {
459
- typeName = OidcIssuerService.typeName;
460
- methods = OidcIssuerService.methods;
461
- options = OidcIssuerService.options;
462
- constructor(private readonly _transport: RpcTransport) {
463
- }
464
- /**
465
- * Look up an issuer by handle. An unknown handle is NOT_FOUND with
466
- * ErrorInfo reason OIDC_ISSUER_NOT_FOUND and a ResourceInfo naming the
467
- * handle; the caller refuses the request and never falls back to another
468
- * issuer.
469
- *
470
- * @generated from protobuf rpc: GetOidcIssuer
471
- */
472
- getOidcIssuer(input: GetOidcIssuerRequest, options?: RpcOptions): UnaryCall<GetOidcIssuerRequest, OidcIssuer> {
473
- const method = this.methods[0], opt = this._transport.mergeOptions(options);
474
- return stackIntercept<GetOidcIssuerRequest, OidcIssuer>("unary", this._transport, method, opt, input);
475
- }
476
- /**
477
- * Resolve the protected resource a route of the ingress configuration names
478
- * before a token is accepted for it. The resource must be registered under
479
- * this issuer: an unknown issuer or indicator is NOT_FOUND with ErrorInfo
480
- * reason RESOURCE_NOT_FOUND and a ResourceInfo naming the indicator. The
481
- * caller refuses the route and never falls back to another target.
482
- *
483
- * @generated from protobuf rpc: GetProtectedResource
484
- */
485
- getProtectedResource(input: GetProtectedResourceRequest, options?: RpcOptions): UnaryCall<GetProtectedResourceRequest, ProtectedResourceTarget> {
486
- const method = this.methods[1], opt = this._transport.mergeOptions(options);
487
- return stackIntercept<GetProtectedResourceRequest, ProtectedResourceTarget>("unary", this._transport, method, opt, input);
488
- }
489
- }