Skip to main content

CVE-2026-32700 — Vulnerability in devise — CVE Details

MEDIUM

Devise has a confirmable "change email" race condition permits user to confirm email they have no access to

Published March 17, 2026Updated March 30, 2026Source: OSV

What Should I Do?

Address in Next Maintenance Window

Low exploitation probability (0.38%). Schedule for your next planned update.

Does your project use an affected devise version?

Paste your Gemfile.lock to check it for CVE-2026-32700 and every other known vulnerability, with CISA KEV and EPSS on each finding. Free with no signup for up to 10 packages, or up to 500 per scan with a free account, which also keeps up to 200 packages in saved projects.

Check my Gemfile.lock

Summary

Impact

A race condition in Devise's Confirmable module allows an attacker to confirm an email address they do not own. This affects any Devise application using the reconfirmable option (the default when using Confirmable with email changes).

By sending two concurrent email change requests, an attacker can desynchronize the confirmation_token and unconfirmed_email fields. The confirmation token is sent to an email the attacker controls, but the unconfirmed_email in the database points to a victim's email address. When the attacker uses the token, the victim's email is confirmed on the attacker's account.

Patches

This is patched in Devise v5.0.3. Users should upgrade as soon as possible.

Workarounds

Applications can override this specific method from Devise models to force unconfirmed_email to be persisted when unchanged: (assuming your model is User)

class User < ApplicationRecord
  protected

  def postpone_email_change_until_confirmation_and_regenerate_confirmation_token
    unconfirmed_email_will_change!
    super
  end
end

Note: Mongoid does not seem to respect that will_change! should force the attribute to be persisted, even if it did not really change, so you might have to implement a workaround similar to Devise by setting changed_attributes["unconfirmed_email"] = nil as well.

Advisory Timeline

  • First published March 17, 2026 (254 days ago).
  • Last revised March 30, 2026 — 13 days after initial publication.

Remediation

Upgrade to the fixed version using your package manager.

Bundler
Update devise to 5.0.3 or later
gem install devise -v 5.0.3

After upgrading, scan your dependencies again to confirm the vulnerability is resolved.

Affected Packages (1)

Affects 1 ecosystem: RubyGems (1).

PackageFixed In
devise RubyGems · Affected: 0.1.0, 0.1.1, 0.2.0, 0.2.1 (+167 more)5.0.3

Vulnerability Classification

Common Weakness Enumeration (CWE) identifiers for this vulnerability type.

CVSS Score Breakdown

What the CVSS (Common Vulnerability Scoring System) 5.3 score means for each attack dimension.

Attack Vector
Network
Attack Complexity
High
Privileges Required
Low
User Interaction
None
Scope
Unchanged
Confidentiality
None
Integrity
High
Availability
None

CVSS:3.1/AV:N/AC:H/PR:L/UI:N/S:U/C:N/I:H/A:N

Frequently Asked Questions

What is CVE-2026-32700?
Devise has a confirmable "change email" race condition permits user to confirm email they have no access to. This vulnerability has been assigned a severity rating of MEDIUM (CVSS score: 5.3/10).
How do I check if my project is affected by CVE-2026-32700?
CVE-2026-32700 affects devise. It has a 0.4% probability of exploitation within 30 days (EPSS score). Use GeekWala's free vulnerability scanner to check your dependencies against CVE-2026-32700 and 200,000+ other known vulnerabilities.

Severity & Exploitability

CVSS Score
5.3

Exploitation requires specific conditions, or the impact is limited.

EPSS Score (30-day exploit probability)
0.38%
EPSS percentile: 24.1

This is a below-median EPSS score — only 24.1% of tracked vulnerabilities score at or below it, so most tracked vulnerabilities are considered more likely to be exploited than this one.

Also Known As

GHSA-57hq-95w6-v4fc

Related CVEs

  • CVE-2015-8314
    HIGH

    Devise Gem for Ruby Unauthorized Access Using "Remember Me" Cookie

  • CVE-2026-128084
    MEDIUM

    sqlite3-ruby: Possible SQL query truncation when a string is 4 GiB or larger

  • CVE-2026-115472
    MEDIUM

    Doorkeeper: When using public clients, any client can revoke any access token

  • CVE-2026-40295
    MEDIUM

    Devise has an Open Redirect via Unvalidated `request.referrer` in Timeoutable Session Timeout Handler

Check your own dependencies

Free, with no signup for up to 10 packages.

Check my Gemfile.lock