openid-client 4.7.3 → 4.9.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/README.md CHANGED
@@ -42,12 +42,13 @@ openid-client.
42
42
  - Client Authentication
43
43
  - tls_client_auth
44
44
  - self_signed_tls_client_auth
45
+ - [RFC9101 - OAuth 2.0 JWT-Secured Authorization Request (JAR)][feature-jar]
46
+ - [RFC9126 - OAuth 2.0 Pushed Authorization Requests (PAR)][feature-par]
45
47
  - [OpenID Connect Session Management 1.0 - draft 28][feature-rp-logout]
46
48
  - RP-Initiated Logout
47
49
  - [Financial-grade API - Part 2: Read and Write API Security Profile (FAPI) - ID2][feature-fapi]
48
50
  - [JWT Secured Authorization Response Mode for OAuth 2.0 (JARM) - ID1][feature-jarm]
49
- - [OAuth 2.0 Demonstration of Proof-of-Possession at the Application Layer (DPoP) - draft 01][feature-dpop]
50
- - [OAuth 2.0 Pushed Authorization Requests (PAR) - draft 06][feature-par]
51
+ - [OAuth 2.0 Demonstration of Proof-of-Possession at the Application Layer (DPoP) - draft 03][feature-dpop]
51
52
 
52
53
  Updates to draft specifications (DPoP, JARM, and FAPI) are released as MINOR library versions,
53
54
  if you utilize these specification implementations consider using the tilde `~` operator in your
@@ -296,8 +297,9 @@ See [Customizing (docs)](https://github.com/panva/node-openid-client/blob/master
296
297
  [feature-rp-logout]: https://openid.net/specs/openid-connect-session-1_0.html#RPLogout
297
298
  [feature-jarm]: https://openid.net/specs/openid-financial-api-jarm-ID1.html
298
299
  [feature-fapi]: https://openid.net/specs/openid-financial-api-part-2-ID2.html
299
- [feature-dpop]: https://tools.ietf.org/html/draft-ietf-oauth-dpop-01
300
- [feature-par]: https://tools.ietf.org/html/draft-ietf-oauth-par-06
300
+ [feature-dpop]: https://tools.ietf.org/html/draft-ietf-oauth-dpop-03
301
+ [feature-par]: https://www.rfc-editor.org/rfc/rfc9126.html
302
+ [feature-jar]: https://www.rfc-editor.org/rfc/rfc9101.html
301
303
  [openid-certified-link]: https://openid.net/certification/
302
304
  [passport-url]: http://passportjs.org
303
305
  [npm-url]: https://www.npmjs.com/package/openid-client
package/lib/client.js CHANGED
@@ -1013,8 +1013,9 @@ module.exports = (issuer, aadIssValidation = false) => class Client extends Base
1013
1013
  method,
1014
1014
  headers,
1015
1015
  body,
1016
- tokenType = accessToken instanceof TokenSet ? accessToken.token_type : 'Bearer',
1017
1016
  DPoP,
1017
+ // eslint-disable-next-line no-nested-ternary
1018
+ tokenType = DPoP ? 'DPoP' : accessToken instanceof TokenSet ? accessToken.token_type : 'Bearer',
1018
1019
  } = {},
1019
1020
  ) {
1020
1021
  if (accessToken instanceof TokenSet) {
@@ -1039,7 +1040,7 @@ module.exports = (issuer, aadIssValidation = false) => class Client extends Base
1039
1040
  responseType: 'buffer',
1040
1041
  method,
1041
1042
  url: resourceUrl,
1042
- }, { mTLS, DPoP });
1043
+ }, { accessToken, mTLS, DPoP });
1043
1044
  }
1044
1045
 
1045
1046
  /**
@@ -1550,6 +1551,57 @@ module.exports = (issuer, aadIssValidation = false) => class Client extends Base
1550
1551
  });
1551
1552
  }
1552
1553
 
1554
+ /**
1555
+ * @name pushedAuthorizationRequest
1556
+ * @api public
1557
+ */
1558
+ async pushedAuthorizationRequest(params = {}, { clientAssertionPayload } = {}) {
1559
+ assertIssuerConfiguration(this.issuer, 'pushed_authorization_request_endpoint');
1560
+
1561
+ const body = {
1562
+ ...('request' in params ? params : authorizationParams.call(this, params)),
1563
+ client_id: this.client_id,
1564
+ };
1565
+
1566
+ const response = await authenticatedPost.call(
1567
+ this,
1568
+ 'pushed_authorization_request',
1569
+ {
1570
+ responseType: 'json',
1571
+ form: body,
1572
+ },
1573
+ { clientAssertionPayload, endpointAuthMethod: 'token' },
1574
+ );
1575
+ const responseBody = processResponse(response, { statusCode: 201 });
1576
+
1577
+ if (!('expires_in' in responseBody)) {
1578
+ throw new RPError({
1579
+ message: 'expected expires_in in Pushed Authorization Successful Response',
1580
+ response,
1581
+ });
1582
+ }
1583
+ if (typeof responseBody.expires_in !== 'number') {
1584
+ throw new RPError({
1585
+ message: 'invalid expires_in value in Pushed Authorization Successful Response',
1586
+ response,
1587
+ });
1588
+ }
1589
+ if (!('request_uri' in responseBody)) {
1590
+ throw new RPError({
1591
+ message: 'expected request_uri in Pushed Authorization Successful Response',
1592
+ response,
1593
+ });
1594
+ }
1595
+ if (typeof responseBody.request_uri !== 'string') {
1596
+ throw new RPError({
1597
+ message: 'invalid request_uri value in Pushed Authorization Successful Response',
1598
+ response,
1599
+ });
1600
+ }
1601
+
1602
+ return responseBody;
1603
+ }
1604
+
1553
1605
  /**
1554
1606
  * @name issuer
1555
1607
  * @api public
@@ -1608,7 +1660,7 @@ Object.defineProperty(BaseClient.prototype, 'validateJARM', {
1608
1660
  * @name dpopProof
1609
1661
  * @api private
1610
1662
  */
