|
BEA Systems, Inc. | |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||
java.lang.Objectweblogic.security.acl.CachingRealm
Caching realm.
| Nested Class Summary | |
protected static class |
CachingRealm.CaseInsensitiveUserInfo
Deprecated. Deprecated in WebLogic Server 7.0. Replaced by the Pluggable Security Infrastructure. |
protected static class |
CachingRealm.Entry
Deprecated. Deprecated in WebLogic Server 7.0. Replaced by the Pluggable Security Infrastructure. |
protected static class |
CachingRealm.UserEntry
Deprecated. Deprecated in WebLogic Server 7.0. Replaced by the Pluggable Security Infrastructure. |
| Field Summary | |
protected TTLCache |
aclNegCache
Deprecated. ACL negative cache. |
protected TTLCache |
aclPosCache
Deprecated. ACL positive cache. |
protected Object |
aclSync
Deprecated. ACL sync object. |
protected TTLCache |
authNegCache
Deprecated. Authentication negative cache. |
protected TTLCache |
authPosCache
Deprecated. Authentication positive cache. |
protected boolean |
caseSensitive
Deprecated. Whether this cache is case-sensitive. |
protected TTLCache |
groupNegCache
Deprecated. Group negative cache. |
protected TTLCache |
groupPosCache
Deprecated. Group positive cache. |
protected Object |
groupSync
Deprecated. Group sync object. |
protected weblogic.logging.LogOutputStream |
log
Deprecated. Debugging log. |
protected TTLCache |
permNegCache
Deprecated. Permission negative cache. |
protected TTLCache |
permPosCache
Deprecated. Permission positive cache. |
protected Object |
permSync
Deprecated. Permission sync object. |
protected TTLCache |
userNegCache
Deprecated. User negative cache. |
protected TTLCache |
userPosCache
Deprecated. User positive cache. |
protected Object |
userSync
Deprecated. User and authentication sync object. |
| Constructor Summary | |
CachingRealm(ListableRealm delegate)
Deprecated. Create a new caching realm instance. |
|
CachingRealm(ListableRealm delegate,
ManageableRealm backup,
Object credential)
Deprecated. Create a new caching realm instance. |
|
| Method Summary | |
User |
authenticate(UserInfo userInfo)
Deprecated. Attempt to authenticate the given user. |
void |
clearAclCaches()
Deprecated. Clear the ACL positive and negative caches. |
void |
clearCaches()
Deprecated. Clear all caches. |
void |
clearGroupCaches()
Deprecated. Clear the group positive and negative caches. |
void |
clearPermCaches()
Deprecated. Clear the permission positive and negative caches. |
void |
clearUserCaches()
Deprecated. Clear all user-related caches. |
void |
deleteAcl(Principal owner,
Acl acl)
Deprecated. Delete an ACL from both the delegate and backup realms. |
void |
deleteGroup(Group group)
Deprecated. Delete a group from both the delegate and backup realms. |
void |
deletePermission(Permission perm)
Deprecated. Delete a permission from both the delegate and backup realms. |
void |
deleteUser(User user)
Deprecated. Delete a user from both the delegate and backup realms. |
Acl |
getAcl(String name)
Deprecated. Retrieves an Access Control List (Acl) of that name, or null. |
Acl |
getAcl(String name,
char separator)
Deprecated. Retrieves an Access Control List (Acl) with the best matching name, or null. |
Principal |
getAclOwner(Object credential)
Deprecated. This is a direct call through to getAclOwner in delegate and/or backup realms. |
Enumeration |
getAcls()
Deprecated. Return all ACLs in both the delegate and backup realms. |
Object |
getCacheValue(Object propId)
Deprecated. |
weblogic.logging.LogOutputStream |
getDebugLog()
Deprecated. |
Class |
getDelegateClass()
Deprecated. Return the class of the delegate realm. |
Group |
getGroup(String name)
Deprecated. Retrieves a group of that name or null. |
Enumeration |
getGroups()
Deprecated. Return all groups in both the delegate and backup realms. |
String |
getName()
Deprecated. Return the name of this realm. |
Permission |
getPermission(String name)
Deprecated. Retrieves a permission object of that name or, if null is passed in, returns null. |
Enumeration |
getPermissions()
Deprecated. Return all permissions in both the delegate and backup realms. |
Principal |
getPrincipal(String name)
Deprecated. |
User |
getUser(String name)
Deprecated. Return the User. |
User |
getUser(UserInfo userInfo)
Deprecated. Call through to the authenticate method. |
Enumeration |
getUsers()
Deprecated. Return all users in both the delegate and backup realms. |
void |
init(String name,
Object ownerCredential)
Deprecated. Call through to the init methods in the delegate and backup realms. |
void |
load(String name,
Object credential)
Deprecated. Call through to the load methods in the delegate and backup realms. |
Acl |
lookupAcl(String name)
Deprecated. Look for the given ACL in the cache. |
Acl |
lookupAcl(String name,
char separator)
Deprecated. |
Group |
lookupGroup(String name)
Deprecated. Look for the given group in the cache. |
Permission |
lookupPermission(String name)
Deprecated. Perform a cache lookup for a permission. |
Principal |
lookupPrincipal(String name)
Deprecated. Look for the named principal in the user and group caches. |
User |
lookupUser(String name)
Deprecated. Look for the given user in the cache. |
BasicRealm |
masqueradeAs(String realmName)
Deprecated. Ensure that the given name in the set of realms points to this realm. |
Acl |
newAcl(Principal owner,
String name)
Deprecated. Create a new ACL in a realm-specific way. |
Group |
newGroup(String name)
Deprecated. Create a new group in a realm-specific way. |
Permission |
newPermission(String name)
Deprecated. Create a new permission in a realm-specific way. |
User |
newUser(String name,
Object credential,
Object constraints)
Deprecated. Create a new user in a realm-specific way. |
void |
refresh()
Deprecated. Refresh by emptying the caches, refreshing the delegate & backup - the CachingRealm will auto-refresh as users/groups/acls are looked up after the caches have been emptied |
void |
save(String name)
Deprecated. Call through to the save methods in the delegate and backup realms. |
void |
setDebug(boolean enable)
Deprecated. |
void |
setPermission(Acl acl,
Principal principal,
Permission permission,
boolean allow)
Deprecated. Sets or unsets a permission for a principal in an ACL. |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected TTLCache aclNegCache
aclPosCache,
aclSyncprotected TTLCache aclPosCache
aclNegCache,
aclSyncprotected final Object aclSync
aclPosCache,
aclNegCacheprotected TTLCache authNegCache
userPosCache,
userNegCache,
authPosCache,
userSyncprotected TTLCache authPosCache
userPosCache,
userNegCache,
authNegCache,
userSyncprotected boolean caseSensitive
protected TTLCache groupNegCache
groupPosCache,
groupSyncprotected TTLCache groupPosCache
groupNegCache,
groupSyncprotected final Object groupSync
groupPosCache,
groupNegCacheprotected weblogic.logging.LogOutputStream log
protected TTLCache permNegCache
permPosCache,
permSyncprotected TTLCache permPosCache
permNegCache,
permSyncprotected final Object permSync
permPosCache,
permNegCacheprotected TTLCache userNegCache
userPosCache,
authPosCache,
authNegCache,
userSyncprotected TTLCache userPosCache
userNegCache,
authPosCache,
authNegCache,
userSyncprotected final Object userSync
userPosCache,
userNegCache,
authPosCache,
authNegCache| Constructor Detail |
public CachingRealm(ListableRealm delegate)
public CachingRealm(ListableRealm delegate,
ManageableRealm backup,
Object credential)
| Method Detail |
public User authenticate(UserInfo userInfo)
userInfo - authentication info associated with the user
public void clearAclCaches()
public void clearCaches()
public void clearGroupCaches()
public void clearPermCaches()
public void clearUserCaches()
public void deleteAcl(Principal owner,
Acl acl)
throws SecurityException
deleteAcl in interface ManageableRealmowner - Principal who is an owner of the ACLacl - Access control list to be deleted
SecurityException - bad juju
UnsupportedOperationException - the delegate realm does
not support this operationManageableRealm.deleteAcl(java.security.Principal, java.security.acl.Acl)
public void deleteGroup(Group group)
throws SecurityException
deleteGroup in interface ManageableRealmgroup - Group to be removed from the realm
SecurityException - bad juju
UnsupportedOperationException - the delegate realm does
not support this operationManageableRealm.deleteGroup(java.security.acl.Group)
public void deletePermission(Permission perm)
throws SecurityException
deletePermission in interface ManageableRealmperm - Permission to be removed from the realm
SecurityException - bad juju
UnsupportedOperationException - the delegate realm does
not support this operationManageableRealm.deletePermission(java.security.acl.Permission)
public void deleteUser(User user)
throws SecurityException
deleteUser in interface ManageableRealmuser - User to be removed from the realm
SecurityException - bad juju
UnsupportedOperationException - the delegate realm does
not support this operationManageableRealm.deleteUser(weblogic.security.acl.User)public Acl getAcl(String name)
BasicRealm
getAcl in interface BasicRealmname - of the Acl to retrieve
public Acl getAcl(String name,
char separator)
BasicRealm
getAcl in interface BasicRealmname - of the Acl to lookupseparator - character that separates segments in an Acl name
public Principal getAclOwner(Object credential)
getAclOwner in interface BasicRealmcredential - Credentials of an owner
BasicRealm.getAclOwner(java.lang.Object)public Enumeration getAcls()
getAcls in interface ListableRealmUnsupportedOperationException - the delegate realm does
not support this operationListableRealm.getAcls()public Object getCacheValue(Object propId)
public weblogic.logging.LogOutputStream getDebugLog()
getDebugLog in interface DebuggableRealmpublic Class getDelegateClass()
public Group getGroup(String name)
BasicRealm
getGroup in interface BasicRealmname - of the group to get
public Enumeration getGroups()
getGroups in interface ListableRealmUnsupportedOperationException - the delegate realm does
not support this operationListableRealm.getGroups()public String getName()
getName in interface BasicRealmpublic Permission getPermission(String name)
BasicRealm
getPermission in interface BasicRealmname - Permission to get
public Enumeration getPermissions()
getPermissions in interface ListableRealmUnsupportedOperationException - the delegate realm does
not support this operationListableRealm.getPermissions()public Principal getPrincipal(String name)
public User getUser(String name)
getUser in interface BasicRealmname - String name of user
public User getUser(UserInfo userInfo)
getUser in interface BasicRealmuserInfo - Credentials to check against
authenticate(weblogic.security.acl.UserInfo)public Enumeration getUsers()
getUsers in interface ListableRealmUnsupportedOperationException - the delegate realm does
not support this operationListableRealm.getUsers()
public void init(String name,
Object ownerCredential)
throws NotOwnerException
init in interface BasicRealmname - Name of RealmownerCredential - Credentialed owner of a BasicRealm
NotOwnerException - if
the owner credential is invalidBasicRealm.init(java.lang.String, java.lang.Object)
public void load(String name,
Object credential)
throws ClassNotFoundException,
IOException,
NotOwnerException
load in interface BasicRealmname - Name of BasicRealm to loadcredential - Credentialed owner of a BasicRealm
ClassNotFoundException - if the BasicRealm cannot be found
NotOwnerException - if the credential does not match an owner
IOException - if there is an I/O errorBasicRealm.load(java.lang.String, java.lang.Object)public Acl lookupAcl(String name)
public Acl lookupAcl(String name,
char separator)
name - of Acl to look upseparator - character that separates segments in an Acl name, usually '.'
public Group lookupGroup(String name)
public Permission lookupPermission(String name)
name - of permission to lookup
public Principal lookupPrincipal(String name)
public User lookupUser(String name)
public BasicRealm masqueradeAs(String realmName)
Realm.getRealm(java.lang.String)
public Acl newAcl(Principal owner,
String name)
throws SecurityException
newAcl in interface ManageableRealmowner - Owner of the access control listname - Name of the access control list
SecurityException - bad juju
UnsupportedOperationException - the delegate realm does not
support this operationManageableRealm.newAcl(java.security.Principal, java.lang.String)
public Group newGroup(String name)
throws SecurityException
newGroup in interface ManageableRealmname - Name for the new Group
SecurityException - bad juju
UnsupportedOperationException - the delegate realm does not
support this operationManageableRealm.newGroup(java.lang.String)
public Permission newPermission(String name)
throws SecurityException
newPermission in interface ManageableRealmname - Name for the Permission
SecurityException - bad juju
UnsupportedOperationException - the delegate realm does not
support this operationManageableRealm.newPermission(java.lang.String)
public User newUser(String name,
Object credential,
Object constraints)
throws SecurityException
Note: we do not currently attempt to clear the negative authentication cache when a new user is created, because there may be several negative hits associated with a given user and keeping track of them is not practicable.
For this reason, you should keep the time-to-live value on the negative authentication cache low if you intend to add users to a realm, otherwise you risk denying them access because of negative cache entries that have not yet expired.
If you must ensure that the negative authentication cache is cleared when a user is created, simply extend this class and make sure that your implementation of this method traverses the negative authentication cache, clearing any entries whose names match the name of the new user. This may be an expensive operation, depending on cache size and frequency of user creation.
newUser in interface ManageableRealmname - Usernamecredential - X.509 certificate, token, or password, etc.constraints - Constraints on this user's access
SecurityException - bad juju
UnsupportedOperationException - the delegate realm does not
support this operationManageableRealm.newUser(java.lang.String, java.lang.Object, java.lang.Object)public void refresh()
refresh in interface RefreshableRealm
public void save(String name)
throws IOException
save in interface BasicRealmname - Name to save under
IOException - if there is an I/O errorBasicRealm.save(java.lang.String)public void setDebug(boolean enable)
setDebug in interface DebuggableRealm
public void setPermission(Acl acl,
Principal principal,
Permission permission,
boolean allow)
setPermission in interface ManageableRealmacl - Access control list to be updatedprincipal - Principal who is an owner of the ACLpermission - Permission to be updatedallow - True to set permission to allow
UnsupportedOperationException - the delegate realm does
not support this operationManageableRealm.setPermission(java.security.acl.Acl, java.security.Principal, java.security.acl.Permission, boolean)
|
Documentation is available at http://download.oracle.com/docs/cd/E13222_01/wls/docs90 Copyright 2005 BEA Systems Inc. |
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||