@pagopa/io-wallet-oid4vp 2.0.0-apt → 2.0.0-launchpad
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/index.d.mts +4 -7
- package/dist/index.d.ts +4 -7
- package/dist/index.js +0 -8
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +0 -8
- package/dist/index.mjs.map +1 -1
- package/package.json +4 -4
package/dist/index.d.mts
CHANGED
|
@@ -138,8 +138,7 @@ type BaseJarOptions<TSigner extends JwtSignerFederation | JwtSignerX5c> = {
|
|
|
138
138
|
type JarOptionsV1_0 = BaseJarOptions<JwtSignerFederation>;
|
|
139
139
|
type JarOptionsV1_3 = BaseJarOptions<JwtSignerFederation | JwtSignerX5c>;
|
|
140
140
|
type JarOptionsV1_4 = JarOptionsV1_3;
|
|
141
|
-
type
|
|
142
|
-
type JarOptions = JarOptionsAPTITUDE | JarOptionsV1_0 | JarOptionsV1_3 | JarOptionsV1_4;
|
|
141
|
+
type JarOptions = JarOptionsV1_0 | JarOptionsV1_3 | JarOptionsV1_4;
|
|
143
142
|
interface BaseCreateAuthorizationRequestOptions<V extends ItWalletSpecsVersion, TJar extends JarOptions> {
|
|
144
143
|
/**
|
|
145
144
|
* Authorization request payload to be validated and serialized.
|
|
@@ -167,8 +166,7 @@ interface BaseCreateAuthorizationRequestOptions<V extends ItWalletSpecsVersion,
|
|
|
167
166
|
type CreateAuthorizationRequestOptionsV1_0 = BaseCreateAuthorizationRequestOptions<ItWalletSpecsVersion.V1_0, JarOptionsV1_0>;
|
|
168
167
|
type CreateAuthorizationRequestOptionsV1_3 = BaseCreateAuthorizationRequestOptions<ItWalletSpecsVersion.V1_3, JarOptionsV1_3>;
|
|
169
168
|
type CreateAuthorizationRequestOptionsV1_4 = BaseCreateAuthorizationRequestOptions<ItWalletSpecsVersion.V1_4, JarOptionsV1_4>;
|
|
170
|
-
type
|
|
171
|
-
type CreateAuthorizationRequestOptions = CreateAuthorizationRequestOptionsAPTITUDE | CreateAuthorizationRequestOptionsV1_0 | CreateAuthorizationRequestOptionsV1_3 | CreateAuthorizationRequestOptionsV1_4;
|
|
169
|
+
type CreateAuthorizationRequestOptions = CreateAuthorizationRequestOptionsV1_0 | CreateAuthorizationRequestOptionsV1_3 | CreateAuthorizationRequestOptionsV1_4;
|
|
172
170
|
interface BaseCreateAuthorizationRequestResult<TJar extends JarOptions> {
|
|
173
171
|
authorizationRequest: string;
|
|
174
172
|
authorizationRequestObject: JarAuthorizationRequest;
|
|
@@ -178,8 +176,7 @@ interface BaseCreateAuthorizationRequestResult<TJar extends JarOptions> {
|
|
|
178
176
|
type CreateAuthorizationRequestResultV1_0 = BaseCreateAuthorizationRequestResult<JarOptionsV1_0>;
|
|
179
177
|
type CreateAuthorizationRequestResultV1_3 = BaseCreateAuthorizationRequestResult<JarOptionsV1_3>;
|
|
180
178
|
type CreateAuthorizationRequestResultV1_4 = BaseCreateAuthorizationRequestResult<JarOptionsV1_4>;
|
|
181
|
-
type
|
|
182
|
-
type CreateAuthorizationRequestResult = CreateAuthorizationRequestResultAPTITUDE | CreateAuthorizationRequestResultV1_0 | CreateAuthorizationRequestResultV1_3 | CreateAuthorizationRequestResultV1_4;
|
|
179
|
+
type CreateAuthorizationRequestResult = CreateAuthorizationRequestResultV1_0 | CreateAuthorizationRequestResultV1_3 | CreateAuthorizationRequestResultV1_4;
|
|
183
180
|
/**
|
|
184
181
|
* Creates an OpenID4VP authorization request URL for the configured IT-Wallet version.
|
|
185
182
|
*
|
|
@@ -1231,4 +1228,4 @@ interface ParseJarmAuthorizationResponseOptions {
|
|
|
1231
1228
|
*/
|
|
1232
1229
|
declare function parseJarmAuthorizationResponse(options: ParseJarmAuthorizationResponseOptions): Promise<ParseAuthorizationResponseResult>;
|
|
1233
1230
|
|
|
1234
|
-
export { type AuthorizationRequestUrlParams, type CertificateEndpoint, type ClientIdParts, ClientIdPrefix, type CreateAuthorizationRequestOptions, type
|
|
1231
|
+
export { type AuthorizationRequestUrlParams, type CertificateEndpoint, type ClientIdParts, ClientIdPrefix, type CreateAuthorizationRequestOptions, type CreateAuthorizationRequestOptionsV1_0, type CreateAuthorizationRequestOptionsV1_3, type CreateAuthorizationRequestOptionsV1_4, type CreateAuthorizationRequestResult, type CreateAuthorizationRequestResultV1_0, type CreateAuthorizationRequestResultV1_3, type CreateAuthorizationRequestResultV1_4, CreateAuthorizationResponseError, type CreateAuthorizationResponseOptionsV1_0, type CreateAuthorizationResponseOptionsV1_3, type CreateAuthorizationResponseOptionsV1_4, type CreateAuthorizationResponseResult, type CreateAuthorizationResponseVersionedOptions, type CreateOpenid4vpAuthorizationResponseOptions, type CreateOpenid4vpAuthorizationResponseResult, type EncryptedJarmHeader, type FetchAuthorizationRequestOptions, type FetchAuthorizationRequestResult, FetchAuthorizationResponseError, type FetchAuthorizationResponseOptions, type GetX509CertificateMetadataCallback, InvalidRequestUriMethodError, type JarOptionsV1_0, type JarOptionsV1_3, type JarOptionsV1_4, type JarmAuthorizationResponse, type JarmAuthorizationResponseEncryptedOnly, type JarmClientMetadata, type JarmHeader, JarmMode, type JarmServerMetadata, Oid4vpError, type Openid4vpAuthorizationRequestHeader, type Openid4vpAuthorizationRequestHeaderV1_0, type Openid4vpAuthorizationRequestHeaderV1_3, type Openid4vpAuthorizationRequestPayload, type Openid4vpAuthorizationResponse, type Openid4vpAuthorizationResponsePayload, type Openid4vpAuthorizationResponseResult, type ParseAuthorizationResponseOptions, type ParseAuthorizationResponseResult, ParseAuthorizeRequestError, type ParseAuthorizeRequestOptions, type ParseJarmAuthorizationResponseOptions, type ParsedAuthorizeRequestResult, type ParsedQrCode, type ValidateCertificateEndpointsOptions, type ValidateOpenid4vpAuthorizationResponseOptions, type ValidateOpenid4vpAuthorizationResponseResult, type VerifyJarmAuthorizationResponseOptions, type VerifyJarmAuthorizationResponseResult, type VpToken, type VpTokenPresentationEntry, type X509CertificateBinding, type X509CertificateMetadata, createAuthorizationRequest, createAuthorizationResponse, createOpenid4vpAuthorizationResponse, createParsedQrCode, createX509HashClientId, extractClientIdPrefix, extractEncryptionJwkFromJwks, fetchAuthorizationRequest, fetchAuthorizationResponse, fetchRequestObjectJwt, parseAuthorizationResponse, parseAuthorizeRequest, parseJarmAuthorizationResponse, parseVpToken, validateAuthorizationRequestParams, validateCertificateEndpoints, validateOpenid4vpAuthorizationResponsePayload, verifyJarmAuthorizationResponse, zAuthorizationRequestUrlParams, zEncryptedJarmHeader, zJarmAuthorizationResponse, zJarmAuthorizationResponseEncryptedOnly, zJarmHeader, zOpenid4vpAuthorizationRequestHeaderV1_0, zOpenid4vpAuthorizationRequestHeaderV1_3, zOpenid4vpAuthorizationRequestPayload, zOpenid4vpAuthorizationResponse, zOpenid4vpAuthorizationResponseResult, zVpToken };
|
package/dist/index.d.ts
CHANGED
|
@@ -138,8 +138,7 @@ type BaseJarOptions<TSigner extends JwtSignerFederation | JwtSignerX5c> = {
|
|
|
138
138
|
type JarOptionsV1_0 = BaseJarOptions<JwtSignerFederation>;
|
|
139
139
|
type JarOptionsV1_3 = BaseJarOptions<JwtSignerFederation | JwtSignerX5c>;
|
|
140
140
|
type JarOptionsV1_4 = JarOptionsV1_3;
|
|
141
|
-
type
|
|
142
|
-
type JarOptions = JarOptionsAPTITUDE | JarOptionsV1_0 | JarOptionsV1_3 | JarOptionsV1_4;
|
|
141
|
+
type JarOptions = JarOptionsV1_0 | JarOptionsV1_3 | JarOptionsV1_4;
|
|
143
142
|
interface BaseCreateAuthorizationRequestOptions<V extends ItWalletSpecsVersion, TJar extends JarOptions> {
|
|
144
143
|
/**
|
|
145
144
|
* Authorization request payload to be validated and serialized.
|
|
@@ -167,8 +166,7 @@ interface BaseCreateAuthorizationRequestOptions<V extends ItWalletSpecsVersion,
|
|
|
167
166
|
type CreateAuthorizationRequestOptionsV1_0 = BaseCreateAuthorizationRequestOptions<ItWalletSpecsVersion.V1_0, JarOptionsV1_0>;
|
|
168
167
|
type CreateAuthorizationRequestOptionsV1_3 = BaseCreateAuthorizationRequestOptions<ItWalletSpecsVersion.V1_3, JarOptionsV1_3>;
|
|
169
168
|
type CreateAuthorizationRequestOptionsV1_4 = BaseCreateAuthorizationRequestOptions<ItWalletSpecsVersion.V1_4, JarOptionsV1_4>;
|
|
170
|
-
type
|
|
171
|
-
type CreateAuthorizationRequestOptions = CreateAuthorizationRequestOptionsAPTITUDE | CreateAuthorizationRequestOptionsV1_0 | CreateAuthorizationRequestOptionsV1_3 | CreateAuthorizationRequestOptionsV1_4;
|
|
169
|
+
type CreateAuthorizationRequestOptions = CreateAuthorizationRequestOptionsV1_0 | CreateAuthorizationRequestOptionsV1_3 | CreateAuthorizationRequestOptionsV1_4;
|
|
172
170
|
interface BaseCreateAuthorizationRequestResult<TJar extends JarOptions> {
|
|
173
171
|
authorizationRequest: string;
|
|
174
172
|
authorizationRequestObject: JarAuthorizationRequest;
|
|
@@ -178,8 +176,7 @@ interface BaseCreateAuthorizationRequestResult<TJar extends JarOptions> {
|
|
|
178
176
|
type CreateAuthorizationRequestResultV1_0 = BaseCreateAuthorizationRequestResult<JarOptionsV1_0>;
|
|
179
177
|
type CreateAuthorizationRequestResultV1_3 = BaseCreateAuthorizationRequestResult<JarOptionsV1_3>;
|
|
180
178
|
type CreateAuthorizationRequestResultV1_4 = BaseCreateAuthorizationRequestResult<JarOptionsV1_4>;
|
|
181
|
-
type
|
|
182
|
-
type CreateAuthorizationRequestResult = CreateAuthorizationRequestResultAPTITUDE | CreateAuthorizationRequestResultV1_0 | CreateAuthorizationRequestResultV1_3 | CreateAuthorizationRequestResultV1_4;
|
|
179
|
+
type CreateAuthorizationRequestResult = CreateAuthorizationRequestResultV1_0 | CreateAuthorizationRequestResultV1_3 | CreateAuthorizationRequestResultV1_4;
|
|
183
180
|
/**
|
|
184
181
|
* Creates an OpenID4VP authorization request URL for the configured IT-Wallet version.
|
|
185
182
|
*
|
|
@@ -1231,4 +1228,4 @@ interface ParseJarmAuthorizationResponseOptions {
|
|
|
1231
1228
|
*/
|
|
1232
1229
|
declare function parseJarmAuthorizationResponse(options: ParseJarmAuthorizationResponseOptions): Promise<ParseAuthorizationResponseResult>;
|
|
1233
1230
|
|
|
1234
|
-
export { type AuthorizationRequestUrlParams, type CertificateEndpoint, type ClientIdParts, ClientIdPrefix, type CreateAuthorizationRequestOptions, type
|
|
1231
|
+
export { type AuthorizationRequestUrlParams, type CertificateEndpoint, type ClientIdParts, ClientIdPrefix, type CreateAuthorizationRequestOptions, type CreateAuthorizationRequestOptionsV1_0, type CreateAuthorizationRequestOptionsV1_3, type CreateAuthorizationRequestOptionsV1_4, type CreateAuthorizationRequestResult, type CreateAuthorizationRequestResultV1_0, type CreateAuthorizationRequestResultV1_3, type CreateAuthorizationRequestResultV1_4, CreateAuthorizationResponseError, type CreateAuthorizationResponseOptionsV1_0, type CreateAuthorizationResponseOptionsV1_3, type CreateAuthorizationResponseOptionsV1_4, type CreateAuthorizationResponseResult, type CreateAuthorizationResponseVersionedOptions, type CreateOpenid4vpAuthorizationResponseOptions, type CreateOpenid4vpAuthorizationResponseResult, type EncryptedJarmHeader, type FetchAuthorizationRequestOptions, type FetchAuthorizationRequestResult, FetchAuthorizationResponseError, type FetchAuthorizationResponseOptions, type GetX509CertificateMetadataCallback, InvalidRequestUriMethodError, type JarOptionsV1_0, type JarOptionsV1_3, type JarOptionsV1_4, type JarmAuthorizationResponse, type JarmAuthorizationResponseEncryptedOnly, type JarmClientMetadata, type JarmHeader, JarmMode, type JarmServerMetadata, Oid4vpError, type Openid4vpAuthorizationRequestHeader, type Openid4vpAuthorizationRequestHeaderV1_0, type Openid4vpAuthorizationRequestHeaderV1_3, type Openid4vpAuthorizationRequestPayload, type Openid4vpAuthorizationResponse, type Openid4vpAuthorizationResponsePayload, type Openid4vpAuthorizationResponseResult, type ParseAuthorizationResponseOptions, type ParseAuthorizationResponseResult, ParseAuthorizeRequestError, type ParseAuthorizeRequestOptions, type ParseJarmAuthorizationResponseOptions, type ParsedAuthorizeRequestResult, type ParsedQrCode, type ValidateCertificateEndpointsOptions, type ValidateOpenid4vpAuthorizationResponseOptions, type ValidateOpenid4vpAuthorizationResponseResult, type VerifyJarmAuthorizationResponseOptions, type VerifyJarmAuthorizationResponseResult, type VpToken, type VpTokenPresentationEntry, type X509CertificateBinding, type X509CertificateMetadata, createAuthorizationRequest, createAuthorizationResponse, createOpenid4vpAuthorizationResponse, createParsedQrCode, createX509HashClientId, extractClientIdPrefix, extractEncryptionJwkFromJwks, fetchAuthorizationRequest, fetchAuthorizationResponse, fetchRequestObjectJwt, parseAuthorizationResponse, parseAuthorizeRequest, parseJarmAuthorizationResponse, parseVpToken, validateAuthorizationRequestParams, validateCertificateEndpoints, validateOpenid4vpAuthorizationResponsePayload, verifyJarmAuthorizationResponse, zAuthorizationRequestUrlParams, zEncryptedJarmHeader, zJarmAuthorizationResponse, zJarmAuthorizationResponseEncryptedOnly, zJarmHeader, zOpenid4vpAuthorizationRequestHeaderV1_0, zOpenid4vpAuthorizationRequestHeaderV1_3, zOpenid4vpAuthorizationRequestPayload, zOpenid4vpAuthorizationResponse, zOpenid4vpAuthorizationResponseResult, zVpToken };
|
package/dist/index.js
CHANGED
|
@@ -235,10 +235,6 @@ var zOpenid4vpAuthorizationRequestHeaderV1_3 = zOpenid4vpAuthorizationRequestHea
|
|
|
235
235
|
|
|
236
236
|
// src/authorization-request/create-authorization-request.ts
|
|
237
237
|
var dispatchCreateAuthorizationRequest = (0, import_io_wallet_utils3.createVersionDispatcher)({
|
|
238
|
-
[import_io_wallet_utils3.ItWalletSpecsVersion.APTITUDE]: async (o) => createAuthorizationRequestWithHeader(
|
|
239
|
-
o,
|
|
240
|
-
zOpenid4vpAuthorizationRequestHeaderV1_3
|
|
241
|
-
),
|
|
242
238
|
[import_io_wallet_utils3.ItWalletSpecsVersion.V1_0]: async (o) => createAuthorizationRequestWithHeader(
|
|
243
239
|
o,
|
|
244
240
|
zOpenid4vpAuthorizationRequestHeaderV1_0
|
|
@@ -572,7 +568,6 @@ function getPublicKeyForVerification(options) {
|
|
|
572
568
|
async function parseAuthorizeRequest(options) {
|
|
573
569
|
try {
|
|
574
570
|
const headerSchema = (0, import_io_wallet_utils5.dispatchByVersion)(options.config.itWalletSpecsVersion, {
|
|
575
|
-
[import_io_wallet_utils5.ItWalletSpecsVersion.APTITUDE]: () => zOpenid4vpAuthorizationRequestHeaderV1_3,
|
|
576
571
|
[import_io_wallet_utils5.ItWalletSpecsVersion.V1_0]: () => zOpenid4vpAuthorizationRequestHeaderV1_0,
|
|
577
572
|
[import_io_wallet_utils5.ItWalletSpecsVersion.V1_3]: () => zOpenid4vpAuthorizationRequestHeaderV1_3,
|
|
578
573
|
[import_io_wallet_utils5.ItWalletSpecsVersion.V1_4]: () => zOpenid4vpAuthorizationRequestHeaderV1_3
|
|
@@ -777,9 +772,6 @@ async function createAuthorizationResponse2(options) {
|
|
|
777
772
|
|
|
778
773
|
// src/authorization-response/create-authorization-response.ts
|
|
779
774
|
var dispatchCreateAuthorizationResponse = (0, import_io_wallet_utils7.createVersionDispatcher)({
|
|
780
|
-
[import_io_wallet_utils7.ItWalletSpecsVersion.APTITUDE]: (o) => createAuthorizationResponse2(
|
|
781
|
-
o
|
|
782
|
-
),
|
|
783
775
|
[import_io_wallet_utils7.ItWalletSpecsVersion.V1_0]: (o) => (
|
|
784
776
|
// V1_0 shares the v1.3 response logic — JWKS / enc resolution is identical.
|
|
785
777
|
createAuthorizationResponse(
|