CVE-2015-7225: Devise two factor Tinfoil Devise-two-factor Does Not "burn" Vulnerability

MODERATE
Advisory Identifier: GHSA-x489-jjwm-52g7
CVSS 5.3
Published
Advisory Summary

CVE-2015-7225 is a MODERATE (CVSS 5.3) tinfoil devise-two-factor does not "burn" vulnerability (General Security Weakness) affecting Devise two factor libraries in the RubyGems ecosystem. The issue involves tinfoil devise-two-factor does not "burn" a successfully validated one-time password (otp). Remediation is available by upgrading affected packages to version 2.0.0.

CVE-2015-7225 at a Glance

CVE Identifier CVE-2015-7225
GHSA Identifier GHSA-x489-jjwm-52g7
Severity MODERATE
CVSS v3.1 Base Score 5.3
CWE Classification General Security Weakness
Affected Product Devise two factor
Package Ecosystem RubyGems
Published Date
Last Updated

Security Impact

CVSS: 5.3

The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.0/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:N/A:N).

Attack Vector Network (AV:N)
Attack Complexity High (AC:H)
Privileges Required Low (PR:L)
User Interaction None (UI:N)
Scope Unchanged (S:U)
Confidentiality High (C:H)
Integrity None (I:N)
Availability None (A:N)

How to Fix CVE-2015-7225

To remediate this vulnerability, upgrade all affected Devise two factor dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.

devise-two-factor fixed: 2.0.0
Upgrade devise-two-factor to 2.0.0
Verify Direct and Transitive Dependencies

Run the following command in your project directory to verify that all resolved dependencies use the patched release:

inspect dependencies for devise-two-factor

How to Check if You Are Affected

To determine whether your application is affected by CVE-2015-7225, inspect your project dependencies for Devise two factor:

inspect dependencies for devise-two-factor

Analyze the terminal output to locate any version of Devise two factor in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.0.0), your application is affected.

Note: Verify declared build manifests and deployed runtime container environments.

Technical Details

Vulnerability Mechanism & Technical Analysis

This vulnerability is classified under General Security Weakness. In Devise two factor, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.

Source Advisory Statement

Tinfoil Devise-two-factor before 2.0.0 does not strictly follow [RFC 6238 § 5.2 ](https://datatracker.ietf.org/doc/html/rfc6238#section-5.2) and does not "burn" a successfully validated one-time password (aka OTP), which allows physically proximate attackers with a target user's login credentials to log in as said user by obtaining the OTP through performing a man-in-the-middle attack between the provider and verifier, or "shoulder surfing", and replaying the OTP in the current time-step.

CVE-2015-7225 Affected Devise two factor Versions

1 component(s)
Fixed Versions:
2.0.0
Product / Package Ecosystem Affected Versions Fixed Version
devise-two-factor
RubyGems
< 2.0.0
2.0.0

References

Frequently Asked Questions

What is CVE-2015-7225?
CVE-2015-7225 is a security vulnerability in Devise two factor involving Tinfoil Devise-two-factor does not "burn" a successfully validated one-time password (OTP) under General Security Weakness.
Which Devise two factor versions are affected?
Affected versions include releases prior to 2.0.0 across affected packages: devise-two-factor.
What version fixes CVE-2015-7225?
Upgrading to 2.0.0 (or the latest patched release for your respective branch) resolves the vulnerability.
Is devise-two-factor affected?
Yes, devise-two-factor is affected in releases prior to 2.0.0. Upgrade your dependency to 2.0.0 or later.
What is the CVSS score of CVE-2015-7225?
CVE-2015-7225 has a CVSS v3.1 base score of 5.3 (MODERATE) with vector string CVSS:3.0/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:N/A:N.
What CWE is associated with CVE-2015-7225?
CVE-2015-7225 is classified under General Security Weakness.
How can I check RubyGems dependencies for CVE-2015-7225?
Run the dependency tree command: 'inspect dependencies for devise-two-factor'. This command lists direct and transitive dependencies in your build configuration so you can verify if a vulnerable version is resolved.
Machine-readable OSV JSON OSV v1.5 Schema
Normalized schema output
{
  "schema_version" : "1.4.0",
  "id" : "GHSA-x489-jjwm-52g7",
  "modified" : "2023-07-05T20:45:12Z",
  "published" : "2018-08-28T22:34:15Z",
  "aliases" : [ "CVE-2015-7225" ],
  "summary" : "Tinfoil Devise-two-factor does not \"burn\" a successfully validated one-time password (OTP)",
  "details" : "Tinfoil Devise-two-factor before 2.0.0 does not strictly follow [RFC 6238 § 5.2 ](https://datatracker.ietf.org/doc/html/rfc6238#section-5.2) and does not \"burn\" a successfully validated one-time password (aka OTP), which allows physically proximate attackers with a target user's login credentials to log in as said user by obtaining the OTP through performing a man-in-the-middle attack between the provider and verifier, or \"shoulder surfing\", and replaying the OTP in the current time-step.",
  "severity" : [ {
    "type" : "CVSS_V3",
    "score" : "CVSS:3.0/AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:N/A:N"
  } ],
  "affected" : [ {
    "package" : {
      "ecosystem" : "RubyGems",
      "name" : "devise-two-factor"
    },
    "ranges" : [ {
      "type" : "ECOSYSTEM",
      "events" : [ {
        "introduced" : "0"
      }, {
        "fixed" : "2.0.0"
      } ]
    } ]
  } ],
  "references" : [ {
    "type" : "ADVISORY",
    "url" : "https://nvd.nist.gov/vuln/detail/CVE-2015-7225"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/tinfoil/devise-two-factor/issues/45#issuecomment-139335608"
  }, {
    "type" : "WEB",
    "url" : "https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=798466"
  }, {
    "type" : "ADVISORY",
    "url" : "https://github.com/advisories/GHSA-x489-jjwm-52g7"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/rubysec/ruby-advisory-db/blob/master/gems/devise-two-factor/CVE-2015-7225.yml"
  }, {
    "type" : "PACKAGE",
    "url" : "https://github.com/tinfoil/devise-two-factor"
  }, {
    "type" : "WEB",
    "url" : "https://github.com/tinfoil/devise-two-factor/blob/master/UPGRADING.md"
  }, {
    "type" : "WEB",
    "url" : "https://web.archive.org/web/20210122192452/https://www.securityfocus.com/bid/76789"
  }, {
    "type" : "WEB",
    "url" : "http://www.openwall.com/lists/oss-security/2015/06/20/4"
  }, {
    "type" : "WEB",
    "url" : "http://www.openwall.com/lists/oss-security/2015/09/06/2"
  }, {
    "type" : "WEB",
    "url" : "http://www.openwall.com/lists/oss-security/2015/09/17/2"
  } ],
  "database_specific" : {
    "cwe_ids" : [ ],
    "severity" : "MODERATE",
    "github_reviewed" : true,
    "github_reviewed_at" : "2020-06-16T22:02:02Z",
    "nvd_published_at" : null
  }
}