Eclipse Jetty: Early return from the JASPIAuthenticator code can potentially no clear ThreadLocal variables
Package
Affected versions
>= 12.1.0, <= 12.1.7
>= 12.0.0, <= 12.0.33
Patched versions
12.1.8
12.0.34
>= 12.1.0, <= 12.1.7
>= 12.0.0, <= 12.0.33
12.1.8
12.0.34
>= 12.1.0, <= 12.1.7
>= 12.0.0, <= 12.0.33
12.1.8
12.0.34
>= 12.1.0, <= 12.1.7
>= 12.0.0, <= 12.0.33
12.1.8
12.0.34
>= 11.0.0, <= 11.0.28
>= 10.0.0, <= 10.0.28
>= 9.4.0, <= 9.4.60
11.0.29
10.0.29
9.4.61
Description
Published to the GitHub Advisory Database
Apr 14, 2026
Reviewed
Apr 14, 2026
Last updated
Apr 14, 2026
Description (as reported)
A security vulnerability has been identified in Jetty's
JaspiAuthenticator.java.The root cause is a failure to consistently clear authentication metadata stored in
ThreadLocalduring certain error or incomplete authentication flows.Specifically, after a
GroupPrincipalCallbackis persisted into theThreadLocal, the authentication process may exit prematurely — before theThreadLocalstorage is cleared — if a mandatoryCallerPrincipalCallbackis missing or an exception occurs.This allows a subsequent, unprivileged user processed by the same worker thread to inherit these residual security roles, leading to Broken Access Control and Privilege Escalation.
See also attached PDF.
Impact
An unauthenticated user may gain ungrated privileges from a previous request (privilege escalation).
Patches
No patches yet.
Workarounds
Do not use Jetty's JASPI.
References