> ## Documentation Index
> Fetch the complete documentation index at: https://auth0.generaltranslation.app/llms.txt
> Use this file to discover all available pages before exploring further.

# CVE-2020-15084：Express-jwtライブラリーのセキュリティ更新

> CVE-2020-15084：Express-jwtライブラリーのセキュリティ更新

**公開日**：2020年6月30日

**CVE番号**：CVE-2020-15084

**著者**：ISTグループ

<div id="overview">
  ## 概要
</div>

5.3.3以前のバージョンでは、構成内で指定する**アルゴリズム**の入力は義務化されていません。

構成内で、**アルゴリズム**が指定されていない場合、jwks-rsaやその他可能性がある非対称暗号ライブラリーと組み合わせると、認可バイパスにつながりかねません。

<div id="am-i-affected">
  ## 自分は影響を受けますか？
</div>

以下の条件がすべて当てはまる場合、この脆弱性によって影響を受けることになります。

* Express-<Tooltip data-tooltip-id="react-containers-DefinitionTooltip-0" href="/docs/ja-JP/ja-jp/glossary?term=json-web-token" tip="JSON Web Token（JWT）: 二者間のクレームを安全に表現するために使用される標準IDトークン形式（および多くの場合、アクセストークン形式）。" cta="用語集の表示">jwt</Tooltip>を使用しており、
* Express-jwt構成内で、**アルゴリズム**が構成されておらず、
* jwks-rsaを**シークレット**として使用している。

<div id="how-to-fix-that">
  ## 修正方法
</div>

Express-jwt構成内で、**アルゴリズム**を指定します。以下で、適切な構成例を紹介します。

```javascript lines theme={null}
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']
});
```

<div id="will-this-update-impact-my-users">
  ## この更新はユーザーに影響を与えますか？
</div>

許可されているアルゴリズムが指定されている場合、パッチで提供される修正はユーザーには影響しません。パッチ修正により、アルゴリズムが必須の構成となりました。
