Skip to content
OpenAdvisories
Medium · 5.3 CVE-2024-8796 EUVD-2024-2856GHSA-qjxf-mc72-wjr2

Insufficient Default OTP Shared Secret Length

Published Sep 17, 2024 · Updated Sep 20, 2024 · Assigned by SNPS

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 products

VendorProductAffectedFixed
devise-two-factor devise-two-factor 4.0.0 – < 6.0.0, 1.0.0 6.0.0

Fixed in Linux distributions

Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.

ReleasePackageFixed inAdvisory
Debian 12 ruby-devise-two-factor No fix yet —
ReleasePackageFixed inAdvisory
Ubuntu 16.04 LTS ruby-devise-two-factor No fix yet —
Show 2 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Ubuntu Pro 22.04 LTS ruby-devise-two-factor 4.0.0-2ubuntu0.1~esm1 USN-7050-1
Ubuntu Pro 20.04 LTS ruby-devise-two-factor 3.1.0-2ubuntu0.1~esm1 USN-7050-1

Affected packages

EcosystemPackageAffectedFixedRecord
RubyGems devise-two-factor >= 4.0.0, < 6.0.0 6.0.0 GHSA-qjxf-mc72-wjr2
RubyGems devise-two-factor 1.0.0 — GHSA-qjxf-mc72-wjr2

Advisories 1

References