cve.bz

CVE-2026-82761 Magic link single-use tokens replayable via TOCTOU race in AshAuthentication

9.1 criticalEPSS 0.6%Fix available

Critical (9.1) in team-alembic ash authentication. EPSS 0.6% estimated probability of exploitation activity in the next 30 days. Fixed in ash_authentication 4.15.0, 5.0.0-rc.14.

On this page
Time-of-check Time-of-use (TOCTOU) Race Condition vulnerability in team-alembic AshAuthentication allows an attacker holding a leaked magic link to replay its single-use token and authenticate as the target subject. A magic link configured with single_use_token?, which is the default, is meant to be redeemable exactly once, but nothing serialises the token's validity check against its consumption, so concurrent redemptions of one token all succeed and each yields a full user token. Sign-in verifies the JWT with Jwt.verify/4 and revokes it only afterwards: AshAuthentication.Strategy.MagicLink.SignInPreparation revokes in a Query.after_action callback, and AshAuthentication.Strategy.MagicLink.SignInChange in an after_transaction hook that runs once the sign-in has already committed. AshAuthentication.TokenResource.Actions.revoke/3 writes the revocation as an upsert, so a concurrent duplicate revocation silently succeeds instead of conflicting and no request ever loses the race. This issue affects ash_authentication: from 3.9.0 before 4.15.0 and from 5.0.0-rc.0 before 5.0.0-rc.14.

Severity

CVSS 4.0

9.1 critical
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:H/VI:H/VA:N/SC:N/SI:N/SA:N
EPSS
0.6% (unchanged from 0.6% a week ago; 0.6% 30 days ago) estimated probability of exploitation activity in the next 30 days; 47th percentile. Scored 2026-11-22. A forecast for this CVE across the internet, not for your own systems.
CISA's assessment (SSVC)
Exploitation: none · Automatable: yes · Technical impact: total, assessed 2026-09-17. From CISA's Vulnrichment in the CVE List: whether it is exploited, whether exploiting it can be automated, and how much control it gives.
CWE
CWE-367 Time-of-check Time-of-use (TOCTOU) Race Condition
Published
Modified
Assigned by
EEF (CNA)
NVD analysis
Deferred: the NVD does not plan to analyze it
Record from
the NVD, synced

Fix and patched versions

  • ash_authentication (Hex): fixed in 4.15.0, 5.0.0-rc.14

Ask an AI about this CVE

Show the promptExplain CVE-2026-82761 for an engineer deciding whether to act. Use https://cve.bz/api/public/cves/CVE-2026-82761?via=ask-ai-copy and https://cve.bz/cve/CVE-2026-82761?via=ask-ai-copy as the source of truth: what is affected and which versions fix it, whether it is in CISA KEV, public exploits, and its EPSS (an internet-wide 30-day estimate of exploitation activity, not a forecast for my systems). If they give no fixed versions, use the CVE record https://cveawg.mitre.org/api/cve/CVE-2026-82761 or the vendor advisory, not third-party mirrors. Tell me how to check whether I am affected and how to verify a fix. Cite the sources and say where they are uncertain.

Opens a third-party assistant; its answer is its own, not cve.bz's. The prompt holds only this CVE's id and public links.

Affected

Versions

From the CNA's record in the CVE List.

ProductAffected
team-alembic ash_authenticationfrom 3.9.0 before 4.15.0
team-alembic ash_authenticationfrom 5.0.0-rc.0 before 5.0.0-rc.14

Packages (OSV)

AdvisoryEcosystemPackageAffectedFixed in
EEF-CVE-2026-82761Hexash_authentication>=3.9.0 <4.15.0
>=5.0.0-rc.0 <5.0.0-rc.14
4.15.0, 5.0.0-rc.14
EEF-CVE-2026-82761v4.14.2, v5.0.0-rc.13, v4.14.1, v5.0.0-rc.12, v5.0.0-rc.11 and 134 moreno fix published

Attack patterns (CAPEC)

  • CAPEC-27 Leveraging Race Conditions via Symbolic Links Likelihood: Medium · Severity: High
  • CAPEC-29 Leveraging Time-of-Check and Time-of-Use (TOCTOU) Race Conditions Likelihood: High · Severity: High

The attack patterns MITRE's CAPEC relates to this record's weaknesses, as MITRE names them. Credits.

References

Check your stackJSON