CVE-2024-25618
What it is
Mastodon is a free, open-source social network server based on ActivityPub. Mastodon allows new identities from configured authentication providers (CAS, SAML, OIDC) to attach to existing local users with the same e-mail address. This results in a possible account takeover if the authentication provider allows changing the e-mail address or multiple authentication providers are configured. When a user logs in through an external authentication provider for the first time, Mastodon checks the e-mail address passed by the provider to find an existing account. However, using the e-mail address alone means that if the authentication provider allows changing the e-mail address of an account, the Mastodon account can immediately be hijacked. All users logging in through external authentication providers are affected. The severity is medium, as it also requires the external authentication provider to misbehave. However, some well-known OIDC providers (like Microsoft Azure) make it very easy to accidentally allow unverified e-mail changes. Moreover, OpenID Connect also allows dynamic client registration. This issue has been addressed in versions 4.2.6, 4.1.14, 4.0.14, and 3.5.18. Users are advised to upgrade. There are no known workarounds for this vulnerability.
At a glance
- Exploitability
- Can be exploited over the network without logging in, but needs a user to act. Limited direct impact.
- Exploit odds
- 0.5% chance of exploitation in the next 30 days (EPSS).
- Fix
- A patch, advisory or fixed version is referenced. Upgrade or apply it.
Timeline
- PublishedDisclosed publicly on CVE.org and NVD
- Last updatedMost recent change to the record
Why it ranks here
- Exploited in the wild: no, CISA does not list it.
- Exploit odds: 0.5% in the next 30 days (EPSS).
- Severity: 4.2 MEDIUM (CVSS).
- Fix: a patch or advisory is linked.
Details
- Published
- Last modified
- Exploit probability
- 0.5% · EPSS, next 30 days
- Weakness
- CWE-287 · Improper authentication
- Record status
- Analyzed
Affected
- Joinmastodon Mastodon < 3.5.18
- Joinmastodon Mastodon < 4.0.14
- Joinmastodon Mastodon < 4.1.14
- Joinmastodon Mastodon < 4.2.6
Attack profile CVSS 3.1 · 4.2
- Attack vector
- Network
- Complexity
- High
- Privileges needed
- None
- User interaction
- Required
- Scope
- Unchanged
- Confidentiality
- Low
- Integrity
- Low
- Availability
- None
Raw vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:R/S:U/C:L/I:L/A:N
Is it in your code?
Hand this to your coding agent. It searches your project for the affected products and checks versions. Nothing leaves your machine.
Read https://cve-list.com/agent/cve/CVE-2024-25618.md and follow it. Check whether this project is affected by CVE-2024-25618. Read only. Don't change anything and don't upload my code. Tell me yes, no or not sure, with the file as proof.
Fix and advisories
- https://github.com/mastodon/mastodon/commit/b31af34c9716338e4a32a62cc812d1ca59e88d15
- https://github.com/mastodon/mastodon/security/advisories/GHSA-vm39-j3vx-pch3
- https://github.com/mastodon/mastodon/commit/b31af34c9716338e4a32a62cc812d1ca59e88d15
- https://github.com/mastodon/mastodon/security/advisories/GHSA-vm39-j3vx-pch3
References
- https://github.com/mastodon/mastodon/commit/b31af34c9716338e4a32a62cc812d1ca59e88d15
- https://github.com/mastodon/mastodon/security/advisories/GHSA-vm39-j3vx-pch3
- https://github.com/mastodon/mastodon/commit/b31af34c9716338e4a32a62cc812d1ca59e88d15
- https://github.com/mastodon/mastodon/security/advisories/GHSA-vm39-j3vx-pch3