Skip to content

Instantly share code, notes, and snippets.

@murraco
Created Nov 11, 2017
Embed
What would you like to do?
String token = jwtTokenProvider.resolveToken((HttpServletRequest) req);
if (token != null && jwtTokenProvider.validateToken(token)) {
Authentication auth = jwtTokenProvider.getAuthentication(token);
SecurityContextHolder.getContext().setAuthentication(auth);
}
filterChain.doFilter(req, res);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment