Read the docs
TI-2024-08162 Aliases CVE-2024-8796GHSA-qjxf-mc72-wjr2

Insufficient Default OTP Shared Secret Length

Priority LOW 28CWE-331Published · Updated

Key facts

Attack vector
Network
Privileges required
Low
User interaction
None
Attack complexity
High
Attack requirements
Present
Impact type
—
Confidentiality · integrity · availability
High · None · None
Fix status
Fixed

Attack profile from CVSS 4.0 · CNA. Fix status from CNA and GitHub.

Summary

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.

Why it matters now

Exploitation None reported CISA SSVC · not in CISA KEV
EPSS 0.00641 50th percentileScored 2026-11-07
Fix Fixed devise-two-factor (devise-two-factor): 6.0.0devise-two-factor (RubyGems): 6.0.0

SSVC decision points

CISA ADP · SSVC 2.0.3

Exploitation
None
Automatable
No
Technical impact
Partial

The decision (Track, Attend, Act) also depends on your mission and well-being impact; see CISA's SSVC guide.

Affected products

VendorProductAffected versionsFixed inStatusSource
devise-two-factordevise-two-factor4.0.0 to before 6.0.0; 1.0.06.0.0Patch availableCNA
—devise-two-factor (RubyGems)4.0.0 to before 6.0.06.0.0Patch availableGHSA-qjxf-mc72-wjr2
—devise-two-factor (RubyGems)——No fix listedGHSA-qjxf-mc72-wjr2
  • devise-two-factor Vendordevise-two-factor Affected 4.0.0 to before 6.0.0; 1.0.0 Fixed in 6.0.0 Patch available CNA
  • devise-two-factor (RubyGems) Vendor— Affected 4.0.0 to before 6.0.0 Fixed in 6.0.0 Patch available GHSA-qjxf-mc72-wjr2
  • devise-two-factor (RubyGems) Vendor— Affected — Fixed in — No fix listed GHSA-qjxf-mc72-wjr2

CPE configurations NVD · 2

CPEVersionsRoleVendor
cpe:2.3:a:tinfoilsecurity:devise-two-factor:*:*:*:*:*:*:*:*4.0.0 to before 6.0.0VulnerableTinfoilsecurity
cpe:2.3:a:tinfoilsecurity:devise-two-factor:1.0.0:*:*:*:*:*:*:*1.0.0VulnerableTinfoilsecurity
  • cpe:2.3:a:tinfoilsecurity:devise-two-factor:*:*:*:*:*:*:*:* Versions 4.0.0 to before 6.0.0 Vulnerable ·Tinfoilsecurity
  • cpe:2.3:a:tinfoilsecurity:devise-two-factor:1.0.0:*:*:*:*:*:*:* Versions 1.0.0 Vulnerable ·Tinfoilsecurity

Remediation

  • Fix · CNA devise-two-factor (devise-two-factor) Fixed in 6.0.0
  • Fix · GHSA-qjxf-mc72-wjr2 devise-two-factor (RubyGems) Fixed in 6.0.0 Advisory →

Timeline

  1. 2026-10-02 Threatist record created from CVE-2024-8796
  2. 2026-10-03 Alias added: GHSA-qjxf-mc72-wjr2
  3. 2026-10-21 EPSS moved to the 50th–90th percentile

References

  • TI-2015-05998 Tinfoil Devise-two-factor before 2.0.0 does not strictly follow section 5.2 of RFC 6238… CVSS 3.0MEDIUM 5.3
  • TI-2021-19191 As a result of an incomplete fix for CVE-2015-7225, in versions of devise-two-factor… CVSS 3.1MEDIUM 5.3

Sources