Vulnerability · Published Sep 17, 2024 · Assigned by SNPS

CVE-2024-8796Insufficient Default OTP Shared Secret Length

Medium 5.3

In plain English

A medium-severity security flaw in devise-two-factor from devise-two-factor. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 0.6% (higher than 51% of all known vulnerabilities). Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)5.3Medium
Exploit odds (30 days)0.6%top 49.1% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack toolingNoneno public tooling known

Official description

Under the default configuration, Devise-Two-Factor versions >= 2.2.0 & < 6.0.0 generate TOTP shared secrets that are 120 bits instead of the 128-bit minimum defined by RFC 4226. Using a shared secret shorter than the minimum to generate a multi-factor authentication code could make it easier for an attacker to guess the shared secret and generate valid TOTP codes.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Debian:12ruby-devise-two-factorno fix listedDEBIAN-CVE-2024-8796
RubyGemsdevise-two-factor6.0.0GHSA-qjxf-mc72-wjr2
RubyGemsdevise-two-factorno fix listedGHSA-qjxf-mc72-wjr2

Affected products (as reported)

VendorProductVersions
devise-two-factor devise-two-factor 4.0.0 – before 6.0.01.0.0

Weakness: CWE-331 · Vector: CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:N/A:N

References