Commit 0e1cbea6 authored by Matija Obreza's avatar Matija Obreza

FIX: Cached authorization code must be evicted

parent 4991351e
......@@ -56,7 +56,9 @@ public class CachedInMemoryAuthorizationCodeServices extends RandomValueAuthoriz
@Override
protected OAuth2Authentication remove(String code) {
return authorizationCodeCache.get(code, OAuth2Authentication.class);
OAuth2Authentication result = authorizationCodeCache.get(code, OAuth2Authentication.class);
authorizationCodeCache.evict(code);
return result;
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment