ADVISORIES

GitHub Advisory Database

GHSA-2h3h-vw8r-82rp

Weak JSON Web Token in yapi-vendor

Moderate CVE-2021-27884

Details

Weak JSON Web Token (JWT) signing secret generation in YMFE YApi through 1.9.2 allows recreation of other users' JWT tokens. This occurs because Math.random in Node.js is used as a source of randomness in jwt signing. Math.random does not provide cryptographically secure random numbers. This has been patched in version 1.9.3.

Affected packages

EcosystemPackageAffected versions
npmyapi-vendor
All versions before 1.9.3 (fixed in 1.9.3)

References