@Singleton
public class RolesFromServiceFilter
extends org.eurekaclinical.standardapis.filter.AbstractRolesFilter
AuthorizingEurekaClinicalClient in
their Guice configuration. It accepts an init parameter,
protectedPath, which takes a path corresponding to the part of
the web application that requires authentication. The filter will ignore
HTTP status codes under 500 when trying to get the user's role list if the
requested path does not start with the application's protected path.| Constructor and Description |
|---|
RolesFromServiceFilter(com.google.inject.Injector inInjector) |
| Modifier and Type | Method and Description |
|---|---|
protected String[] |
getRoles(Principal inPrincipal,
javax.servlet.ServletRequest inRequest)
Gets the user's roles from the service that maintains the user's role
information.
|
void |
init(javax.servlet.FilterConfig fc)
Does nothing.
|
@Inject public RolesFromServiceFilter(com.google.inject.Injector inInjector)
public void init(javax.servlet.FilterConfig fc)
init in interface javax.servlet.Filterinit in class org.eurekaclinical.standardapis.filter.AbstractRolesFilterfc - the filter configuration.protected String[] getRoles(Principal inPrincipal, javax.servlet.ServletRequest inRequest) throws javax.servlet.ServletException
getRoles in class org.eurekaclinical.standardapis.filter.AbstractRolesFilterinPrincipal - the user principal.inRequest - the request.javax.servlet.ServletException - if the service responded with a 500 status,
the protectedPath init parameter was not given or is
null, or the requested servlet path starts with the
protected path.Copyright © 2016–2018 Emory University. All rights reserved.