public final class DefaultAuthorizationProvider extends Object implements AuthorizationProvider
AuthorizationProvider
that will read an xml definition associating targets and operations with
GrantedAuthoritys and will use this to check whether the current user
has the authorization to invoke a given operation on a given target. The file
must conform to the Authorization.xsd schema.| Constructor and Description |
|---|
DefaultAuthorizationProvider()
Create new DefaultAuthorizationProvider with no definitions
|
DefaultAuthorizationProvider(String xmlFileName)
Create new DefaultAuthorizationProvider
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
isAuthorized(org.springframework.security.core.Authentication authentication,
String target,
String operation)
Query whether the given user is authorized to invoke the given operation
on the given taget
|
public DefaultAuthorizationProvider()
public DefaultAuthorizationProvider(String xmlFileName)
xmlFileName - The name of the xml filepublic boolean isAuthorized(org.springframework.security.core.Authentication authentication,
String target,
String operation)
AuthorizationProviderisAuthorized in interface AuthorizationProviderauthentication - The usertarget - The target (IDL name or class name)operation - The method nametrue if the authentication is authorized.Copyright © 2019 ADDC Infotech GmbH. All rights reserved.