@pagopa/io-react-native-jwt 0.4.1
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/LICENSE +20 -0
- package/README.md +145 -0
- package/android/build.gradle +97 -0
- package/android/gradle.properties +5 -0
- package/android/src/main/AndroidManifest.xml +4 -0
- package/android/src/main/java/com/pagopa/ioreactnativejwt/IoReactNativeJwtModule.kt +114 -0
- package/android/src/main/java/com/pagopa/ioreactnativejwt/IoReactNativeJwtPackage.kt +17 -0
- package/android/src/main/java/com/pagopa/ioreactnativejwt/Utils.kt +95 -0
- package/ios/ASN1DERParsing.swift +226 -0
- package/ios/IoReactNativeJwt-Bridging-Header.h +2 -0
- package/ios/IoReactNativeJwt.mm +28 -0
- package/ios/IoReactNativeJwt.swift +156 -0
- package/ios/IoReactNativeJwt.xcodeproj/project.pbxproj +283 -0
- package/lib/commonjs/algorithms.js +39 -0
- package/lib/commonjs/algorithms.js.map +1 -0
- package/lib/commonjs/hash.js +17 -0
- package/lib/commonjs/hash.js.map +1 -0
- package/lib/commonjs/index.js +194 -0
- package/lib/commonjs/index.js.map +1 -0
- package/lib/commonjs/jwt_claims_set.js +112 -0
- package/lib/commonjs/jwt_claims_set.js.map +1 -0
- package/lib/commonjs/produce.js +140 -0
- package/lib/commonjs/produce.js.map +1 -0
- package/lib/commonjs/sign.js +159 -0
- package/lib/commonjs/sign.js.map +1 -0
- package/lib/commonjs/types.js +2 -0
- package/lib/commonjs/types.js.map +1 -0
- package/lib/commonjs/unsecured.js +118 -0
- package/lib/commonjs/unsecured.js.map +1 -0
- package/lib/commonjs/utils/asn1.js +37 -0
- package/lib/commonjs/utils/asn1.js.map +1 -0
- package/lib/commonjs/utils/base64.js +43 -0
- package/lib/commonjs/utils/base64.js.map +1 -0
- package/lib/commonjs/utils/errors.js +214 -0
- package/lib/commonjs/utils/errors.js.map +1 -0
- package/lib/commonjs/utils/is_object.js +23 -0
- package/lib/commonjs/utils/is_object.js.map +1 -0
- package/lib/commonjs/utils/proxy.js +17 -0
- package/lib/commonjs/utils/proxy.js.map +1 -0
- package/lib/commonjs/utils/secs.js +61 -0
- package/lib/commonjs/utils/secs.js.map +1 -0
- package/lib/module/algorithms.js +29 -0
- package/lib/module/algorithms.js.map +1 -0
- package/lib/module/hash.js +11 -0
- package/lib/module/hash.js.map +1 -0
- package/lib/module/index.js +115 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/jwt_claims_set.js +103 -0
- package/lib/module/jwt_claims_set.js.map +1 -0
- package/lib/module/produce.js +131 -0
- package/lib/module/produce.js.map +1 -0
- package/lib/module/sign.js +153 -0
- package/lib/module/sign.js.map +1 -0
- package/lib/module/types.js +2 -0
- package/lib/module/types.js.map +1 -0
- package/lib/module/unsecured.js +110 -0
- package/lib/module/unsecured.js.map +1 -0
- package/lib/module/utils/asn1.js +31 -0
- package/lib/module/utils/asn1.js.map +1 -0
- package/lib/module/utils/base64.js +36 -0
- package/lib/module/utils/base64.js.map +1 -0
- package/lib/module/utils/errors.js +200 -0
- package/lib/module/utils/errors.js.map +1 -0
- package/lib/module/utils/is_object.js +17 -0
- package/lib/module/utils/is_object.js.map +1 -0
- package/lib/module/utils/proxy.js +10 -0
- package/lib/module/utils/proxy.js.map +1 -0
- package/lib/module/utils/secs.js +53 -0
- package/lib/module/utils/secs.js.map +1 -0
- package/lib/typescript/algorithms.d.ts +5 -0
- package/lib/typescript/algorithms.d.ts.map +1 -0
- package/lib/typescript/hash.d.ts +5 -0
- package/lib/typescript/hash.d.ts.map +1 -0
- package/lib/typescript/index.d.ts +93 -0
- package/lib/typescript/index.d.ts.map +1 -0
- package/lib/typescript/jwt_claims_set.d.ts +4 -0
- package/lib/typescript/jwt_claims_set.d.ts.map +1 -0
- package/lib/typescript/produce.d.ts +55 -0
- package/lib/typescript/produce.d.ts.map +1 -0
- package/lib/typescript/sign.d.ts +61 -0
- package/lib/typescript/sign.d.ts.map +1 -0
- package/lib/typescript/types.d.ts +172 -0
- package/lib/typescript/types.d.ts.map +1 -0
- package/lib/typescript/unsecured.d.ts +64 -0
- package/lib/typescript/unsecured.d.ts.map +1 -0
- package/lib/typescript/utils/asn1.d.ts +2 -0
- package/lib/typescript/utils/asn1.d.ts.map +1 -0
- package/lib/typescript/utils/base64.d.ts +4 -0
- package/lib/typescript/utils/base64.d.ts.map +1 -0
- package/lib/typescript/utils/errors.d.ts +157 -0
- package/lib/typescript/utils/errors.d.ts.map +1 -0
- package/lib/typescript/utils/is_object.d.ts +2 -0
- package/lib/typescript/utils/is_object.d.ts.map +1 -0
- package/lib/typescript/utils/proxy.d.ts +2 -0
- package/lib/typescript/utils/proxy.d.ts.map +1 -0
- package/lib/typescript/utils/secs.d.ts +4 -0
- package/lib/typescript/utils/secs.d.ts.map +1 -0
- package/package.json +170 -0
- package/pagopa-io-react-native-jwt.podspec +44 -0
- package/src/algorithms.ts +46 -0
- package/src/hash.ts +10 -0
- package/src/index.tsx +120 -0
- package/src/jwt_claims_set.ts +194 -0
- package/src/produce.ts +109 -0
- package/src/sign.ts +180 -0
- package/src/types.ts +203 -0
- package/src/unsecured.ts +127 -0
- package/src/utils/asn1.ts +36 -0
- package/src/utils/base64.ts +37 -0
- package/src/utils/errors.ts +206 -0
- package/src/utils/is_object.ts +20 -0
- package/src/utils/proxy.ts +15 -0
- package/src/utils/secs.ts +58 -0
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import type { JWTPayload } from './types';
|
|
2
|
+
/** Generic class for JWT producing. */
|
|
3
|
+
export declare class ProduceJWT {
|
|
4
|
+
protected _payload: JWTPayload;
|
|
5
|
+
/** @param payload The JWT Claims Set object. */
|
|
6
|
+
constructor(payload: JWTPayload);
|
|
7
|
+
/**
|
|
8
|
+
* Set "iss" (Issuer) Claim.
|
|
9
|
+
*
|
|
10
|
+
* @param issuer "Issuer" Claim value to set on the JWT Claims Set.
|
|
11
|
+
*/
|
|
12
|
+
setIssuer(issuer: string): this;
|
|
13
|
+
/**
|
|
14
|
+
* Set "sub" (Subject) Claim.
|
|
15
|
+
*
|
|
16
|
+
* @param subject "sub" (Subject) Claim value to set on the JWT Claims Set.
|
|
17
|
+
*/
|
|
18
|
+
setSubject(subject: string): this;
|
|
19
|
+
/**
|
|
20
|
+
* Set "aud" (Audience) Claim.
|
|
21
|
+
*
|
|
22
|
+
* @param audience "aud" (Audience) Claim value to set on the JWT Claims Set.
|
|
23
|
+
*/
|
|
24
|
+
setAudience(audience: string | string[]): this;
|
|
25
|
+
/**
|
|
26
|
+
* Set "jti" (JWT ID) Claim.
|
|
27
|
+
*
|
|
28
|
+
* @param jwtId "jti" (JWT ID) Claim value to set on the JWT Claims Set.
|
|
29
|
+
*/
|
|
30
|
+
setJti(jwtId: string): this;
|
|
31
|
+
/**
|
|
32
|
+
* Set "nbf" (Not Before) Claim.
|
|
33
|
+
*
|
|
34
|
+
* @param input "nbf" (Not Before) Claim value to set on the JWT Claims Set. When number is passed
|
|
35
|
+
* that is used as a value, when string is passed it is resolved to a time span and added to the
|
|
36
|
+
* current timestamp.
|
|
37
|
+
*/
|
|
38
|
+
setNotBefore(input: number | string): this;
|
|
39
|
+
/**
|
|
40
|
+
* Set "exp" (Expiration Time) Claim.
|
|
41
|
+
*
|
|
42
|
+
* @param input "exp" (Expiration Time) Claim value to set on the JWT Claims Set. When number is
|
|
43
|
+
* passed that is used as a value, when string is passed it is resolved to a time span and added
|
|
44
|
+
* to the current timestamp.
|
|
45
|
+
*/
|
|
46
|
+
setExpirationTime(input: number | string): this;
|
|
47
|
+
/**
|
|
48
|
+
* Set "iat" (Issued At) Claim.
|
|
49
|
+
*
|
|
50
|
+
* @param input "iat" (Issued At) Claim value to set on the JWT Claims Set. Default is current
|
|
51
|
+
* timestamp.
|
|
52
|
+
*/
|
|
53
|
+
setIssuedAt(input?: number): this;
|
|
54
|
+
}
|
|
55
|
+
//# sourceMappingURL=produce.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"produce.d.ts","sourceRoot":"","sources":["../../src/produce.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAC;AAI1C,uCAAuC;AACvC,qBAAa,UAAU;IACrB,SAAS,CAAC,QAAQ,EAAG,UAAU,CAAC;IAEhC,gDAAgD;gBACpC,OAAO,EAAE,UAAU;IAO/B;;;;OAIG;IACH,SAAS,CAAC,MAAM,EAAE,MAAM;IAKxB;;;;OAIG;IACH,UAAU,CAAC,OAAO,EAAE,MAAM;IAK1B;;;;OAIG;IACH,WAAW,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,EAAE;IAKvC;;;;OAIG;IACH,MAAM,CAAC,KAAK,EAAE,MAAM;IAKpB;;;;;;OAMG;IACH,YAAY,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM;IAYnC;;;;;;OAMG;IACH,iBAAiB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM;IAYxC;;;;;OAKG;IACH,WAAW,CAAC,KAAK,CAAC,EAAE,MAAM;CAQ3B"}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import type { CompactJWSHeaderParameters, JWTDecodeResult, JWTPayload } from './types';
|
|
2
|
+
import { ProduceJWT } from './produce';
|
|
3
|
+
/**
|
|
4
|
+
* The SignJWT class is used to build and sign Compact JWS formatted JSON Web Tokens.
|
|
5
|
+
*
|
|
6
|
+
* @example Usage with a given signature
|
|
7
|
+
*
|
|
8
|
+
* ```js
|
|
9
|
+
* const alg = 'RS256'
|
|
10
|
+
* const signature = 'Axy0....'
|
|
11
|
+
*
|
|
12
|
+
* const jwt = new SignJWT({ 'urn:example:claim': true })
|
|
13
|
+
* .setProtectedHeader({ alg })
|
|
14
|
+
* .setIssuedAt()
|
|
15
|
+
* .setIssuer('urn:example:issuer')
|
|
16
|
+
* .setAudience('urn:example:audience')
|
|
17
|
+
* .setExpirationTime('2h')
|
|
18
|
+
* .sign(signature)
|
|
19
|
+
*
|
|
20
|
+
* console.log(jwt)
|
|
21
|
+
* ```
|
|
22
|
+
*/
|
|
23
|
+
export declare class SignJWT extends ProduceJWT {
|
|
24
|
+
private _protectedHeader;
|
|
25
|
+
/**
|
|
26
|
+
* Sets the JWS Protected Header on the SignJWT object.
|
|
27
|
+
*
|
|
28
|
+
* @param protectedHeader JWS Protected Header. Must contain an "alg" (JWS Algorithm) property.
|
|
29
|
+
*/
|
|
30
|
+
setProtectedHeader(protectedHeader: CompactJWSHeaderParameters): this;
|
|
31
|
+
/**
|
|
32
|
+
* Return a JWT without signature (`header.payload`) to sign.
|
|
33
|
+
*
|
|
34
|
+
*/
|
|
35
|
+
toSign(): string;
|
|
36
|
+
/**
|
|
37
|
+
* Append signature to unsigned JWT.
|
|
38
|
+
* For an ECDSA signature it is required that this is in ASN.1/DER encoded format.
|
|
39
|
+
* The same format used by the TEE. Conversion to JWS is handled automatically.
|
|
40
|
+
*
|
|
41
|
+
* @param jwtWithoutSignature
|
|
42
|
+
* @param signature
|
|
43
|
+
*/
|
|
44
|
+
static appendSignature(jwtWithoutSignature: string, signature: string): Promise<string>;
|
|
45
|
+
/**
|
|
46
|
+
* Decodes a JWT without signature
|
|
47
|
+
*
|
|
48
|
+
* @param jwtWithoutSignature JWT to sign that needs to be decoded.
|
|
49
|
+
*/
|
|
50
|
+
static decodeJwtWithoutSignature(jwtWithoutSignature: string): {
|
|
51
|
+
payload: JWTPayload;
|
|
52
|
+
header: CompactJWSHeaderParameters;
|
|
53
|
+
};
|
|
54
|
+
/**
|
|
55
|
+
* Decodes a JWT without signature
|
|
56
|
+
*
|
|
57
|
+
* @param jwtWithoutSignature JWT to sign that needs to be decoded.
|
|
58
|
+
*/
|
|
59
|
+
static decode(jwt: string): JWTDecodeResult;
|
|
60
|
+
}
|
|
61
|
+
//# sourceMappingURL=sign.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sign.d.ts","sourceRoot":"","sources":["../../src/sign.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EACV,0BAA0B,EAC1B,eAAe,EACf,UAAU,EACX,MAAM,SAAS,CAAC;AACjB,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAMvC;;;;;;;;;;;;;;;;;;;GAmBG;AACH,qBAAa,OAAQ,SAAQ,UAAU;IACrC,OAAO,CAAC,gBAAgB,CAA8B;IAEtD;;;;OAIG;IACH,kBAAkB,CAAC,eAAe,EAAE,0BAA0B;IAQ9D;;;OAGG;IACH,MAAM,IAAI,MAAM;IAehB;;;;;;;OAOG;WACU,eAAe,CAC1B,mBAAmB,EAAE,MAAM,EAC3B,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,MAAM,CAAC;IAoBlB;;;;OAIG;IACH,MAAM,CAAC,yBAAyB,CAAC,mBAAmB,EAAE,MAAM,GAAG;QAC7D,OAAO,EAAE,UAAU,CAAC;QACpB,MAAM,EAAE,0BAA0B,CAAC;KACpC;IAkCD;;;;OAIG;IACH,MAAM,CAAC,MAAM,CAAC,GAAG,EAAE,MAAM,GAAG,eAAe;CAkC5C"}
|
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
export interface JWTDecodeResult {
|
|
2
|
+
/** JWT Claims Set. */
|
|
3
|
+
payload: JWTPayload;
|
|
4
|
+
/** JWS Protected Header. */
|
|
5
|
+
protectedHeader: JWSHeaderParameters;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* JSON Web Key ({@link https://www.rfc-editor.org/rfc/rfc7517 JWK}). "RSA", "EC", "OKP", and "oct"
|
|
9
|
+
* key types are supported.
|
|
10
|
+
*/
|
|
11
|
+
export interface JWK {
|
|
12
|
+
/** JWK "alg" (Algorithm) Parameter. */
|
|
13
|
+
'alg'?: string;
|
|
14
|
+
'crv'?: string;
|
|
15
|
+
'd'?: string;
|
|
16
|
+
'dp'?: string;
|
|
17
|
+
'dq'?: string;
|
|
18
|
+
'e'?: string;
|
|
19
|
+
/** JWK "ext" (Extractable) Parameter. */
|
|
20
|
+
'ext'?: boolean;
|
|
21
|
+
'k'?: string;
|
|
22
|
+
/** JWK "key_ops" (Key Operations) Parameter. */
|
|
23
|
+
'key_ops'?: string[];
|
|
24
|
+
/** JWK "kid" (Key ID) Parameter. */
|
|
25
|
+
'kid'?: string;
|
|
26
|
+
/** JWK "kty" (Key Type) Parameter.
|
|
27
|
+
* This attribute is required to discriminate the
|
|
28
|
+
* type of EC/RSA algorithm */
|
|
29
|
+
'kty': string;
|
|
30
|
+
'n'?: string;
|
|
31
|
+
'oth'?: Array<{
|
|
32
|
+
d?: string;
|
|
33
|
+
r?: string;
|
|
34
|
+
t?: string;
|
|
35
|
+
}>;
|
|
36
|
+
'p'?: string;
|
|
37
|
+
'q'?: string;
|
|
38
|
+
'qi'?: string;
|
|
39
|
+
/** JWK "use" (Public Key Use) Parameter. */
|
|
40
|
+
'use'?: string;
|
|
41
|
+
'x'?: string;
|
|
42
|
+
'y'?: string;
|
|
43
|
+
/** JWK "x5c" (X.509 Certificate Chain) Parameter. */
|
|
44
|
+
'x5c'?: string[];
|
|
45
|
+
/** JWK "x5t" (X.509 Certificate SHA-1 Thumbprint) Parameter. */
|
|
46
|
+
'x5t'?: string;
|
|
47
|
+
/** "x5t#S256" (X.509 Certificate SHA-256 Thumbprint) Parameter. */
|
|
48
|
+
'x5t#S256'?: string;
|
|
49
|
+
/** JWK "x5u" (X.509 URL) Parameter. */
|
|
50
|
+
'x5u'?: string;
|
|
51
|
+
[propName: string]: unknown;
|
|
52
|
+
}
|
|
53
|
+
export interface JoseHeaderParameters {
|
|
54
|
+
/** "kid" (Key ID) Header Parameter. */
|
|
55
|
+
kid?: string;
|
|
56
|
+
/** "x5t" (X.509 Certificate SHA-1 Thumbprint) Header Parameter. */
|
|
57
|
+
x5t?: string;
|
|
58
|
+
/** "x5c" (X.509 Certificate Chain) Header Parameter. */
|
|
59
|
+
x5c?: string[];
|
|
60
|
+
/** "x5u" (X.509 URL) Header Parameter. */
|
|
61
|
+
x5u?: string;
|
|
62
|
+
/** "jku" (JWK Set URL) Header Parameter. */
|
|
63
|
+
jku?: string;
|
|
64
|
+
/** "jwk" (JSON Web Key) Header Parameter. */
|
|
65
|
+
jwk?: Pick<JWK, 'kty' | 'crv' | 'x' | 'y' | 'e' | 'n'>;
|
|
66
|
+
/** "typ" (Type) Header Parameter. */
|
|
67
|
+
typ?: string;
|
|
68
|
+
/** "cty" (Content Type) Header Parameter. */
|
|
69
|
+
cty?: string;
|
|
70
|
+
}
|
|
71
|
+
/** Recognized JWS Header Parameters, any other Header Members may also be present. */
|
|
72
|
+
export interface JWSHeaderParameters extends JoseHeaderParameters {
|
|
73
|
+
/** JWS "alg" (Algorithm) Header Parameter. */
|
|
74
|
+
alg?: string;
|
|
75
|
+
/**
|
|
76
|
+
* This JWS Extension Header Parameter modifies the JWS Payload representation and the JWS Signing
|
|
77
|
+
* Input computation as per {@link https://www.rfc-editor.org/rfc/rfc7797 RFC7797}.
|
|
78
|
+
*/
|
|
79
|
+
b64?: boolean;
|
|
80
|
+
/** JWS "crit" (Critical) Header Parameter. */
|
|
81
|
+
crit?: string[];
|
|
82
|
+
/** Any other JWS Header member. */
|
|
83
|
+
[propName: string]: unknown;
|
|
84
|
+
}
|
|
85
|
+
/** Recognized Compact JWS Header Parameters, any other Header Members may also be present. */
|
|
86
|
+
export interface CompactJWSHeaderParameters extends JWSHeaderParameters {
|
|
87
|
+
alg: string;
|
|
88
|
+
}
|
|
89
|
+
/** Recognized JWT Claims Set members, any other members may also be present. */
|
|
90
|
+
export interface JWTPayload {
|
|
91
|
+
/**
|
|
92
|
+
* JWT Issuer
|
|
93
|
+
*
|
|
94
|
+
* @see {@link https://www.rfc-editor.org/rfc/rfc7519#section-4.1.1 RFC7519#section-4.1.1}
|
|
95
|
+
*/
|
|
96
|
+
iss?: string;
|
|
97
|
+
/**
|
|
98
|
+
* JWT Subject
|
|
99
|
+
*
|
|
100
|
+
* @see {@link https://www.rfc-editor.org/rfc/rfc7519#section-4.1.2 RFC7519#section-4.1.2}
|
|
101
|
+
*/
|
|
102
|
+
sub?: string;
|
|
103
|
+
/**
|
|
104
|
+
* JWT Audience
|
|
105
|
+
*
|
|
106
|
+
* @see {@link https://www.rfc-editor.org/rfc/rfc7519#section-4.1.3 RFC7519#section-4.1.3}
|
|
107
|
+
*/
|
|
108
|
+
aud?: string | string[];
|
|
109
|
+
/**
|
|
110
|
+
* JWT ID
|
|
111
|
+
*
|
|
112
|
+
* @see {@link https://www.rfc-editor.org/rfc/rfc7519#section-4.1.7 RFC7519#section-4.1.7}
|
|
113
|
+
*/
|
|
114
|
+
jti?: string;
|
|
115
|
+
/**
|
|
116
|
+
* JWT Not Before
|
|
117
|
+
*
|
|
118
|
+
* @see {@link https://www.rfc-editor.org/rfc/rfc7519#section-4.1.5 RFC7519#section-4.1.5}
|
|
119
|
+
*/
|
|
120
|
+
nbf?: number;
|
|
121
|
+
/**
|
|
122
|
+
* JWT Expiration Time
|
|
123
|
+
*
|
|
124
|
+
* @see {@link https://www.rfc-editor.org/rfc/rfc7519#section-4.1.4 RFC7519#section-4.1.4}
|
|
125
|
+
*/
|
|
126
|
+
exp?: number;
|
|
127
|
+
/**
|
|
128
|
+
* JWT Issued At
|
|
129
|
+
*
|
|
130
|
+
* @see {@link https://www.rfc-editor.org/rfc/rfc7519#section-4.1.6 RFC7519#section-4.1.6}
|
|
131
|
+
*/
|
|
132
|
+
iat?: number;
|
|
133
|
+
/** Any other JWT Claim Set member. */
|
|
134
|
+
[propName: string]: unknown;
|
|
135
|
+
}
|
|
136
|
+
/** JWT Claims Set verification options. */
|
|
137
|
+
export interface JWTClaimVerificationOptions {
|
|
138
|
+
/** Expected JWT "aud" (Audience) Claim value(s). */
|
|
139
|
+
audience?: string | string[];
|
|
140
|
+
/**
|
|
141
|
+
* Expected clock tolerance
|
|
142
|
+
*
|
|
143
|
+
* - In seconds when number (e.g. 5)
|
|
144
|
+
* - Parsed as seconds when a string (e.g. "5 seconds", "10 minutes", "2 hours").
|
|
145
|
+
*/
|
|
146
|
+
clockTolerance?: string | number;
|
|
147
|
+
/** Expected JWT "iss" (Issuer) Claim value(s). */
|
|
148
|
+
issuer?: string | string[];
|
|
149
|
+
/**
|
|
150
|
+
* Maximum time elapsed (in seconds) from the JWT "iat" (Issued At) Claim value.
|
|
151
|
+
*
|
|
152
|
+
* - In seconds when number (e.g. 5)
|
|
153
|
+
* - Parsed as seconds when a string (e.g. "5 seconds", "10 minutes", "2 hours").
|
|
154
|
+
*/
|
|
155
|
+
maxTokenAge?: string | number;
|
|
156
|
+
/** Expected JWT "sub" (Subject) Claim value. */
|
|
157
|
+
subject?: string;
|
|
158
|
+
/** Expected JWT "typ" (Type) Header Parameter value. */
|
|
159
|
+
typ?: string;
|
|
160
|
+
/** Date to use when comparing NumericDate claims, defaults to `new Date()`. */
|
|
161
|
+
currentDate?: Date;
|
|
162
|
+
/**
|
|
163
|
+
* Array of required Claim Names that must be present in the JWT Claims Set. Default is that: if
|
|
164
|
+
* the {@link JWTClaimVerificationOptions.issuer issuer option} is set, then "iss" must be present;
|
|
165
|
+
* if the {@link JWTClaimVerificationOptions.audience audience option} is set, then "aud" must be
|
|
166
|
+
* present; if the {@link JWTClaimVerificationOptions.subject subject option} is set, then "sub"
|
|
167
|
+
* must be present; if the {@link JWTClaimVerificationOptions.maxTokenAge maxTokenAge option} is
|
|
168
|
+
* set, then "iat" must be present.
|
|
169
|
+
*/
|
|
170
|
+
requiredClaims?: string[];
|
|
171
|
+
}
|
|
172
|
+
//# sourceMappingURL=types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/types.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,eAAe;IAC9B,sBAAsB;IACtB,OAAO,EAAE,UAAU,CAAC;IAEpB,4BAA4B;IAC5B,eAAe,EAAE,mBAAmB,CAAC;CACtC;AAED;;;GAGG;AACH,MAAM,WAAW,GAAG;IAClB,uCAAuC;IACvC,KAAK,CAAC,EAAE,MAAM,CAAC;IAC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G,OAAO,CAAC;CAC7B;AAED,2CAA2C;AAC3C,MAAM,WAAW,2BAA2B;IAC1C,oDAAoD;IACpD,QAAQ,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAE7B;;;;;OAKG;IACH,cAAc,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAEjC,kDAAkD;IAClD,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,CAAC;IAE3B;;;;;OAKG;IACH,WAAW,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IAE9B,gDAAgD;IAChD,OAAO,CAAC,EAAE,MAAM,CAAC;IAEjB,wDAAwD;IACxD,GAAG,CAAC,EAAE,MAAM,CAAC;IAEb,+EAA+E;IAC/E,WAAW,CAAC,EAAE,IAAI,CAAC;IAEnB;;;;;;;OAOG;IACH,cAAc,CAAC,EAAE,MAAM,EAAE,CAAC;CAC3B"}
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
import type { JWSHeaderParameters, JWTClaimVerificationOptions, JWTPayload } from './types';
|
|
2
|
+
import { ProduceJWT } from './produce';
|
|
3
|
+
export interface UnsecuredResult {
|
|
4
|
+
payload: JWTPayload;
|
|
5
|
+
header: JWSHeaderParameters;
|
|
6
|
+
}
|
|
7
|
+
/**
|
|
8
|
+
* The UnsecuredJWT class is a utility for dealing with `{ "alg": "none" }` Unsecured JWTs.
|
|
9
|
+
*
|
|
10
|
+
* @example Encoding
|
|
11
|
+
*
|
|
12
|
+
* ```js
|
|
13
|
+
* const unsecuredJwt = new UnsecuredJWT({ 'urn:example:claim': true })
|
|
14
|
+
* .setIssuedAt()
|
|
15
|
+
* .setIssuer('urn:example:issuer')
|
|
16
|
+
* .setAudience('urn:example:audience')
|
|
17
|
+
* .setExpirationTime('2h')
|
|
18
|
+
* .encode()
|
|
19
|
+
*
|
|
20
|
+
* console.log(unsecuredJwt)
|
|
21
|
+
* ```
|
|
22
|
+
*
|
|
23
|
+
* @example Decoding
|
|
24
|
+
*
|
|
25
|
+
* ```js
|
|
26
|
+
* const payload = UnsecuredJWT.decode(jwt, {
|
|
27
|
+
* issuer: 'urn:example:issuer',
|
|
28
|
+
* audience: 'urn:example:audience',
|
|
29
|
+
* })
|
|
30
|
+
*
|
|
31
|
+
* console.log(payload)
|
|
32
|
+
* ```
|
|
33
|
+
* * @example JWT content ToSign
|
|
34
|
+
*
|
|
35
|
+
* ```js
|
|
36
|
+
* const jwtToSign = new UnsecuredJWT({ 'urn:example:claim': true })
|
|
37
|
+
* .setIssuedAt()
|
|
38
|
+
* .setIssuer('urn:example:issuer')
|
|
39
|
+
* .setAudience('urn:example:audience')
|
|
40
|
+
* .setExpirationTime('2h')
|
|
41
|
+
* .toSign()
|
|
42
|
+
*
|
|
43
|
+
* console.log(jwtToSign)
|
|
44
|
+
* ```
|
|
45
|
+
*/
|
|
46
|
+
export declare class UnsecuredJWT extends ProduceJWT {
|
|
47
|
+
/** Encodes the Unsecured JWT. */
|
|
48
|
+
encode(): string;
|
|
49
|
+
/**
|
|
50
|
+
* Decodes an unsecured JWT.
|
|
51
|
+
*
|
|
52
|
+
* @param jwt Unsecured JWT to decode the payload of.
|
|
53
|
+
* @param options JWT Claims Set validation options.
|
|
54
|
+
*/
|
|
55
|
+
static decode(jwt: string, options?: JWTClaimVerificationOptions): UnsecuredResult;
|
|
56
|
+
/**
|
|
57
|
+
* Decodes an unsecured JWT payload.
|
|
58
|
+
*
|
|
59
|
+
* @param jwt Unsecured JWT payload to decode.
|
|
60
|
+
* @param options JWT Claims Set validation options.
|
|
61
|
+
*/
|
|
62
|
+
static decodePayload(jwt: string, options?: JWTClaimVerificationOptions): JWTPayload;
|
|
63
|
+
}
|
|
64
|
+
//# sourceMappingURL=unsecured.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"unsecured.d.ts","sourceRoot":"","sources":["../../src/unsecured.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,mBAAmB,EACnB,2BAA2B,EAC3B,UAAU,EACX,MAAM,SAAS,CAAC;AAIjB,OAAO,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAGvC,MAAM,WAAW,eAAe;IAC9B,OAAO,EAAE,UAAU,CAAC;IACpB,MAAM,EAAE,mBAAmB,CAAC;CAC7B;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAsCG;AACH,qBAAa,YAAa,SAAQ,UAAU;IAC1C,iCAAiC;IACjC,MAAM,IAAI,MAAM;IAOhB;;;;;OAKG;IACH,MAAM,CAAC,MAAM,CACX,GAAG,EAAE,MAAM,EACX,OAAO,CAAC,EAAE,2BAA2B,GACpC,eAAe;IA6BlB;;;;;OAKG;IACH,MAAM,CAAC,aAAa,CAClB,GAAG,EAAE,MAAM,EACX,OAAO,CAAC,EAAE,2BAA2B,GACpC,UAAU;CAed"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"asn1.d.ts","sourceRoot":"","sources":["../../../src/utils/asn1.ts"],"names":[],"mappings":"AAoBA,eAAO,MAAM,SAAS,kBACL,MAAM,OAChB,MAAM,KACV,QAAQ,MAAM,CAYhB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"base64.d.ts","sourceRoot":"","sources":["../../../src/utils/base64.ts"],"names":[],"mappings":"AAeA,wBAAgB,YAAY,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAOlD;AAED,wBAAgB,YAAY,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAOlD;AAED,wBAAgB,aAAa,CAAC,OAAO,EAAE,MAAM,GAAG,MAAM,CAGrD"}
|
|
@@ -0,0 +1,157 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* A generic Error that all other JOSE specific Error subclasses extend.
|
|
3
|
+
*
|
|
4
|
+
* @example Checking thrown error is a JOSE one
|
|
5
|
+
*
|
|
6
|
+
* ```js
|
|
7
|
+
* if (err instanceof errors.JOSEError) {
|
|
8
|
+
* // ...
|
|
9
|
+
* }
|
|
10
|
+
* ```
|
|
11
|
+
*/
|
|
12
|
+
export declare class JOSEError extends Error {
|
|
13
|
+
/** A unique error code for the particular error subclass. */
|
|
14
|
+
static get code(): string;
|
|
15
|
+
/** A unique error code for the particular error subclass. */
|
|
16
|
+
code: string;
|
|
17
|
+
constructor(message?: string);
|
|
18
|
+
}
|
|
19
|
+
export declare class JWTClaimValidationFailed extends JOSEError {
|
|
20
|
+
static get code(): 'ERR_JWT_CLAIM_VALIDATION_FAILED';
|
|
21
|
+
code: string;
|
|
22
|
+
/** The Claim for which the validation failed. */
|
|
23
|
+
claim: string;
|
|
24
|
+
/** Reason code for the validation failure. */
|
|
25
|
+
reason: string;
|
|
26
|
+
constructor(message: string, claim?: string, reason?: string);
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* An error subclass thrown when a JWT is expired.
|
|
30
|
+
*
|
|
31
|
+
* @example Checking thrown error is this one using a stable error code
|
|
32
|
+
*
|
|
33
|
+
* ```js
|
|
34
|
+
* if (err.code === 'ERR_JWT_EXPIRED') {
|
|
35
|
+
* // ...
|
|
36
|
+
* }
|
|
37
|
+
* ```
|
|
38
|
+
*
|
|
39
|
+
* @example Checking thrown error is this one using `instanceof`
|
|
40
|
+
*
|
|
41
|
+
* ```js
|
|
42
|
+
* if (err instanceof errors.JWTExpired) {
|
|
43
|
+
* // ...
|
|
44
|
+
* }
|
|
45
|
+
* ```
|
|
46
|
+
*/
|
|
47
|
+
export declare class JWTExpired extends JOSEError implements JWTClaimValidationFailed {
|
|
48
|
+
static get code(): 'ERR_JWT_EXPIRED';
|
|
49
|
+
code: string;
|
|
50
|
+
/** The Claim for which the validation failed. */
|
|
51
|
+
claim: string;
|
|
52
|
+
/** Reason code for the validation failure. */
|
|
53
|
+
reason: string;
|
|
54
|
+
constructor(message: string, claim?: string, reason?: string);
|
|
55
|
+
}
|
|
56
|
+
/**
|
|
57
|
+
* An error subclass thrown when a JOSE Algorithm is not allowed per developer preference.
|
|
58
|
+
*
|
|
59
|
+
* @example Checking thrown error is this one using a stable error code
|
|
60
|
+
*
|
|
61
|
+
* ```js
|
|
62
|
+
* if (err.code === 'ERR_JOSE_ALG_NOT_ALLOWED') {
|
|
63
|
+
* // ...
|
|
64
|
+
* }
|
|
65
|
+
* ```
|
|
66
|
+
*
|
|
67
|
+
* @example Checking thrown error is this one using `instanceof`
|
|
68
|
+
*
|
|
69
|
+
* ```js
|
|
70
|
+
* if (err instanceof errors.JOSEAlgNotAllowed) {
|
|
71
|
+
* // ...
|
|
72
|
+
* }
|
|
73
|
+
* ```
|
|
74
|
+
*/
|
|
75
|
+
export declare class JOSEAlgNotAllowed extends JOSEError {
|
|
76
|
+
static get code(): 'ERR_JOSE_ALG_NOT_ALLOWED';
|
|
77
|
+
code: string;
|
|
78
|
+
}
|
|
79
|
+
/**
|
|
80
|
+
* An error subclass thrown when a particular feature or algorithm is not supported by this
|
|
81
|
+
* implementation or JOSE in general.
|
|
82
|
+
*
|
|
83
|
+
* @example Checking thrown error is this one using a stable error code
|
|
84
|
+
*
|
|
85
|
+
* ```js
|
|
86
|
+
* if (err.code === 'ERR_JOSE_NOT_SUPPORTED') {
|
|
87
|
+
* // ...
|
|
88
|
+
* }
|
|
89
|
+
* ```
|
|
90
|
+
*
|
|
91
|
+
* @example Checking thrown error is this one using `instanceof`
|
|
92
|
+
*
|
|
93
|
+
* ```js
|
|
94
|
+
* if (err instanceof errors.JOSENotSupported) {
|
|
95
|
+
* // ...
|
|
96
|
+
* }
|
|
97
|
+
* ```
|
|
98
|
+
*/
|
|
99
|
+
export declare class JOSENotSupported extends JOSEError {
|
|
100
|
+
static get code(): 'ERR_JOSE_NOT_SUPPORTED';
|
|
101
|
+
code: string;
|
|
102
|
+
}
|
|
103
|
+
/**
|
|
104
|
+
* An error subclass thrown when a JWT is invalid.
|
|
105
|
+
*
|
|
106
|
+
* @example Checking thrown error is this one using a stable error code
|
|
107
|
+
*
|
|
108
|
+
* ```js
|
|
109
|
+
* if (err.code === 'ERR_JWT_INVALID') {
|
|
110
|
+
* // ...
|
|
111
|
+
* }
|
|
112
|
+
* ```
|
|
113
|
+
*
|
|
114
|
+
* @example Checking thrown error is this one using `instanceof`
|
|
115
|
+
*
|
|
116
|
+
* ```js
|
|
117
|
+
* if (err instanceof errors.JWTInvalid) {
|
|
118
|
+
* // ...
|
|
119
|
+
* }
|
|
120
|
+
* ```
|
|
121
|
+
*/
|
|
122
|
+
export declare class JWTInvalid extends JOSEError {
|
|
123
|
+
static get code(): 'ERR_JWT_INVALID';
|
|
124
|
+
code: string;
|
|
125
|
+
}
|
|
126
|
+
/**
|
|
127
|
+
* An error subclass thrown when a JWT signature (JWS) is invalid.
|
|
128
|
+
*/
|
|
129
|
+
export declare class JWSInvalid extends JOSEError {
|
|
130
|
+
static get code(): 'ERR_JWS_INVALID';
|
|
131
|
+
code: string;
|
|
132
|
+
}
|
|
133
|
+
/**
|
|
134
|
+
* An error subclass thrown when JWS signature verification fails.
|
|
135
|
+
*
|
|
136
|
+
* @example Checking thrown error is this one using a stable error code
|
|
137
|
+
*
|
|
138
|
+
* ```js
|
|
139
|
+
* if (err.code === 'ERR_JWS_SIGNATURE_VERIFICATION_FAILED') {
|
|
140
|
+
* // ...
|
|
141
|
+
* }
|
|
142
|
+
* ```
|
|
143
|
+
*
|
|
144
|
+
* @example Checking thrown error is this one using `instanceof`
|
|
145
|
+
*
|
|
146
|
+
* ```js
|
|
147
|
+
* if (err instanceof errors.JWSSignatureVerificationFailed) {
|
|
148
|
+
* // ...
|
|
149
|
+
* }
|
|
150
|
+
* ```
|
|
151
|
+
*/
|
|
152
|
+
export declare class JWSSignatureVerificationFailed extends JOSEError {
|
|
153
|
+
static get code(): 'ERR_JWS_SIGNATURE_VERIFICATION_FAILED';
|
|
154
|
+
code: string;
|
|
155
|
+
message: string;
|
|
156
|
+
}
|
|
157
|
+
//# sourceMappingURL=errors.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"err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;;GAEG;AACH,qBAAa,UAAW,SAAQ,SAAS;IACvC,MAAM,KAAK,IAAI,IAAI,iBAAiB,CAEnC;IACD,IAAI,SAAqB;CAC1B;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,qBAAa,8BAA+B,SAAQ,SAAS;IAC3D,MAAM,KAAK,IAAI,IAAI,uCAAuC,CAEzD;IAED,IAAI,SAA2C;IAE/C,OAAO,SAAmC;CAC3C"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"is_object.d.ts","sourceRoot":"","sources":["../../../src/utils/is_object.ts"],"names":[],"mappings":"AAIA,MAAM,CAAC,OAAO,UAAU,QAAQ,CAAC,CAAC,GAAG,MAAM,EAAE,KAAK,EAAE,OAAO,GAAG,KAAK,IAAI,CAAC,CAevE"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"proxy.d.ts","sourceRoot":"","sources":["../../../src/utils/proxy.ts"],"names":[],"mappings":"AAEA,eAAO,MAAM,gBAAgB,KAYxB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"secs.d.ts","sourceRoot":"","sources":["../../../src/utils/secs.ts"],"names":[],"mappings":"8BAcqB,MAAM,KAAG,MAAM;AAApC,wBAyCE;AAEF,eAAO,MAAM,KAAK,SAAU,IAAI,WAAsC,CAAC"}
|