yurikrupnik / node-playground

playing more
0 stars 0 forks source link

Update dependency express-jwt to v6 [SECURITY] #4

Closed renovate[bot] closed 3 years ago

renovate[bot] commented 3 years ago

WhiteSource Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
express-jwt ^5.3.0 -> ^6.0.0 age adoption passing confidence

GitHub Vulnerability Alerts

CVE-2020-15084

Overview

Versions before and including 5.3.3, we are not enforcing the algorithms entry to be specified in the configuration. When algorithms is not specified in the configuration, with the combination of jwks-rsa, it may lead to authorization bypass.

Am I affected?

You are affected by this vulnerability if all of the following conditions apply:

You are using express-jwt AND You do not have algorithms configured in your express-jwt configuration. AND You are using libraries such as jwks-rsa as the secret.

How to fix that?

Specify algorithms in the express-jwt configuration. The following is an example of a proper configuration

const checkJwt = jwt({
  secret: jwksRsa.expressJwtSecret({
    rateLimit: true,
    jwksRequestsPerMinute: 5,
    jwksUri: `https://${DOMAIN}/.well-known/jwks.json`
  }),
  // Validate the audience and the issuer.
  audience: process.env.AUDIENCE,
  issuer: `https://${DOMAIN}/`,
  // restrict allowed algorithms
  algorithms: ['RS256']
}); 

Will this update impact my users?

The fix provided in patch will not affect your users if you specified the algorithms allowed. The patch now makes algorithms a required configuration.

Credit

IST Group


Release Notes

auth0/express-jwt ### [`v6.0.0`](https://togithub.com/auth0/express-jwt/blob/master/CHANGELOG.md#​600---2020-06-29) [Compare Source](https://togithub.com/auth0/express-jwt/compare/v5.3.3...v6.0.0) - Made algorithms mandatory ([304a1c5968aed7c4c520035426fc09142156669d](https://togithub.com/auth0/express-jwt/commit/304a1c5968aed7c4c520035426fc09142156669d))

Renovate configuration

:date: Schedule: "" (UTC).

:vertical_traffic_light: Automerge: Disabled by config. Please merge this manually once you are satisfied.

:recycle: Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

:no_bell: Ignore: Close this PR and you won't be reminded about this update again.



This PR has been generated by WhiteSource Renovate. View repository job log here.