@Provider @Priority(value=1000) public abstract class AuthenticationFilter extends Object implements javax.ws.rs.container.ContainerRequestFilter
AuthenticationFilter.| Constructor and Description |
|---|
AuthenticationFilter() |
| Modifier and Type | Method and Description |
|---|---|
void |
filter(javax.ws.rs.container.ContainerRequestContext requestContext) |
protected boolean |
isSecured()
Checks if is the resourceClass is annotated with the annotation
Securable. |
protected boolean |
isSigninPath(String path)
Checks if the given path is a sign in path.
|
protected boolean |
isSigninRequest(javax.ws.rs.container.ContainerRequestContext requestContext)
Checks if the current request is a is a sign request.
|
protected Response |
newFaultResponse()
Factory callback method for create a new
Response. |
protected String |
newRealmValue()
Factory callback method for create a new realm value for the header key
'WWW-Authenticate'.
|
protected SecurityContext |
newSecurityContext(String username)
Factory method for create a new security context with the given user
name.
|
protected abstract String |
onValidateToken(String token)
Abstract callback method that checks if the given token is valid.
|
public void filter(javax.ws.rs.container.ContainerRequestContext requestContext) throws IOException
filter in interface javax.ws.rs.container.ContainerRequestFilterIOExceptionprotected boolean isSigninRequest(javax.ws.rs.container.ContainerRequestContext requestContext) throws Exception
requestContext - the request contextException - occurs if some error like the scheme is not httpsprotected boolean isSigninPath(String path)
path - the sign in path to check.protected boolean isSecured()
Securable.Securable.protected abstract String onValidateToken(String token) throws Exception
token - the tokenException - if the token is not validprotected Response newFaultResponse()
Response.protected String newRealmValue()
protected SecurityContext newSecurityContext(String username)
username - the user nameCopyright © 2015–2017 Alpha Ro Group UG (haftungsbeschrÀngt). All rights reserved.