7.7high
In Forgejo before 15.0.12 and 16.x and 17.x before 17.0.2, emailverified can be spoofed, sometimes leading to account takeover in external…
- Severity
- 7.7high CVSS:3.1 by mitre
- Exploit likelihood
- 0.59% (higher than 49% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- mitre
Description
In Forgejo before 15.0.12 and 16.x and 17.x before 17.0.2, email_verified can be spoofed, sometimes leading to account takeover in external services that rely on Forgejo for authentication. It allows an authenticated user to set an unverified secondary email address as their primary email address when [service] REGISTER_EMAIL_CONFIRM is enabled. Although the web UI hides the "Make primary" button for unverified addresses, the backend POST /user/settings/account/email handler (EmailPost in routers/web/user/setting/account.go) and MakeEmailAddressPrimary in services/user/email.go did not check whether the email address was activated. Because Forgejo's OpenID Connect (OIDC) provider derives the email_verified claim from user.IsActive rather than the primary email address's activation state, an attacker can obtain signed ID tokens asserting email_verified: true for an arbitrary unverified email address, and potentially take over accounts on external relying parties that match users by verified email.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| Forgejo Forgejo | from 9.0.0 before 15.0.12, from 16.0.0 before 17.0.2 | CVE List |
Classification
References
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2026-138408 changed 2026-11-29 | CVE Terms of Use |