1611
- function dpopProof(payload, jwk) {
1663
+ function dpopProof(payload, jwk, accessToken) {
1612
1664
  if (!isPlainObject(payload)) {
1613
1665
  throw new TypeError('payload must be a plain object');
1614
1666
  }
@@ -1632,9 +1684,15 @@ function dpopProof(payload, jwk) {
1632
1684
  [alg] = key.algorithms('sign');
1633
1685
  }
1634
1686
 
1687
+ let ath;
1688
+ if (accessToken) {
1689
+ ath = base64url.encode(crypto.createHash('sha256').update(accessToken).digest());
1690
+ }
1691
+
1635
1692
  return jose.JWS.sign({
1636
1693
  iat: now(),
1637
1694
  jti: random(),
1695
+ ath,
1638
1696
  ...payload,
1639
1697
  }, jwk, {
1640
1698
  alg,
@@ -1648,7 +1706,7 @@ Object.defineProperty(BaseClient.prototype, 'dpopProof', {
1648
1706
  configurable: true,
1649
1707
  value(...args) {
1650
1708
  process.emitWarning(
1651
- 'The DPoP APIs implements an IETF draft. Breaking draft implementations are included as minor versions of the openid-client library, therefore, the ~ semver operator should be used and close attention be payed to library changelog as well as the drafts themselves.',
1709
+ 'The DPoP APIs implements an IETF draft (https://www.ietf.org/archive/id/draft-ietf-oauth-dpop-03.html). Breaking draft implementations are included as minor versions of the openid-client library, therefore, the ~ semver operator should be used and close attention be payed to library changelog as well as the drafts themselves.',
1652
1710
  'DraftWarning',
1653
1711
  );
1654
1712
  Object.defineProperty(BaseClient.prototype, 'dpopProof', {
@@ -1660,72 +1718,4 @@ Object.defineProperty(BaseClient.prototype, 'dpopProof', {
1660
1718
  },
1661
1719
  });
1662
1720
 
1663
- /**
1664
- * @name pushedAuthorizationRequest
1665
- * @api public
1666
- */
1667
- async function pushedAuthorizationRequest(params = {}, { clientAssertionPayload } = {}) {
1668
- assertIssuerConfiguration(this.issuer, 'pushed_authorization_request_endpoint');
1669
-
1670
- const body = {
1671
- ...('request' in params ? params : authorizationParams.call(this, params)),
1672
- client_id: this.client_id,
1673
- };
1674
-
1675
- const response = await authenticatedPost.call(
1676
- this,
1677
- 'pushed_authorization_request',
1678
- {
1679
- responseType: 'json',
1680
- form: body,
1681
- },
1682
- { clientAssertionPayload, endpointAuthMethod: 'token' },
1683
- );
1684
- const responseBody = processResponse(response, { statusCode: 201 });
1685
-
1686
- if (!('expires_in' in responseBody)) {
1687
- throw new RPError({
1688
- message: 'expected expires_in in Pushed Authorization Successful Response',
1689
- response,
1690
- });
1691
- }
1692
- if (typeof responseBody.expires_in !== 'number') {
1693
- throw new RPError({
1694
- message: 'invalid expires_in value in Pushed Authorization Successful Response',
1695
- response,
1696
- });
1697
- }
1698
- if (!('request_uri' in responseBody)) {
1699
- throw new RPError({
1700
- message: 'expected request_uri in Pushed Authorization Successful Response',
1701
- response,
1702
- });
1703
- }
1704
- if (typeof responseBody.request_uri !== 'string') {
1705
- throw new RPError({
1706
- message: 'invalid request_uri value in Pushed Authorization Successful Response',
1707
- response,
1708
- });
1709
- }
1710
-
1711
- return responseBody;
1712
- }
1713
-
1714
- Object.defineProperty(BaseClient.prototype, 'pushedAuthorizationRequest', {
1715
- enumerable: true,
1716
- configurable: true,
1717
- value(...args) {
1718
- process.emitWarning(
1719
- 'The Pushed Authorization Requests APIs implements an IETF draft. Breaking draft implementations are included as minor versions of the openid-client library, therefore, the ~ semver operator should be used and close attention be payed to library changelog as well as the drafts themselves.',
1720
- 'DraftWarning',
1721
- );
1722
- Object.defineProperty(BaseClient.prototype, 'pushedAuthorizationRequest', {
1723
- enumerable: true,
1724
- configurable: true,
1725
- value: pushedAuthorizationRequest,
1726
- });
1727
- return this.pushedAuthorizationRequest(...args);
1728
- },
1729
- });
1730
-
1731
1721
  module.exports.BaseClient = BaseClient;
@@ -22,7 +22,7 @@ setDefaults({
22
22
  throwHttpErrors: false,
23
23
  });
24
24
 
25
- module.exports = async function request(options, { mTLS = false, DPoP } = {}) {
25
+ module.exports = async function request(options, { accessToken, mTLS = false, DPoP } = {}) {
26
26
  const { url } = options;
27
27
  isAbsoluteUrl(url);
28
28
  const optsFn = this[HTTP_OPTIONS];
@@ -33,7 +33,7 @@ module.exports = async function request(options, { mTLS = false, DPoP } = {}) {
33
33
  opts.headers.DPoP = this.dpopProof({
34
34
  htu: url,
35
35
  htm: options.method,
36
- }, DPoP);
36
+ }, DPoP, accessToken);
37
37
  }
38
38
 
39
39
  if (optsFn) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "openid-client",
3
- "version": "4.7.3",
3
+ "version": "4.9.0",
4
4
  "description": "OpenID Connect Relying Party (RP, Client) implementation for Node.js runtime, supports passportjs",
5
5
  "keywords": [
6
6
  "auth",
@@ -43,7 +43,6 @@
43
43
  "coverage": "nyc mocha test/**/*.test.js",
44
44
  "lint": "eslint lib test",
45
45
  "lint-fix": "eslint lib test --fix",
46
- "lint-ts": "npx typescript@~3.6.0 --build types",
47
46
  "test": "mocha test/**/*.test.js"
48
47
  },
49
48
  "nyc": {
package/types/index.d.ts CHANGED
@@ -380,6 +380,8 @@ export interface IntrospectionResponse {
380
380
  username?: string;
381
381
  aud?: string | string[];
382
382
  scope: string;
383
+ sub?: string;
384
+ nbf?: number;
383
385
  token_type?: string;
384
386
  cnf?: {
385
387
  "x5t#S256"?: string;
@@ -513,7 +515,7 @@ export class Client {
513
515
  options?: {
514
516
  headers?: object;
515
517
  body?: string | Buffer;
516
- method?: "GET" | "POST" | "PUT" | "HEAD" | "DELETE" | "OPTIONS" | "TRACE";
518
+ method?: "GET" | "POST" | "PUT" | "HEAD" | "DELETE" | "OPTIONS" | "TRACE" | "PATCH";
517
519
  tokenType?: string;
518
520
  DPoP?: DPoPInput;
519
521
  }
package/CHANGELOG.md DELETED
@@ -1,1101 +0,0 @@
1
- # Changelog
2
-
3
- All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
-
5
- ## [4.7.3](https://github.com/panva/node-openid-client/compare/v4.7.2...v4.7.3) (2021-04-30)
6
-
7
-
8
- ### Bug Fixes
9
-
10
- * **fapi:** validate ID Token's iat regardless of which channel it came from ([b68b9ab](https://github.com/panva/node-openid-client/commit/b68b9ab5af6a85a2f42adf6b782cef7e08378658))
11
-
12
- ## [4.7.2](https://github.com/panva/node-openid-client/compare/v4.7.1...v4.7.2) (2021-04-23)
13
-
14
-
15
- ### Bug Fixes
16
-
17
- * **typescript:** add types for 4.6.0 additions ([9064136](https://github.com/panva/node-openid-client/commit/9064136d959b5825f69b32344bbe165f12a10949))
18
-
19
- ## [4.7.1](https://github.com/panva/node-openid-client/compare/v4.7.0...v4.7.1) (2021-04-22)
20
-
21
-
22
- ### Bug Fixes
23
-
24
- * **typescript:** add types for 4.7.0 additions ([2c1d2ab](https://github.com/panva/node-openid-client/commit/2c1d2ab71fe2daba2dad23af1f92f66c92305df5))
25
-
26
- ## [4.7.0](https://github.com/panva/node-openid-client/compare/v4.6.0...v4.7.0) (2021-04-22)
27
-
28
-
29
- ### Features
30
-
31
- * add abort control over Device Flow Handle polling ([#357](https://github.com/panva/node-openid-client/issues/357)) ([f6faa68](https://github.com/panva/node-openid-client/commit/f6faa68850e2582c92e69fa420b8d5c58bfc951c)), closes [#355](https://github.com/panva/node-openid-client/issues/355) [#356](https://github.com/panva/node-openid-client/issues/356)
32
-
33
- ## [4.6.0](https://github.com/panva/node-openid-client/compare/v4.5.2...v4.6.0) (2021-03-25)
34
-
35
-
36
- ### Features
37
-
38
- * added OAuth 2.0 Pushed Authorization Requests client API ([e7af9f5](https://github.com/panva/node-openid-client/commit/e7af9f5125c9c1a8877482b8fda44954e60707a1)), closes [#259](https://github.com/panva/node-openid-client/issues/259)
39
-
40
- ## [4.5.2](https://github.com/panva/node-openid-client/compare/v4.5.1...v4.5.2) (2021-03-24)
41
-
42
-
43
- ### Bug Fixes
44
-
45
- * interoperable audience array value for JWT Client auth assertions ([da7d2f0](https://github.com/panva/node-openid-client/commit/da7d2f0090cd0323a14702bcca77536eb4e2b49d))
46
-
47
- ## [4.5.1](https://github.com/panva/node-openid-client/compare/v4.5.0...v4.5.1) (2021-03-15)
48
-
49
-
50
- ### Bug Fixes
51
-
52
- * use mtls token endpoint alias as audience when using jwt auth with mtls constrained tokens ([c463359](https://github.com/panva/node-openid-client/commit/c4633591ed7ebdf973b0240959078a8217beccbb))
53
-
54
- ## [4.5.0](https://github.com/panva/node-openid-client/compare/v4.4.2...v4.5.0) (2021-03-10)
55
-
56
-
57
- ### Features
58
-
59
- * include `nbf` in FAPIClient Request Objects ([0be56ba](https://github.com/panva/node-openid-client/commit/0be56ba5622e0062495965f55285438542da614e))
60
-
61
- ## [4.4.2](https://github.com/panva/node-openid-client/compare/v4.4.1...v4.4.2) (2021-03-07)
62
-
63
-
64
- ### Bug Fixes
65
-
66
- * resolve discovery URIs one by one to yield consistent results ([6b18218](https://github.com/panva/node-openid-client/commit/6b18218cfa098195ec8442086221a88fa6aef654)), closes [#260](https://github.com/panva/node-openid-client/issues/260) [#267](https://github.com/panva/node-openid-client/issues/267)
67
-
68
- ## [4.4.1](https://github.com/panva/node-openid-client/compare/v4.4.0...v4.4.1) (2021-02-26)
69
-
70
-
71
- ### Bug Fixes
72
-
73
- * hide AggregateError message stack ([3011cca](https://github.com/panva/node-openid-client/commit/3011ccabc63e670adcee432b6565d10b55554865)), closes [#336](https://github.com/panva/node-openid-client/issues/336)
74
-
75
- ## [4.4.0](https://github.com/panva/node-openid-client/compare/v4.3.0...v4.4.0) (2021-01-29)
76
-
77
-
78
- ### Features
79
-
80
- * allow options.https.pfx for mTSL ([075cad7](https://github.com/panva/node-openid-client/commit/075cad73a28d825128e6c92d44e7dba556b6a6f4)), closes [#326](https://github.com/panva/node-openid-client/issues/326)
81
-
82
- ## [4.3.0](https://github.com/panva/node-openid-client/compare/v4.2.3...v4.3.0) (2021-01-22)
83
-
84
-
85
- ### Features
86
-
87
- * **typescript:** add userinfo response generics ([b176b2f](https://github.com/panva/node-openid-client/commit/b176b2f9161be77082c520ab532c237380abda22))
88
-
89
- ## [4.2.3](https://github.com/panva/node-openid-client/compare/v4.2.2...v4.2.3) (2021-01-18)
90
-
91
-
92
- ### Performance
93
-
94
- * use base64url encoding in node when available ([24ab5b4](https://github.com/panva/node-openid-client/commit/24ab5b46c688cd1dd3679fe61a9de668c87e656b))
95
-
96
- ## [4.2.2](https://github.com/panva/node-openid-client/compare/v4.2.1...v4.2.2) (2020-11-30)
97
-
98
-
99
- ### Bug Fixes
100
-
101
- * push pkce <> response type resolution to the authenticate function ([1970af4](https://github.com/panva/node-openid-client/commit/1970af41dc0cd62d44efb1f0a48bdc2a70bcd608)), closes [#312](https://github.com/panva/node-openid-client/issues/312)
102
-
103
- ## [4.2.1](https://github.com/panva/node-openid-client/compare/v4.2.0...v4.2.1) (2020-10-27)
104
-
105
-
106
- ### Bug Fixes
107
-
108
- * **typescript:** add state property to AuthorizationParameters ([#305](https://github.com/panva/node-openid-client/issues/305)) ([b9dfa60](https://github.com/panva/node-openid-client/commit/b9dfa6064d7823ab0bb3eed486a3a5c7ad452982)), closes [#304](https://github.com/panva/node-openid-client/issues/304)
109
-
110
- ## [4.2.0](https://github.com/panva/node-openid-client/compare/v4.1.1...v4.2.0) (2020-10-03)
111
-
112
-
113
- ### Features
114
-
115
- * add callback extras to strategy options ([#295](https://github.com/panva/node-openid-client/issues/295)) ([b77466d](https://github.com/panva/node-openid-client/commit/b77466ddb597accdb783bad07566f28db0d2c827))
116
-
117
- ## [4.1.1](https://github.com/panva/node-openid-client/compare/v4.1.0...v4.1.1) (2020-09-14)
118
-
119
-
120
- ### Bug Fixes
121
-
122
- * **typescript:** ts module interop issues with default export ([6ca57d0](https://github.com/panva/node-openid-client/commit/6ca57d0ef08c188c1da7f3c980b74ba3abf33966)), closes [#291](https://github.com/panva/node-openid-client/issues/291)
123
-
124
- ## [4.1.0](https://github.com/panva/node-openid-client/compare/v4.0.2...v4.1.0) (2020-09-11)
125
-
126
-
127
- ### Features
128
-
129
- * OAuth 2.0 DPoP in various relevant API interfaces ([44a0de7](https://github.com/panva/node-openid-client/commit/44a0de7ceb62cabacd62798ac136f1c394907028))
130
-
131
- ## [4.0.2](https://github.com/panva/node-openid-client/compare/v4.0.1...v4.0.2) (2020-09-11)
132
-
133
-
134
- ### Bug Fixes
135
-
136
- * updated request object mime-type as per draft-ietf-oauth-jwsreq-30 ([d5cc619](https://github.com/panva/node-openid-client/commit/d5cc619cbf137c42898229546e44b8f065af6e3f))
137
-
138
- ## [4.0.1](https://github.com/panva/node-openid-client/compare/v4.0.0...v4.0.1) (2020-09-10)
139
-
140
-
141
- ### Bug Fixes
142
-
143
- * ensure minimal got version handles upcoming node version changes ([fd737a3](https://github.com/panva/node-openid-client/commit/fd737a3598c29d7069328156e06b23d08c1f50c6))
144
-
145
- ## [4.0.0](https://github.com/panva/node-openid-client/compare/v3.15.10...v4.0.0) (2020-09-09)
146
-
147
-
148
- ### ⚠ BREAKING CHANGES
149
-
150
- * the deprecated `issuer.key()` method was removed
151
- * due to added ESM module support Node.js version with
152
- ESM implementation bugs are no longer supported, this only affects early
153
- v13.x versions. The resulting Node.js semver range is
154
- `^10.19.0 || >=12.0.0 < 13 || >=13.7.0` (also taking into account the
155
- `got` dependency update)
156
- * upgraded got http request library dependency from
157
- `v9.x` to `v11.x`. If you override some of the http request options
158
- you will most certainly have to accomodate them.
159
- * Signed Request Object "typ" changed from `JWT` to
160
- `oauth.authz.req+jwt`
161
- * Encrypted Request Object "cty" changed from `JWT` to
162
- `oauth.authz.req+jwt`
163
- * PKCE is now used by default in the passport strategy
164
- * `client.userinfo()` `verb` parameter was renamed to
165
- `method`
166
- * the deprecated `client.resource()` method was removed
167
-
168
- ### Features
169
-
170
- * added support for ESM (ECMAScript modules) ([3ac37e8](https://github.com/panva/node-openid-client/commit/3ac37e80d66d47e9814972ed86d1323b9ee96b79))
171
- * passport strategy will now use PKCE by default where applicable ([56f9fe7](https://github.com/panva/node-openid-client/commit/56f9fe7171ccc1bec6427d4f9bc45e419150ab4d))
172
-
173
-
174
- ### Bug Fixes
175
-
176
- * request object type changed from 'JWT' to 'oauth.authz.req+jwt' ([641a42f](https://github.com/panva/node-openid-client/commit/641a42fdd3097289085340afab652e4b8b9f571c))
177
-
178
-
179
- ### Refactor
180
-
181
- * remove deprecated `client.resource()` ([c0ec865](https://github.com/panva/node-openid-client/commit/c0ec8652673c7b276a7c71eb2d730eb3feb22eeb))
182
- * remove deprecated `issuer.key()` ([5cd1ecf](https://github.com/panva/node-openid-client/commit/5cd1ecfced358c7a685d9dc29aa451a9ef13b770))
183
- * rename `client.userinfo()` `verb` parameter to `method` ([4cb21a4](https://github.com/panva/node-openid-client/commit/4cb21a4c2aef6421fe7a0f67d45baf209989cdd4))
184
- * upgrade got from v9.x to v11.x ([c72b5e8](https://github.com/panva/node-openid-client/commit/c72b5e812f6a94a92e008facefa72c366728d4a5))
185
-
186
- ## [3.15.10](https://github.com/panva/node-openid-client/compare/v3.15.9...v3.15.10) (2020-09-02)
187
-
188
-
189
- ### Bug Fixes
190
-
191
- * **typescript:** add missing types ([#284](https://github.com/panva/node-openid-client/issues/284)) ([49e0ff0](https://github.com/panva/node-openid-client/commit/49e0ff0c695cabd54148bc8a83611dd4ef6ed47c))
192
-
193
- ## [3.15.9](https://github.com/panva/node-openid-client/compare/v3.15.8...v3.15.9) (2020-07-26)
194
-
195
-
196
- ### Bug Fixes
197
-
198
- * **typescript:** max_age in AuthorizationParameters is a number ([5ce2a73](https://github.com/panva/node-openid-client/commit/5ce2a733890dba6ba2bc2f8f296a4235c0c5cdd6)), closes [#279](https://github.com/panva/node-openid-client/issues/279)
199
-
200
-
201
-
202
- ## [3.15.8](https://github.com/panva/node-openid-client/compare/v3.15.7...v3.15.8) (2020-07-17)
203
-
204
-
205
- ### Bug Fixes
206
-
207
- * allow AAD appid including discovery URLs to be multi-tenant ([c27caab](https://github.com/panva/node-openid-client/commit/c27caab9b9df92b591c4f0491fd2ec346ff48988))
208
-
209
-
210
-
211
- ## [3.15.7](https://github.com/panva/node-openid-client/compare/v3.15.6...v3.15.7) (2020-07-16)
212
-
213
-
214
-
215
- ## [3.15.6](https://github.com/panva/node-openid-client/compare/v3.15.5...v3.15.6) (2020-07-06)
216
-
217
-
218
- ### Bug Fixes
219
-
220
- * merge helper returns modified object, leftovers removed ([2e3339b](https://github.com/panva/node-openid-client/commit/2e3339bd82297d6e37574e007b8a443087f3291e))
221
-
222
-
223
-
224
- ## [3.15.5](https://github.com/panva/node-openid-client/compare/v3.15.4...v3.15.5) (2020-06-26)
225
-
226
-
227
- ### Bug Fixes
228
-
229
- * regression from [#272](https://github.com/panva/node-openid-client/issues/272) ([9bff960](https://github.com/panva/node-openid-client/commit/9bff960bda42fd8af7b8569f121ca35c7f4cfae4))
230
-
231
-
232
-
233
- ## [3.15.4](https://github.com/panva/node-openid-client/compare/v3.15.3...v3.15.4) (2020-06-26)
234
-
235
-
236
-
237
- ## [3.15.3](https://github.com/panva/node-openid-client/compare/v3.15.2...v3.15.3) (2020-06-15)
238
-
239
-
240
- ### Bug Fixes
241
-
242
- * give AAD v1 common same treatment as v2 common ([2344e00](https://github.com/panva/node-openid-client/commit/2344e006fd4086d0df8391f9ef95cce25299e45f)), closes [#269](https://github.com/panva/node-openid-client/issues/269)
243
-
244
-
245
-
246
- ## [3.15.2](https://github.com/panva/node-openid-client/compare/v3.15.1...v3.15.2) (2020-06-01)
247
-
248
-
249
- ### Bug Fixes
250
-
251
- * allow any JSON numeric value for timestamp values ([a24a759](https://github.com/panva/node-openid-client/commit/a24a7596c038bacd5bdbfc5b8678a96e62b86fd2)), closes [#263](https://github.com/panva/node-openid-client/issues/263)
252
-
253
-
254
-
255
- ## [3.15.1](https://github.com/panva/node-openid-client/compare/v3.15.0...v3.15.1) (2020-05-12)
256
-
257
-
258
- ### Bug Fixes
259
-
260
- * A192CBC-HS384 and A256CBC-HS512 direct encryption key derivation ([c356bbe](https://github.com/panva/node-openid-client/commit/c356bbeaba1e28b6a56534b9ba503cb536c14d57))
261
-
262
-
263
-
264
- ## [3.15.0](https://github.com/panva/node-openid-client/compare/v3.14.2...v3.15.0) (2020-04-28)
265
-
266
-
267
- ### Features
268
-
269
- * add RPError indicators for unix timestamp comparison failures ([fe3db5c](https://github.com/panva/node-openid-client/commit/fe3db5c46a04cab024901782f202d08234b4cd96)), closes [#250](https://github.com/panva/node-openid-client/issues/250)
270
-
271
-
272
-
273
- ## [3.14.2](https://github.com/panva/node-openid-client/compare/v3.14.1...v3.14.2) (2020-04-07)
274
-
275
-
276
- ### Bug Fixes
277
-
278
- * **typescript:** add options arg to TypeOfGenericClient ([b97b028](https://github.com/panva/node-openid-client/commit/b97b0288d5d79f25cad3d0009212878c5d42a2e0))
279
-
280
-
281
-
282
- ## [3.14.1](https://github.com/panva/node-openid-client/compare/v3.14.0...v3.14.1) (2020-03-21)
283
-
284
-
285
- ### Bug Fixes
286
-
287
- * assert refresh_token grant ID Token sub to equal previous ([23f3f9f](https://github.com/panva/node-openid-client/commit/23f3f9fcb88c157cf9bbfa7cc2444e07f0cedc18))
288
-
289
-
290
-
291
- ## [3.14.0](https://github.com/panva/node-openid-client/compare/v3.13.0...v3.14.0) (2020-02-28)
292
-
293
-
294
- ### Features
295
-
296
- * support additional authorized parties ([c9268ce](https://github.com/panva/node-openid-client/commit/c9268ce24c0080729652d7ba67a7f313227dc815)), closes [#231](https://github.com/panva/node-openid-client/issues/231)
297
-
298
-
299
-
300
- ## [3.13.0](https://github.com/panva/node-openid-client/compare/v3.12.2...v3.13.0) (2020-02-18)
301
-
302
-
303
- ### Features
304
-
305
- * add support for RSA-OAEP-384 and RSA-OAEP-512 JWE algorithms ([6c696e9](https://github.com/panva/node-openid-client/commit/6c696e98202af2a358fde72bd0718c7dff7f3a96))
306
-
307
-
308
-
309
- ## [3.12.2](https://github.com/panva/node-openid-client/compare/v3.12.1...v3.12.2) (2020-01-30)
310
-
311
-
312
- ### Bug Fixes
313
-
314
- * ensure jose version that handles ECDH-ES for larger key sizes right ([e91001a](https://github.com/panva/node-openid-client/commit/e91001a30e0c429ef5bb49e0fda58a54f765c346))
315
-
316
-
317
-
318
- ## [3.12.1](https://github.com/panva/node-openid-client/compare/v3.12.0...v3.12.1) (2020-01-25)
319
-
320
-
321
- ### Bug Fixes
322
-
323
- * allow multiple keys to match when selecting encryption key for request object ([fa3fa67](https://github.com/panva/node-openid-client/commit/fa3fa677709f4e229c6356896731416feff71509))
324
-
325
-
326
-
327
- ## [3.12.0](https://github.com/panva/node-openid-client/compare/v3.11.0...v3.12.0) (2020-01-23)
328
-
329
-
330
- ### Bug Fixes
331
-
332
- * allow omitting the `*_enc` attributes (default 'A128CBC-HS256') ([6567c73](https://github.com/panva/node-openid-client/commit/6567c73996ba247d1bd46796d37a32ffa93d74a5))
333
-
334
-
335
- ### Features
336
-
337
- * new API for fetching arbitrary resources with the access token ([c981ed6](https://github.com/panva/node-openid-client/commit/c981ed68e5cb0a53f064eb27604d8790ef3dac91)), closes [#222](https://github.com/panva/node-openid-client/issues/222)
338
-
339
-
340
-
341
- ## [3.11.0](https://github.com/panva/node-openid-client/compare/v3.10.1...v3.11.0) (2020-01-10)
342
-
343
-
344
- ### Bug Fixes
345
-
346
- * **typescript:** allow 'id_token token' as a response type ([61c486c](https://github.com/panva/node-openid-client/commit/61c486c2b800c9299f4eaf3649711c39a6e5ce57))
347
-
348
-
349
- ### Features
350
-
351
- * detect self-issued OP and validate ID Token accordingly ([c5d3158](https://github.com/panva/node-openid-client/commit/c5d315826a767d1479509931eddb5ae6e3b99532)), closes [#220](https://github.com/panva/node-openid-client/issues/220) [#221](https://github.com/panva/node-openid-client/issues/221)
352
-
353
-
354
-
355
- ## [3.10.1](https://github.com/panva/node-openid-client/compare/v3.10.0...v3.10.1) (2020-01-07)
356
-
357
-
358
- ### Bug Fixes
359
-
360
- * allow duplicate "kid" values in issuer's jwks_uri (sigh) ([8840fb6](https://github.com/panva/node-openid-client/commit/8840fb6e9cb2b3f8e6396b596ff90f8f080e7f7a))
361
-
362
-
363
-
364
- ## [3.10.0](https://github.com/panva/node-openid-client/compare/v3.9.2...v3.10.0) (2019-12-27)
365
-
366
-
367
- ### Bug Fixes
368
-
369
- * enabled full JWT validation on distributed and aggregated claims ([d95e31b](https://github.com/panva/node-openid-client/commit/d95e31bf33bf3dc9a90e420a6dc90bbfd964d885))
370
-
371
-
372
- ### Features
373
-
374
- * allow consuming JARM responses (jwt response mode) ([dd4aae9](https://github.com/panva/node-openid-client/commit/dd4aae92eafbdde5ac11c2d7d422d150ceed45da))
375
-
376
-
377
-
378
- ## [3.9.2](https://github.com/panva/node-openid-client/compare/v3.9.1...v3.9.2) (2019-12-17)
379
-
380
-
381
- ### Bug Fixes
382
-
383
- * skip validating iat is in the past ([0791001](https://github.com/panva/node-openid-client/commit/0791001a6e0244ac3fbde8b9e6cf206d97f82fbe))
384
-
385
-
386
-
387
- ## [3.9.1](https://github.com/panva/node-openid-client/compare/v3.9.0...v3.9.1) (2019-12-15)
388
-
389
-
390
- ### Bug Fixes
391
-
392
- * remove check for nonce presence in params ([cac46fb](https://github.com/panva/node-openid-client/commit/cac46fb1846c853f6c519beddd5ab5bdaf0770b1))
393
-
394
-
395
-
396
- ## [3.9.0](https://github.com/panva/node-openid-client/compare/v3.8.4...v3.9.0) (2019-12-06)
397
-
398
-
399
- ### Bug Fixes
400
-
401
- * check for mTLS request options during token_endpoint calls ([269569f](https://github.com/panva/node-openid-client/commit/269569fbb08139694589f1b27bda690b8d8474fe))
402
- * **typescript:** complete http options ([3997687](https://github.com/panva/node-openid-client/commit/3997687cc68bf76bc92ac143c5e5fe3b9cbd3914))
403
-
404
-
405
- ### Features
406
-
407
- * added API for fetching any resource ([ae242a5](https://github.com/panva/node-openid-client/commit/ae242a5c058386a3607af4a662dbf696938bc6f1))
408
- * added issuer.FAPIClient for FAPI RW integrations ([ab88aa5](https://github.com/panva/node-openid-client/commit/ab88aa590fb5a853ddbd8273a713bf142a9f5049))
409
-
410
-
411
-
412
- ## [3.8.4](https://github.com/panva/node-openid-client/compare/v3.8.3...v3.8.4) (2019-11-26)
413
-
414
-
415
- ### Bug Fixes
416
-
417
- * use shake256(m, 114) for Ed448 ID Token _hash claims ([80311c8](https://github.com/panva/node-openid-client/commit/80311c89273d9e2577dc694f1ac91a00944cc026))
418
-
419
-
420
-
421
- ## [3.8.3](https://github.com/panva/node-openid-client/compare/v3.8.2...v3.8.3) (2019-11-14)
422
-
423
-
424
-
425
- ## [3.8.2](https://github.com/panva/node-openid-client/compare/v3.8.1...v3.8.2) (2019-11-10)
426
-
427
-
428
- ### Bug Fixes
429
-
430
- * assert jwks is present for private_key_jwk first ([c1f875c](https://github.com/panva/node-openid-client/commit/c1f875c0c4a472b2dc424bc9de21a9cbdc8ca8ad))
431
-
432
-
433
-
434
- ## [3.8.1](https://github.com/panva/node-openid-client/compare/v3.8.0...v3.8.1) (2019-11-07)
435
-
436
-
437
- ### Bug Fixes
438
-
439
- * use sha512 for Ed25519 and shake256 for Ed448 ID Token _hash claims ([31f7a04](https://github.com/panva/node-openid-client/commit/31f7a040c289e7fd389a0083803f2998bf62b660))
440
-
441
-
442
-
443
- ## [3.8.0](https://github.com/panva/node-openid-client/compare/v3.7.4...v3.8.0) (2019-11-07)
444
-
445
-
446
- ### Features
447
-
448
- * allow tokenType for userinfo to use as authorization header scheme ([4eaa75f](https://github.com/panva/node-openid-client/commit/4eaa75f714a744f9e712615dedc6702f4f9b7a64))
449
-
450
-
451
-
452
- ## [3.7.4](https://github.com/panva/node-openid-client/compare/v3.7.3...v3.7.4) (2019-10-24)
453
-
454
-
455
- ### Bug Fixes
456
-
457
- * allow distributed claims to be missing from the response ([48d6633](https://github.com/panva/node-openid-client/commit/48d6633af2bb5d724c2fee2628fdfc871324bb94)), closes [#197](https://github.com/panva/node-openid-client/issues/197)
458
-
459
-
460
-
461
- ## [3.7.3](https://github.com/panva/node-openid-client/compare/v3.7.2...v3.7.3) (2019-10-01)
462
-
463
-
464
- ### Bug Fixes
465
-
466
- * use updated jose package ([1f3a251](https://github.com/panva/node-openid-client/commit/1f3a251))
467
-
468
-
469
-
470
- ## [3.7.2](https://github.com/panva/node-openid-client/compare/v3.7.1...v3.7.2) (2019-09-13)
471
-
472
-
473
- ### Bug Fixes
474
-
475
- * **typescript:** add missing Strategy interface properties ([c0d59c4](https://github.com/panva/node-openid-client/commit/c0d59c4)), closes [#189](https://github.com/panva/node-openid-client/issues/189)
476
-
477
-
478
-
479
- ## [3.7.1](https://github.com/panva/node-openid-client/compare/v3.7.0...v3.7.1) (2019-09-09)
480
-
481
-
482
- ### Bug Fixes
483
-
484
- * **typescript:** remove the need for @types/got dependency ([e5a50d7](https://github.com/panva/node-openid-client/commit/e5a50d7))
485
-
486
-
487
-
488
- ## [3.7.0](https://github.com/panva/node-openid-client/compare/v3.6.2...v3.7.0) (2019-09-09)
489
-
490
-
491
- ### Bug Fixes
492
-
493
- * assert client_secret is present when required, require client_id, etc ([82855a5](https://github.com/panva/node-openid-client/commit/82855a5))
494
-
495
-
496
- ### Features
497
-
498
- * Add Typescript definitions ([#184](https://github.com/panva/node-openid-client/issues/184)) ([c37130b](https://github.com/panva/node-openid-client/commit/c37130b))
499
- * allow clientAssertionPayload to overwrite default payload ([28c8964](https://github.com/panva/node-openid-client/commit/28c8964))
500
-
501
-
502
-
503
- ## [3.6.2](https://github.com/panva/node-openid-client/compare/v3.6.1...v3.6.2) (2019-09-03)
504
-
505
-
506
- ### Bug Fixes
507
-
508
- * device authorization request always pushes the client_id to body ([6fbf125](https://github.com/panva/node-openid-client/commit/6fbf125))
509
-
510
-
511
-
512
- ## [3.6.1](https://github.com/panva/node-openid-client/compare/v3.6.0...v3.6.1) (2019-08-24)
513
-
514
-
515
- ### Bug Fixes
516
-
517
- * ignore runtime unsupported or malformed issuer jwks ([f08b8be](https://github.com/panva/node-openid-client/commit/f08b8be))
518
-
519
-
520
-
521
- ## [3.6.0](https://github.com/panva/node-openid-client/compare/v3.5.0...v3.6.0) (2019-08-24)
522
-
523
-
524
- ### Features
525
-
526
- * add RFC8628 - OAuth 2.0 Device Authorization Grant (Device Flow) support ([adb4b76](https://github.com/panva/node-openid-client/commit/adb4b76))
527
- * allow multiple resource parameters in authorization requests ([dfdd8cb](https://github.com/panva/node-openid-client/commit/dfdd8cb))
528
-
529
-
530
-
531
- ## [3.5.0](https://github.com/panva/node-openid-client/compare/v3.4.0...v3.5.0) (2019-08-22)
532
-
533
-
534
- ### Features
535
-
536
- * added Node.js lts/dubnium support for runtime supported features ([54788c2](https://github.com/panva/node-openid-client/commit/54788c2))
537
-
538
-
539
-
540
- ## [3.4.0](https://github.com/panva/node-openid-client/compare/v3.3.0...v3.4.0) (2019-08-13)
541
-
542
-
543
- ### Features
544
-
545
- * electron v6.x runtime support ([65ec619](https://github.com/panva/node-openid-client/commit/65ec619))
546
-
547
-
548
-
549
- ## [3.3.0](https://github.com/panva/node-openid-client/compare/v3.2.3...v3.3.0) (2019-08-02)
550
-
551
-
552
- ### Features
553
-
554
- * option to change http options globally ([a1e0a3f](https://github.com/panva/node-openid-client/commit/a1e0a3f))
555
-
556
-
557
-
558
- ## [3.2.3](https://github.com/panva/node-openid-client/compare/v3.2.2...v3.2.3) (2019-07-18)
559
-
560
-
561
- ### Bug Fixes
562
-
563
- * **strategy:** do not modify the params argument, clone it instead ([4731d29](https://github.com/panva/node-openid-client/commit/4731d29)), closes [#177](https://github.com/panva/node-openid-client/issues/177)
564
-
565
-
566
-
567
- ## [3.2.2](https://github.com/panva/node-openid-client/compare/v3.2.1...v3.2.2) (2019-07-12)
568
-
569
-
570
- ### Bug Fixes
571
-
572
- * give AAD v2 organizations and consumers same treatment as common ([4891b5b](https://github.com/panva/node-openid-client/commit/4891b5b)), closes [#175](https://github.com/panva/node-openid-client/issues/175)
573
-
574
-
575
-
576
- ## [3.2.1](https://github.com/panva/node-openid-client/compare/v3.2.0...v3.2.1) (2019-07-10)
577
-
578
-
579
- ### Bug Fixes
580
-
581
- * plug reported lodash vulnerability ([b690dac](https://github.com/panva/node-openid-client/commit/b690dac))
582
-
583
-
584
-
585
- ## [3.2.0](https://github.com/panva/node-openid-client/compare/v3.1.2...v3.2.0) (2019-06-27)
586
-
587
-
588
- ### Features
589
-
590
- * feat: added support for direct symmetric key encryption alg (dir) ([f1b4282](https://github.com/panva/node-openid-client/commit/f1b4282))
591
-
592
-
593
-
594
- ## [3.1.2](https://github.com/panva/node-openid-client/compare/v3.1.1...v3.1.2) (2019-06-21)
595
-
596
-
597
- ### Bug Fixes
598
-
599
- * ensure runtime @panva/jose dependency ^1.3.0 ([d992deb](https://github.com/panva/node-openid-client/commit/d992deb))
600
-
601
-
602
-
603
- ## [3.1.1](https://github.com/panva/node-openid-client/compare/v3.1.0...v3.1.1) (2019-05-15)
604
-
605
-
606
- ### Bug Fixes
607
-
608
- * passport strategy runtime authenticate parameters regression ([36e741e](https://github.com/panva/node-openid-client/commit/36e741e)), closes [#167](https://github.com/panva/node-openid-client/issues/167)
609
-
610
-
611
-
612
- ## [3.1.0](https://github.com/panva/node-openid-client/compare/v3.0.0...v3.1.0) (2019-05-13)
613
-
614
-
615
- ### Features
616
-
617
- * add helpers for generating secure random values & PKCE challenges ([44f1865](https://github.com/panva/node-openid-client/commit/44f1865))
618
-
619
-
620
-
621
- ## [3.0.0](https://github.com/panva/node-openid-client/compare/v2.5.0...v3.0.0) (2019-05-11)
622
-
623
-
624
- ### Bug Fixes
625
-
626
- * authorizationParams no longer requires nonce for `response_type=token`
627
- * issuer's auth signing algs presence is now asserted if client is missing the relevant metadata property
628
- * unintended (client|issuer).metadata[property] reassignment is no longer possible
629
- * refreshed encrypted ID Tokens are now properly decrypted
630
- * userinfo_endpoint presence on an issuer is now asserted during userinfo function call
631
- * PBES2 symmetric encryption and decryption now correctly uses the `client_secret` value rather then
632
- its SHA digest
633
- * Accept header is now correctly set for all requests
634
- * clients configured to receive signed and/or encrypted userinfo endpoints will now correctly reject
635
- a response that isn't proper `application/jwt`
636
-
637
-
638
- ### Features
639
-
640
- * **Typed Errors** - openid-client now has unique errors for HTTP transport related errors, OP/AS
641
- returned errors and RP(client-side) assertions.
642
- * **common configuration issues are now gracefully handled.** I feel like many developers may be
643
- setting properties like `redirect_uri` or `response_type` on a client instance. I sympathize and
644
- openid-client will now take these common mistakes and accomodate.
645
- * **QoL** `#client.authorizationParams()` will now attempt to resolve the `redirect_uri` and
646
- `response_type` from your client's metadata. If there's only one listed, it will be used
647
- automatically. If there's more, you must continue providing it explicitly.
648
- * **per-request http request options helper function** HTTP request options can now be modified on
649
- a per request basis for the different classes or their instances. This now allows each request's
650
- options to be altered on-demand with e.g. client mutual-TLS certificates or implementing work
651
- arounds for specific AS quirks.
652
- * **mutual-TLS client authentication** is now supported through the above mentioned helper for both
653
- client-authentication and proof-of-possession purposes.
654
- * **custom request bodies** Where the above per-request helper falls short is providing extra
655
- token endpoint exchange parameters like `resource` to authorization code or refresh token exchange,
656
- you can now pass those in the actual client methods.
657
- * **custom client assertion payloads** You can now pass extra claims to the client authenticated
658
- calls e.g. token, introspect, revoke.
659
- * **request objects are now set to be one-time use** Generated Request Objects are secure by default
660
- they include iat, exp and jti claims so that OPs have a way to make them one-time use depending on
661
- their policy.
662
- * **EdDSA support** OKP JSON Web Keys and EdDSA signing and verification is now supported.
663
-
664
-
665
- ### BREAKING CHANGES
666
- * openid-client now uses `@panva/jose` for all things JOSE. As a result of this the minimum required
667
- node version is v12.0.0 and the client will now only function in node.js environments.
668
- * `Issuer.defaultHttpOptions` getter and setter were removed. See documentation customization
669
- section for its replacement.
670
- * `client.CLOCK_TOLERANCE` client property was removed. See documentation customization section for
671
- its replacement.
672
- * `client.authorizationCallback()` has been renamed to `client.callback()`
673
- * `tokenset.claims` getter is now a function `tokenset.claims()`
674
- * `useRequest` and `useGot` methods were removed, with the maintenance mode and inevitable
675
- deprecation of the `request` module i've decided to only support got as an http request library.
676
- * Instead of passing jose library keystore instances with private keys the API now
677
- expects a JWKS formatted object. `keystore` options argument properties are now called just `jwks`.
678
- * `response_type=code` is no longer defaulted to in `#client.authorizationUrl()` if your client
679
- instance has multiple `response_types` members.
680
- * Strict `===` equality operator is now used for assertions, while unlikely the breaking change is
681
- that should some ID Token claims be correct values but incorrect type, these will start failing now.
682
- * `#client.revoke()` no longer returns or in any way processes the response body as per spec
683
- requirements.
684
- * All http(s) responses are now strictly checked for the expected http response status code.
685
- * All http(s) requests now assert that an absolute URL is being requested.
686
- * Passport Strategy will now fail when userinfo is requested via the verify callback arity but no
687
- access token is returned from the OP.
688
-
689
-
690
-
691
- ## [2.5.0](https://github.com/panva/node-openid-client/compare/v2.4.5...v2.5.0) (2019-04-29)
692
-
693
-
694
- ### Bug Fixes
695
-
696
- * key lookup cache is now working as intended ([90d2f2a](https://github.com/panva/node-openid-client/commit/90d2f2a)), closes [#162](https://github.com/panva/node-openid-client/issues/162)
697
-
698
-
699
- ### Features
700
-
701
- * add support for azure ad v2 multitenant apps ([24486dd](https://github.com/panva/node-openid-client/commit/24486dd)), closes [#148](https://github.com/panva/node-openid-client/issues/148)
702
-
703
-
704
-
705
- ## [2.4.5](https://github.com/panva/node-openid-client/compare/v2.4.4...v2.4.5) (2018-11-05)
706
-
707
-
708
- ### Bug Fixes
709
-
710
- * upgrade min node-jose version to fix its performance in node ([e682dfc](https://github.com/panva/node-openid-client/commit/e682dfc))
711
-
712
-
713
-
714
- ## [2.4.4](https://github.com/panva/node-openid-client/compare/v2.4.3...v2.4.4) (2018-10-18)
715
-
716
-
717
- ### Bug Fixes
718
-
719
- * strategy code_verifier length, removed uuid dependency ([60d0cb8...ea4a8fd](https://github.com/panva/node-openid-client/compare/60d0cb8...ea4a8fd)), closes [#131](https://github.com/panva/node-openid-client/issues/131)
720
-
721
-
722
-
723
- ## [2.4.3](https://github.com/panva/node-openid-client/compare/v2.4.2...v2.4.3) (2018-10-10)
724
-
725
-
726
- ### Bug Fixes
727
-
728
- * assign Discovery 1.0 defaults when discovering with .well-known ([74b593e](https://github.com/panva/node-openid-client/commit/74b593e))
729
-
730
-
731
-
732
- ## [2.4.2](https://github.com/panva/node-openid-client/compare/v2.4.1...v2.4.2) (2018-09-27)
733
-
734
-
735
- ### Bug Fixes
736
-
737
- * non-string error responses are not treated as OpenIdConnectError ([782d464](https://github.com/panva/node-openid-client/commit/782d464)), closes [#125](https://github.com/panva/node-openid-client/issues/125)
738
-
739
-
740
-
741
- ## [2.4.1](https://github.com/panva/node-openid-client/compare/v2.4.0...v2.4.1) (2018-09-16)
742
-
743
-
744
- ### Bug Fixes
745
-
746
- * lts/boron unsupported syntax fix ([5289188](https://github.com/panva/node-openid-client/commit/5289188))
747
-
748
-
749
-
750
- ## [2.4.0](https://github.com/panva/node-openid-client/compare/v2.3.1...v2.4.0) (2018-09-16)
751
-
752
-
753
- ### Bug Fixes
754
-
755
- * OpenIdConnectError also returns session_state ([95fae3d](https://github.com/panva/node-openid-client/commit/95fae3d))
756
- * stop sending state on the authorisation code token grant ([c4c9e50](https://github.com/panva/node-openid-client/commit/c4c9e50))
757
-
758
-
759
- ### Features
760
-
761
- * add RP-Initiated Logout URL helper ([7c2e030](https://github.com/panva/node-openid-client/commit/7c2e030)), closes [#116](https://github.com/panva/node-openid-client/issues/116)
762
-
763
-
764
-
765
- ## [2.3.1](https://github.com/panva/node-openid-client/compare/v2.3.0...v2.3.1) (2018-08-23)
766
-
767
-
768
- ### Bug Fixes
769
-
770
- * apply safer, simpler www-authenticate parsing regex ([ffce55a](https://github.com/panva/node-openid-client/commit/ffce55a))
771
- * only assign Discovery 1.0 defaults when Issuer is discovered ([dca60b8](https://github.com/panva/node-openid-client/commit/dca60b8))
772
-
773
-
774
-
775
- ## [2.3.0](https://github.com/panva/node-openid-client/compare/v2.2.1...v2.3.0) (2018-08-11)
776
-
777
-
778
- ### Features
779
-
780
- * authorization response parameter checking based on response_type ([6e0ac57](https://github.com/panva/node-openid-client/commit/6e0ac57))
781
- * passport strategy automatically checks response REQUIRED params ([902eeed](https://github.com/panva/node-openid-client/commit/902eeed))
782
-
783
-
784
-
785
- # Pre standard-version Change Log
786
- ## Version 2.2.x
787
- ### Version 2.2.1
788
- - 2018-07-10 [DIFF](https://github.com/panva/node-openid-client/compare/v2.2.0...v2.2.1)
789
- - improved discovery support of custom .well-known suffixes
790
- - chores - refactoring, missing tests, cleanup
791
-
792
- ### Version 2.2.0
793
- - 2018-07-04 [DIFF](https://github.com/panva/node-openid-client/compare/v2.1.1...v2.2.0)
794
- - added support for [RFC8414 - OAuth 2.0 Authorization Server Metadata](https://tools.ietf.org/html/rfc8414)
795
- discovery
796
-
797
- ## Version 2.1.x
798
- ### Version 2.1.1
799
- - 2018-06-28 [DIFF](https://github.com/panva/node-openid-client/compare/v2.1.0...v2.1.1)
800
- - fixed handling of bearer endpoint responses with www-authenticate headers only. fixes #102
801
-
802
- ### Version 2.1.0
803
- - 2018-05-31 [DIFF](https://github.com/panva/node-openid-client/compare/v2.0.4...v2.1.0)
804
- - `node-jose` dependency bumped to major ^1.0.0 - fixes `A\d{3}GCMKW` symmetrical encryption support
805
- - dependency updates
806
-
807
- ## Version 2.0.x
808
- ### Version 2.0.4
809
- - 2018-05-25 [DIFF](https://github.com/panva/node-openid-client/compare/v2.0.3...v2.0.4)
810
- - fixed circular when serializing OpenIdConnectError
811
- - base64url dependency update
812
-
813
- ### Version 2.0.3
814
- - 2018-05-15 [DIFF](https://github.com/panva/node-openid-client/compare/v2.0.2...v2.0.3)
815
- - base64url dependency replaced
816
-
817
- ### Version 2.0.2
818
- - 2018-05-10 [DIFF](https://github.com/panva/node-openid-client/compare/v2.0.1...v2.0.2)
819
- - dependency tree updates
820
-
821
- ### Version 2.0.1
822
- - 2018-04-26 [DIFF](https://github.com/panva/node-openid-client/compare/v2.0.0...v2.0.1)
823
- - fixed `client_secret_basic` requiring the username and password tokens to be `x-www-form-urlencoded`
824
- according to https://tools.ietf.org/html/rfc6749#section-2.3.1
825
- - NOTE: Although technically a fix, this is a breaking change when used with providers that also
826
- don't currently follow the standard. A proper way of submitting client_id and client_secret using
827
- `client_secret_basic` is `Authorization: base64(formEncode(client_id):formEncode(client_secret))`.
828
- If your client_id and client_secret does contain special characters that need encoding this does not
829
- affect you. If it does, try using `client_secret_post` instead.
830
-
831
- ### Version 2.0.0
832
- - 2018-04-12 [DIFF](https://github.com/panva/node-openid-client/compare/v1.20.0...v2.0.0)
833
- - dropped support for Node.js v4.x due to its End-of-Life on [2018-04-30](https://github.com/nodejs/Release)
834
- - removed deprecated `client#grantAuth`
835
- - removed deprecated way of passing keystore directly to `Client#register`
836
- - removed support for passing client to `OpenIDConnectStrategy` as single argument, use
837
- `new Strategy({ client })` instead of `new Strategy(client)`.
838
- - fixed a bug requiring nonce to be passed for `response_type=none`
839
-
840
- ## Version 1.20.0
841
- - 2018-03-13 [DIFF](https://github.com/panva/node-openid-client/compare/v1.19.5...v1.20.0)
842
- - added documentation for `OpenIdConnectError`
843
- - added `error_uri` from IdP responses to `OpenIdConnectError` instances
844
- - fixed `OpenIdConnectError` messages to include `error_description`
845
-
846
- ## Version 1.19.x
847
- ### Version 1.19.5
848
- - 2018-03-10 [DIFF](https://github.com/panva/node-openid-client/compare/v1.19.4...v1.19.5)
849
- - `Issuer.discover` now parses the provided URI instead of just inspecting the string. #80
850
-
851
- ### Version 1.19.4
852
- - 2018-01-30 [DIFF](https://github.com/panva/node-openid-client/compare/v1.19.3...v1.19.4)
853
- - fixed edge cases of (and simplified) private id token decryption method
854
-
855
- ### Version 1.19.3
856
- - 2018-01-22 [DIFF](https://github.com/panva/node-openid-client/compare/v1.19.2...v1.19.3)
857
- - fix return values of `#authorizationCallback()` for `response_type=none` to resolve a TokenSet
858
-
859
- ### Version 1.19.2
860
- - 2018-01-16 [DIFF](https://github.com/panva/node-openid-client/compare/v1.19.1...v1.19.2)
861
- - fixed `authorizationUrl` to respect existing issuer authorization_endpoint query parameters
862
-
863
- ### Version 1.19.1
864
- - 2018-01-15 [DIFF](https://github.com/panva/node-openid-client/compare/v1.19.0...v1.19.1)
865
- - adjusted the passport state mismatch related error message to hint developers at a local setup
866
- issue
867
-
868
- ### Version 1.19.0
869
- - 2017-12-12 [DIFF](https://github.com/panva/node-openid-client/compare/v1.18.2...v1.19.0)
870
- - added maintained request wrapper and a simple api to use request instead of `got`
871
-
872
- ## Version 1.18.x
873
- ### Version 1.18.2
874
- - 2017-12-05 [DIFF](https://github.com/panva/node-openid-client/compare/v1.18.1...v1.18.2)
875
- - bumped node-jose dependency
876
-
877
- ### Version 1.18.1
878
- - 2017-11-25 [DIFF](https://github.com/panva/node-openid-client/compare/v1.18.0...v1.18.1)
879
- - fixed the order of several `assert.equal` calls to swap actual/expected descriptions
880
- - added assertion error messages for passport strategy
881
-
882
- ### Version 1.18.0
883
- - 2017-11-19 [DIFF](https://github.com/panva/node-openid-client/compare/v1.17.0...v1.18.0)
884
- - added option for the passport strategy to use PKCE
885
- - updated http request library `got` dependency
886
-
887
- ## Version 1.17.0
888
- - 2017-10-31 [DIFF](https://github.com/panva/node-openid-client/compare/v1.16.0...v1.17.0)
889
- - now uses `client_secret_post` as default for Issuer instances that do not support
890
- `client_secret_basic` but do signal support for `client_secret_post` in their discovery document
891
-
892
- ## Version 1.16.0
893
- - 2017-10-13 [DIFF](https://github.com/panva/node-openid-client/compare/v1.15.0...v1.16.0)
894
- - added `s_hash` value validation support for ID Tokens returned by authorization endpoint
895
- - fixed edge cases where valid `_hash` but from invalid sha-length was accepted
896
-
897
- ## Version 1.15.0
898
- - 2017-09-11 [DIFF](https://github.com/panva/node-openid-client/compare/v1.14.0...v1.15.0)
899
- - added support for Request Objects encrypted with symmetrical keys
900
- - fixed PBES2 encryption to use client_secret derived symmetrical key instead of its full octet value
901
-
902
- ## Version 1.14.0
903
- - 2017-09-09 [DIFF](https://github.com/panva/node-openid-client/compare/v1.13.0...v1.14.0)
904
- - added Passport Strategy `passReqToCallback` option, defaults to false
905
-
906
- ## Version 1.13.0
907
- - 2017-08-24 [DIFF](https://github.com/panva/node-openid-client/compare/v1.12.1...v1.13.0)
908
- - added an optional keystore argument to `Client#fromUri(uri, token, [keystore])` to pass a keystore
909
- with private asymmetrical keys
910
- - fixed keystore check during constructor `Client#new` calls to check that only private asymmetrical
911
- keys are added
912
-
913
- ## Version 1.12.0
914
- ### Version 1.12.1
915
- - 2017-08-11 [DIFF](https://github.com/panva/node-openid-client/compare/v1.12.0...v1.12.1)
916
- - explicitly specified accepted response type via `accept: application/json` header
917
- - added state to token_endpoint calls for servers supporting mixup mitigation
918
-
919
- ### Version 1.12.0
920
- - 2017-07-17 [DIFF](https://github.com/panva/node-openid-client/compare/v1.11.1...v1.12.0)
921
- - Allow session key to be specified in passport strategy options
922
-
923
- ## Version 1.11.0
924
- ### Version 1.11.1
925
- - 2017-07-14 [DIFF](https://github.com/panva/node-openid-client/compare/v1.11.0...v1.11.1)
926
- - relaxed #callbackParams to allow IncomingMessage lookalikes
927
- - update internal dependencies
928
-
929
- ### Version 1.11.0
930
- - 2017-05-19 [DIFF](https://github.com/panva/node-openid-client/compare/v1.10.0...v1.11.0)
931
- - fixed default application_type from `['web']` to `'web'`
932
- - added barebones `Issuer.httpClient` setter to help advanced developers in complex environments
933
- to change the used http request client
934
-
935
- ## Version 1.10.0
936
- - 2017-05-04 [DIFF](https://github.com/panva/node-openid-client/compare/v1.9.0...v1.10.0)
937
- - added pure OAuth 2.0 stripped down callback function `#oauthCallback`
938
- - added an extra option for `#userinfo` requests to have extra params in either query or body
939
-
940
- ## Version 1.9.0
941
- - 2017-04-30 [DIFF](https://github.com/panva/node-openid-client/compare/v1.8.2...v1.9.0)
942
- - added introspection/revocation specific client and issuer properties. To remain backwards
943
- compatible they default to their token endpoint counterparts
944
- - issuer.revocation_endpoint_auth_methods_supported
945
- - issuer.introspection_endpoint_auth_methods_supported
946
- - issuer.revocation_endpoint_auth_signing_alg_values_supported
947
- - issuer.introspection_endpoint_auth_signing_alg_values_supported
948
- - client.revocation_endpoint_auth_method
949
- - client.introspection_endpoint_auth_method
950
- - client.revocation_endpoint_auth_signing_alg
951
- - client.introspection_endpoint_auth_signing_alg
952
-
953
- ## Version 1.8.0
954
- ### Version 1.8.2
955
- - 2017-04-29 [DIFF](https://github.com/panva/node-openid-client/compare/v1.8.0...v1.8.2)
956
- - bumped node-jose dependency to avoid github tar.gz dependencies
957
- - adjusted token_endpoint_auth_method=none to how it should be
958
-
959
- ### Version 1.8.0
960
- - 2017-04-07 [DIFF](https://github.com/panva/node-openid-client/compare/v1.7.2...v1.8.0)
961
- - Issuer and Client now recognize custom properties, this is so that new Registry Contents do not
962
- require a new release of openid-client to be picked up. Custom properties are exposed as getters
963
- so long as they do not interfere with the object's Prototype and they are always available in
964
- `#metadata` getter.
965
-
966
- ## Version 1.7.0
967
- ### Version 1.7.2
968
- - 2017-03-28 [DIFF](https://github.com/panva/node-openid-client/compare/v1.7.1...v1.7.2)
969
- - added missing check for webfinger issuer location protocol
970
-
971
- ### Version 1.7.1
972
- - 2017-03-28 [DIFF](https://github.com/panva/node-openid-client/compare/v1.6.4...v1.7.1)
973
- - added authorizationCallback support for submitting code_verifier
974
- - example now includes session management OP and RP frames
975
-
976
- 1.7.0 failed to publish properly, use 1.7.1 instead
977
-
978
- ## Version 1.6.0
979
- ### Version 1.6.4
980
- - 2017-03-14 [DIFF](https://github.com/panva/node-openid-client/compare/v1.6.3...v1.6.4)
981
- - fixed receiving (correct) empty responses from revocation endpoints (#21)
982
-
983
- ### Version 1.6.3
984
- - 2017-03-14 [DIFF](https://github.com/panva/node-openid-client/compare/v1.6.2...v1.6.3)
985
- - bumped minimum node-jose version to cover http://blog.intothesymmetry.com/2017/03/critical-vulnerability-in-json-web.html
986
-
987
- ### Version 1.6.2
988
- - 2017-03-09 [DIFF](https://github.com/panva/node-openid-client/compare/v1.6.1...v1.6.2)
989
- - fixed verify callback skipping userinfo when userinfo_endpoint is not configured (#19)
990
- - removed mandatory checks from passport strategy, allowing i.e. implicit only OPs (#19)
991
-
992
- ### Version 1.6.1
993
- - 2017-03-07 [DIFF](https://github.com/panva/node-openid-client/compare/v1.6.0...v1.6.1)
994
- - fixed verify callback skipping userinfo call when arity says it should but no access token is present (#18)
995
-
996
- ### Version 1.6.0
997
- - 2017-02-15 [DIFF](https://github.com/panva/node-openid-client/compare/v1.5.3...v1.6.0)
998
- - added at_hash presence assertion for applicable (implicit) ID Token validation
999
- - added c_hash presence assertion for applicable (hybrid) ID Token validation from the authorization_endpoint
1000
-
1001
- ## Version 1.5.0
1002
- ### Version 1.5.3
1003
- - 2017-02-15 [DIFF](https://github.com/panva/node-openid-client/compare/v1.5.2...v1.5.3)
1004
- - fixed an ID Token validation for ID Token returned by Token Endpoint that includes c_hash
1005
-
1006
- ### Version 1.5.2
1007
- - 2017-02-01 [DIFF](https://github.com/panva/node-openid-client/compare/v1.5.1...v1.5.2)
1008
- - fixed passport strategy, have it use prototype instead of ES6 class syntax
1009
-
1010
- ### Version 1.5.1
1011
- - 2017-01-29 [DIFF](https://github.com/panva/node-openid-client/compare/v1.5.0...v1.5.1)
1012
- - fixed client_assertion aud claim for `_jwt` auth methods when used in introspection and revocation
1013
-
1014
- ### Version 1.5.0
1015
- - 2017-01-26 [DIFF](https://github.com/panva/node-openid-client/compare/v1.4.0...v1.5.0)
1016
- - added a passport.js strategy
1017
- - added missing max_age, default_max_age related functionality
1018
- - authorizationCallback now supports max_age check
1019
- - clients with default_max_age use this default value automatically
1020
- - when max_age is checked auth_time claim is mandatory and must be a number
1021
- - added missing require_auth_time related functionality
1022
- - clients with require_auth_time = true have the presence and format of auth_time claim validated
1023
- - authorizationUrl and authorizationPost now removes null and undefined values and ensures parameters
1024
- are stringified before passed to url.format
1025
- - added client.CLOCK_TOLERANCE property, to allow for clock skew (in seconds)
1026
-
1027
- ## Version 1.4.0
1028
- - 2017-01-10 [DIFF](https://github.com/panva/node-openid-client/compare/v1.3.1...v1.4.0)
1029
- - deprecated passing keystore directly to Client#register, pass an object with keystore property instead
1030
- - added the option to provide InitialAccessToken value to Client#register
1031
-
1032
- ## Version 1.3.0
1033
- ### Version 1.3.1
1034
- - 2016-12-18 [DIFF](https://github.com/panva/node-openid-client/compare/v1.3.0...v1.3.1)
1035
- - added error messages when expected response is missing
1036
-
1037
- ### Version 1.3.0
1038
- - 2016-12-13 [DIFF](https://github.com/panva/node-openid-client/compare/v1.2.0...v1.3.0)
1039
- - added `#requestObject` method to Client to return signed and/or encrypted Request Object
1040
-
1041
- ## Version 1.2.0
1042
- - 2016-12-09 [DIFF](https://github.com/panva/node-openid-client/compare/v1.1.0...v1.2.0)
1043
- - added `#claims` getter to TokenSets returned from `authorizationCallback` and `refresh`;
1044
-
1045
- ## Version 1.1.0
1046
- - 2016-11-23 [DIFF](https://github.com/panva/node-openid-client/compare/v1.0.2...v1.1.0)
1047
- - fixed unpacking aggregated claims with alg=none and no iss claim
1048
- - fetching distributed claims now expects a JWT response, previously expected invalid OP responses
1049
-
1050
- ## Version 1.0.0
1051
- ### Version 1.0.2
1052
- - 2016-11-22 [DIFF](https://github.com/panva/node-openid-client/compare/v1.0.1...v1.0.2)
1053
- - fixed signed userinfo response validation in case iss, aud and similar ID Token claims are missing
1054
-
1055
- ### Version 1.0.1
1056
- - 2016-11-18 [DIFF](https://github.com/panva/node-openid-client/compare/v1.0.0...v1.0.1)
1057
- - Updated uuid dependency
1058
-
1059
- ### Version 1.0.0
1060
- RP test tools are passing, no changes required from the library, API is declared stable, hence 1.0.0
1061
- release.
1062
-
1063
- - 2016-11-16 [DIFF](https://github.com/panva/node-openid-client/compare/v0.7.0...v1.0.0)
1064
- - See [1.x migration](#migrating-from-0x-to-10) to update your 0.x deployment into 1.x.
1065
-
1066
- ## Migrating from 0.x to 1.0
1067
-
1068
- 1. update your package.json file to `"^1.0.0"`
1069
- 2. sit back and relax, no breaking changes
1070
-
1071
- ## pre 1.x changelog
1072
-
1073
- 4. Major version zero (0.y.z) is for initial development. Anything may change at any time.
1074
- The public API should not be considered stable.
1075
-
1076
- 5. Version 1.0.0 defines the public API.
1077
-
1078
- - https://github.com/panva/node-openid-client/compare/v0.6.0...v0.7.0
1079
- - added: webfinger discovery
1080
- - added: callback parameter helper for node's http.IncomingMessage
1081
- - tested for lts/argon (4), lts/boron (6) and current stable (7)
1082
- - https://github.com/panva/node-openid-client/compare/v0.5.4...v0.6.0
1083
- - added: handling of symmetrically encrypted responses (A...GCMKW, A...KW, PBES2-HS...+A...KW)
1084
- - fix: state check supersedes error check, still not sure about it though
1085
- - https://github.com/panva/node-openid-client/compare/v0.5.0...v0.5.4
1086
- - added: token_type_hint for introspection and revocation
1087
- - fix: handle refresh w/o id_token
1088
- - fix: ignore nonce values when refreshing w/ id_token
1089
- - fix: validateIdToken only checks at_hash and c_hash values when TokenSet is passed in
1090
- - fix: session_state now part of returned TokenSet
1091
- - https://github.com/panva/node-openid-client/compare/v0.4.1...v0.5.0
1092
- - aggregated and distributed claim handling
1093
- - https://github.com/panva/node-openid-client/compare/v0.3.0...v0.4.1
1094
- - fix: issuer with path component discovery
1095
- - built-in signed and/or encrypted userinfo handling
1096
- - authorizationCallback handling of implicit and hybrid responses
1097
- - https://github.com/panva/node-openid-client/compare/v0.2.0...v0.3.0
1098
- - encrypted userinfo and idtoken response handling
1099
- - https://github.com/panva/node-openid-client/compare/v0.1.0...v0.2.0
1100
- - httpOptions configurable on a library level
1101
- - signed userinfo response handling