Commit e771607f authored by Jens Ehlers's avatar Jens Ehlers
Browse files

minor fix in REST API

parent bab90557
Pipeline #9927 passed with stage
in 1 minute and 21 seconds
......@@ -38,6 +38,7 @@ public class AuthenticationFilter implements ContainerRequestFilter {
String authHeader = request.getHeaders().getFirst(HttpHeaders.AUTHORIZATION);
if (authHeader == null || !authHeader.startsWith(TOKEN_TYPE + " ")) {
request.abortWith(Response.status(401).entity("JWT not found in HTTP header").build());
return;
}
// extract the token from the HTTP authorization header
String jwt = authHeader.substring(TOKEN_TYPE.length()).trim();
......
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