CVE-2025-4754

CVE-2025-4754 is a low-severity security vulnerability in ash_authentication_phoenix (erlang), affecting versions <= 2.9.0. It is fixed in 2.10.0.

Does this CVE actually affect you?

Kodem shows which CVEs are reachable and running in your applications, so you fix what's exploitable, not just what's listed.

Thank you! Your submission has been received!
Oops! Something went wrong while submitting the form.

Runtime intelligence, not another scanner.

Summary

ashauthenticationphoenix has Insufficient Session Expiration

Workarounds

You can manually revoke tokens in your logout/2 handler in your auth controller.

Impact

Session tokens remain valid on the server after user logout, creating a security gap where:

  • Compromised tokens (via XSS, network interception, or device theft) continue to work even after the user logs out
    • The sessions stored in the database still expire, limiting the duration during which this could be exploited
  • Users cannot fully invalidate their sessions when logging out from shared or potentially compromised devices
    • by default, changing one's password does invalidate all other sessions, so changing your password as a security measure would have been effective
  • May cause compliance issues with security frameworks requiring complete session

Affected versions

ash_authentication_phoenix (<= 2.9.0)

Security releases

ash_authentication_phoenix → 2.10.0 (erlang)

Kodem intelligence

Severity tells you how bad this could be in the worst case. It does not tell you whether you are exposed. Exploitability and impact are functions of runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A vulnerable package can sit in your dependency tree and never run.

Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter. Kodem's runtime-powered SCA identifies whether this CVE is reachable in your applications.

Already deployed Kodem?

See it in your environmentNew to Kodem? Get a demo →

Remediation advice

Upgrade to version 2.10.0. After upgrading, users must update their AuthController implementation to use the new clear_session/2 function with their OTP app name. You will be prompted to do so with a compile-time error.

If you do not have the setting require_token_presence_for_authentication? set to true in the tokens section, you will see a separate error:

** (Spark.Error.DslError) authentication -> session_identifier:
Must set `authentication.session_identifier` to either `:jti` or `:unsafe`.

...

In order to revoke sessions on log out when not storing tokens directly in the session, we must have some unique identifier with which to do so. You should prefer to enable require_token_presence_for_authentication? if possible, instead of setting this to :jti. Note that whatever you do here, if you did not previously have require_token_presence_for_authentication? set to true, setting it to true or setting authentication.session_identifier to :jti will log out all of your currently authenticated users.

Frequently Asked Questions

  1. What is CVE-2025-4754? CVE-2025-4754 is a low-severity security vulnerability in ash_authentication_phoenix (erlang), affecting versions <= 2.9.0. It is fixed in 2.10.0.
  2. Which versions of ash_authentication_phoenix are affected by CVE-2025-4754? ash_authentication_phoenix (erlang) versions <= 2.9.0 is affected.
  3. Is there a fix for CVE-2025-4754? Yes. CVE-2025-4754 is fixed in 2.10.0. Upgrade to this version or later.
  4. Is CVE-2025-4754 exploitable, and should I be worried? Whether CVE-2025-4754 is exploitable in your environment depends on whether the vulnerable code is present and reachable. A CVSS score is a worst-case rating; it does not account for your specific deployment, configuration, or usage patterns. Kodem, an Intelligent Application Security platform, uses runtime intelligence to show which vulnerabilities actually execute in production, so you can focus on the ones that represent real risk. Get a demo
  5. What actually determines whether CVE-2025-4754 is exploitable, and how bad it is? Exploitability and impact are not fixed properties of a CVE. They depend on runtime truth: whether the vulnerable code is present, reachable, and actually executes in your application. A high CVSS score on a dependency that never runs is not the same as real risk. Kodem, an Intelligent Application Security platform, uses runtime intelligence to reveal which vulnerabilities actually execute in production, so teams prioritize the ones that genuinely matter.
  6. How do I fix CVE-2025-4754? Upgrade ash_authentication_phoenix to 2.10.0 or later.

Stop the waste.
Protect your environment with Kodem.