|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objecteu.emi.dsr.security.util.AttributeSourcesChain
public class AttributeSourcesChain
IAttributeSource implementation that combines the results from a chain of attribute sources using a configurable combining policy:
| Nested Class Summary | |
|---|---|
static interface |
AttributeSourcesChain.CombiningPolicy
defines how attributes should be combined |
static class |
AttributeSourcesChain.FirstAccessible
first accessible: the answer from the first accessible attribute source is used. |
static class |
AttributeSourcesChain.FirstApplicable
first applicable: only the first not empty map of attributes is used |
static class |
AttributeSourcesChain.Merge
Merge: attributes with the same key are combined (values are added). |
static class |
AttributeSourcesChain.MergeLastOverrides
merge_last_overrides: new attributes overwrite existing ones |
| Field Summary |
|---|
| Fields inherited from interface eu.emi.dsr.security.IAttributeSource |
|---|
ATTRIBUTE_ADD_DEFAULT_GROUPS, ATTRIBUTE_GROUP, ATTRIBUTE_ROLE, ATTRIBUTE_SUPPLEMENTARY_GROUPS, ATTRIBUTE_VOS, ROLE_ADMIN, ROLE_ANONYMOUS |
| Constructor Summary | |
|---|---|
AttributeSourcesChain()
|
|
| Method Summary | |
|---|---|
String[] |
getAcceptedVOs()
This method returns the list of VOs that this attribute source supports. |
SubjectAttributesHolder |
getAttributes(SecurityTokens tokens,
SubjectAttributesHolder unused)
combines results from all configured attribute sources |
List<IAttributeSource> |
getChain()
|
AttributeSourcesChain.CombiningPolicy |
getCombiningPolicy()
|
String |
getName()
This method should return name of this attribute source, which was passed to the init() method. |
String |
getStatusDescription()
Get a user-friendly description of the attribute source's status. This is used for informing the administrator of any problems with configuration, connection problems, etc. |
void |
init(String name)
will initialise all the authorisers in the chain by calling their init() method |
void |
setCombiningPolicy(String name)
|
void |
setOrder(String order)
|
void |
setProperties(Properties p)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AttributeSourcesChain()
| Method Detail |
|---|
public void init(String name)
throws Exception
init in interface IAttributeSourceException
public SubjectAttributesHolder getAttributes(SecurityTokens tokens,
SubjectAttributesHolder unused)
throws IOException,
AuthorisationException
getAttributes in interface IAttributeSourcetokens - - security tokens for this requestunused - - attributes returned by other authorisers, which may be null
IOException - in case of technical problems
AuthorisationExceptionpublic String getStatusDescription()
IAttributeSourceTimeoutRunner class to avoid blocking.
getStatusDescription in interface IAttributeSourcepublic List<IAttributeSource> getChain()
public AttributeSourcesChain.CombiningPolicy getCombiningPolicy()
public void setProperties(Properties p)
public void setOrder(String order)
public void setCombiningPolicy(String name)
public String getName()
IAttributeSource
getName in interface IAttributeSourcepublic String[] getAcceptedVOs()
IAttributeSource
getAcceptedVOs in interface IAttributeSource
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||