public interface IAccessPolicy
extends com.webmethods.portal.bizPolicy.biz.IBizPolicy
Policy to modify Portal Access information. This includes IAce
,
and other information.
IAccessPolicy functions expose setting (updating) and removing IAce
s,
as well as altering Anonymous, AuthScheme and capability information as well on Portal resources. (IThing
s).
Modifier and Type | Method and Description |
---|---|
int |
getAccess(IContext context,
IThingID itemID,
IURI userID)
Returns access rights that user has for the given thing.
|
Collection |
getAccessEx(IContext context,
IThingID itemID,
IURI userID)
Returns access rights that user has for the given thing.
|
IListView |
getAclView(IContext context,
IThingID itemID)
Returns list of access control entries for this item
|
String |
getAuthScheme(IContext context,
IThingID itemId)
Queries the authLevel of the resource.
|
IListView |
getRightsForType(IContext context,
String xtypeName)
Returns list view of all rights registered with the given xtype/basic type
|
IThingID |
getSecurityRealm(IContext context,
IThingID itemID)
Retrieves and returns security policy associated with the item
|
boolean |
isAnonymous(IContext context,
IThingID itemId)
Verifies whether specified resource is anonymous.
|
IListView |
listSecurityRealmObjects(IContext context,
IThingID securityRealmID)
Returns list view of all objects assigned this security realm.
|
IListView |
listSecurityReamObjects(IContext context,
IThingID securityRealmID)
Deprecated.
use
listSecurityRealmObjects(IContext, IThingID) instead |
void |
removeAces(IContext context,
IThingID itemId,
List principalIds,
boolean recursive)
Removes the access entries of the specified item.
|
void |
removeSecurityRealm(IContext context,
IThingID itemID,
IThingID securityRealmID,
boolean recursive)
Removes security policy from the object
|
void |
setAces(IContext context,
IThingID itemId,
List principalIds,
boolean recursive,
int grant,
int deny,
int exclusive,
int delegate,
int mask)
Sets the access entries of the specified item.
|
void |
setAcesEx(IContext context,
IThingID itemId,
List principalIds,
boolean recursive,
Collection granted,
Collection denied,
Collection exclusive)
Sets the access for the specified item.
|
void |
setAnonymous(IContext context,
IThingID itemId,
boolean recursive,
boolean isAnonymous)
Set specified resource either as anonymous.
|
void |
setAuthScheme(IContext context,
IThingID itemId,
boolean recursive,
String authLevel)
Sets the authentication level of this thing
|
void |
setSecurityRealm(IContext context,
IThingID itemID,
IThingID securityRealmID,
boolean recursive)
Sets security policy to the object
|
void setAces(IContext context, IThingID itemId, List principalIds, boolean recursive, int grant, int deny, int exclusive, int delegate, int mask) throws com.webmethods.portal.bizPolicy.BizException
context
- Command context (user state information).itemId
- Item whose access entries to set.principalIds
- List of IURI
s for which to add or modify access.recursive
- True if the access modification should be applied to this item's descendants.grant
- Bit set of rights to grant.deny
- Bit set of rights to deny.exclusive
- Bit set of rights to grant exclusively.delegate
- Bit set of rights that may be delegated.mask
- Bit set of rights to modify. When adding or modifying a particular right set
(like grant or deny) only the intersection of this and the particular right set apply.com.webmethods.portal.bizPolicy.BizException
- TODO: delegate and mask are unused and should be deprected/removed.void setAcesEx(IContext context, IThingID itemId, List principalIds, boolean recursive, Collection granted, Collection denied, Collection exclusive) throws com.webmethods.portal.bizPolicy.BizException
context
- current contextitemId
- item to set aces onprincipalIds
- principals listrecursive
- whether set aces recursivegranted
- list of granted rights. This is a list of String names of rights or Integer right valuesdenied
- list of denied rights. This is a list of String names of rights or Integer right valuesexclusive
- list of denied rights. This is a list of String names of rights or Integer right valuescom.webmethods.portal.bizPolicy.BizException
int getAccess(IContext context, IThingID itemID, IURI userID) throws com.webmethods.portal.bizPolicy.BizException
context
- Command contextitemID
- item whose access should be retrieveduserID
- user whose access shouild be retrievedcom.webmethods.portal.bizPolicy.BizException
IListView getRightsForType(IContext context, String xtypeName) throws com.webmethods.portal.bizPolicy.BizException
context
- current contextxtypeName
- xtype or base type namecom.webmethods.portal.bizPolicy.BizException
Collection getAccessEx(IContext context, IThingID itemID, IURI userID) throws com.webmethods.portal.bizPolicy.BizException
context
- Command contextitemID
- item whose access should be retrieveduserID
- user whose access shouild be retrievedcom.webmethods.portal.bizPolicy.BizException
IListView getAclView(IContext context, IThingID itemID) throws com.webmethods.portal.bizPolicy.BizException
context
- executing contextitemID
- item to retrieve access control listIAceView
objectscom.webmethods.portal.bizPolicy.BizException
void removeAces(IContext context, IThingID itemId, List principalIds, boolean recursive) throws com.webmethods.portal.bizPolicy.BizException
context
- Command context (user state information).itemId
- Item whose access entries to remove.principalIds
- List of IURI
s for which to add or modify access.recursive
- True if the access modification should be applied to this item's descendants.com.webmethods.portal.bizPolicy.BizException
void setAnonymous(IContext context, IThingID itemId, boolean recursive, boolean isAnonymous) throws com.webmethods.portal.bizPolicy.BizException
1) The authLevel on the thing will change. IThingBaseView.getAuthLevel()
2) Authentication will not be required to access this thing
This is really just a convience function for checking to see if getAuthScheme(com.webmethods.portal.bizPolicy.IContext, com.webmethods.portal.service.meta2.thing.IThingID)
is equal to anonymouscontext
- Command context (user state information).itemId
- Item whose anonymous setting to change.recursive
- True if the access modification should be applied to this item's descendants.isAnonymous
- whether or not to set this as anonymouscom.webmethods.portal.bizPolicy.BizException
boolean isAnonymous(IContext context, IThingID itemId) throws com.webmethods.portal.bizPolicy.BizException
context
- Command context (user state information).itemId
- Item whose anonymous setting to query.com.webmethods.portal.bizPolicy.BizException
void setAuthScheme(IContext context, IThingID itemId, boolean recursive, String authLevel) throws com.webmethods.portal.bizPolicy.BizException
context
- Command context (user state information).itemId
- Item whose authLevel setting to change.recursive
- True if the access modification should be applied to this item's descendants.authLevel
- the name of the auth scheme: 'default', 'fullAccess', 'anonymous', 'basic', 'ntlm'com.webmethods.portal.bizPolicy.BizException
IAccessMechanics.AUTH_LEVEL_DEFAULT
,
IAccessMechanics.AUTH_LEVEL_FULL_ACCESS
,
IAccessMechanics.AUTH_LEVEL_ANONYMOUS
,
IAccessMechanics.AUTH_LEVEL_BASIC
,
IAccessMechanics.AUTH_LEVEL_NTLM
String getAuthScheme(IContext context, IThingID itemId) throws com.webmethods.portal.bizPolicy.BizException
context
- Command context (user state information).itemId
- Item whose authLevel setting to query.com.webmethods.portal.bizPolicy.BizException
IAccessMechanics.AUTH_LEVEL_DEFAULT
,
IAccessMechanics.AUTH_LEVEL_FULL_ACCESS
,
IAccessMechanics.AUTH_LEVEL_ANONYMOUS
,
IAccessMechanics.AUTH_LEVEL_BASIC
,
IAccessMechanics.AUTH_LEVEL_NTLM
void setSecurityRealm(IContext context, IThingID itemID, IThingID securityRealmID, boolean recursive) throws com.webmethods.portal.bizPolicy.BizException
context
- Command contextitemID
- item thing ID to set policy onsecurityRealmID
- policy thing IDrecursive
- whether to set policy recursivelycom.webmethods.portal.bizPolicy.BizException
IThingID getSecurityRealm(IContext context, IThingID itemID) throws com.webmethods.portal.bizPolicy.BizException
context
- Command contextitemID
- item thing IDcom.webmethods.portal.bizPolicy.BizException
void removeSecurityRealm(IContext context, IThingID itemID, IThingID securityRealmID, boolean recursive) throws com.webmethods.portal.bizPolicy.BizException
context
- command contextitemID
- item thing IDsecurityRealmID
- policy thing IDcom.webmethods.portal.bizPolicy.BizException
IListView listSecurityRealmObjects(IContext context, IThingID securityRealmID) throws com.webmethods.portal.bizPolicy.BizException
securityRealmID
- com.webmethods.portal.bizPolicy.BizException
@Deprecated IListView listSecurityReamObjects(IContext context, IThingID securityRealmID) throws com.webmethods.portal.bizPolicy.BizException
listSecurityRealmObjects(IContext, IThingID)
insteadsecurityRealmID
- com.webmethods.portal.bizPolicy.BizException