Closed blootsvoets closed 6 years ago
In the OAuth2 spec, it states the following example for an error:
HTTP/1.1 401 Unauthorized WWW-Authenticate: Bearer realm="example", error="invalid_token", error_description="The access token expired"
It would then not send a body. I would opt for using this technique rather than sending a JSON body back in AuthenticationFilter.
AuthenticationFilter
The next paragraph is also relevant:
insufficient_scope
WWW-Authenticate
In the OAuth2 spec, it states the following example for an error:
It would then not send a body. I would opt for using this technique rather than sending a JSON body back in
AuthenticationFilter
.