|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectgate.security.AccessControllerImpl
Field Summary | |
protected int |
dbType
|
static int |
DEFAULT_SESSION_TIMEOUT_MIN
|
private HashMap |
groupsByID
|
private HashMap |
groupsByName
|
private boolean |
isPooled
|
private Connection |
jdbcConn
|
private String |
jdbcSchema
|
private String |
jdbcURL
|
static int |
LOGIN_FAILED
|
static int |
LOGIN_OK
|
private static long |
MY_VERY_SECRET_CONSTANT
|
private Vector |
omCreationListeners
--- |
private Vector |
omDeletionListeners
--- |
private Vector |
omModificationListeners
--- |
private static Random |
r
|
private static int |
RANDOM_MAX
|
private int |
refCnt
|
private HashMap |
sessionLastUsed
|
private HashMap |
sessions
|
private HashMap |
sessionTimeouts
|
private HashMap |
usersByID
|
private HashMap |
usersByName
|
Constructor Summary | |
AccessControllerImpl(String jdbcURL)
--- |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int DEFAULT_SESSION_TIMEOUT_MIN
public static final int LOGIN_OK
public static final int LOGIN_FAILED
private static long MY_VERY_SECRET_CONSTANT
private static final int RANDOM_MAX
private HashMap sessions
private HashMap sessionLastUsed
private HashMap sessionTimeouts
private Connection jdbcConn
private String jdbcURL
private String jdbcSchema
protected int dbType
private HashMap usersByID
private HashMap usersByName
private HashMap groupsByID
private HashMap groupsByName
private static Random r
private boolean isPooled
private int refCnt
private Vector omModificationListeners
private Vector omCreationListeners
private Vector omDeletionListeners
Constructor Detail |
public AccessControllerImpl(String jdbcURL)
Method Detail |
public void open() throws PersistenceException
open
in interface AccessController
PersistenceException
public void close() throws PersistenceException
close
in interface AccessController
PersistenceException
public Group findGroup(String name) throws PersistenceException, SecurityException
findGroup
in interface AccessController
PersistenceException
SecurityException
public Group findGroup(Long id) throws PersistenceException, SecurityException
findGroup
in interface AccessController
PersistenceException
SecurityException
public User findUser(String name) throws PersistenceException, SecurityException
findUser
in interface AccessController
PersistenceException
SecurityException
public User findUser(Long id) throws PersistenceException, SecurityException
findUser
in interface AccessController
PersistenceException
SecurityException
public Session findSession(Long id) throws SecurityException
findSession
in interface AccessController
SecurityException
public Group createGroup(String name, Session s) throws PersistenceException, SecurityException
createGroup
in interface AccessController
PersistenceException
SecurityException
public void deleteGroup(Long id, Session s) throws PersistenceException, SecurityException
deleteGroup
in interface AccessController
PersistenceException
SecurityException
public void deleteGroup(Group grp, Session s) throws PersistenceException, SecurityException
deleteGroup
in interface AccessController
PersistenceException
SecurityException
public User createUser(String name, String passwd, Session s) throws PersistenceException, SecurityException
createUser
in interface AccessController
PersistenceException
SecurityException
public void deleteUser(User usr, Session s) throws PersistenceException, SecurityException
deleteUser
in interface AccessController
PersistenceException
SecurityException
public void deleteUser(Long id, Session s) throws PersistenceException, SecurityException
deleteUser
in interface AccessController
PersistenceException
SecurityException
public Session login(String usr_name, String passwd, Long prefGroupID) throws PersistenceException, SecurityException
login
in interface AccessController
PersistenceException
SecurityException
public void logout(Session s) throws SecurityException
logout
in interface AccessController
SecurityException
public void setSessionTimeout(Session s, int timeoutMins) throws SecurityException
setSessionTimeout
in interface AccessController
SecurityException
public boolean isValidSession(Session s)
isValidSession
in interface AccessController
public List listGroups() throws PersistenceException
listGroups
in interface AccessController
PersistenceException
public List listUsers() throws PersistenceException
listUsers
in interface AccessController
PersistenceException
private void touchSession(Session s)
private Long createSessionID()
private boolean canDeleteGroup(Group grp) throws PersistenceException, SecurityException
PersistenceException
SecurityException
private boolean canDeleteUser(User usr) throws PersistenceException, SecurityException
PersistenceException
SecurityException
private void init() throws PersistenceException
PersistenceException
private void fireObjectCreatedEvent(ObjectModificationEvent e)
private void fireObjectDeletedEvent(ObjectModificationEvent e)
private void fireObjectModifiedEvent(ObjectModificationEvent e)
public void registerObjectModificationListener(ObjectModificationListener l, int eventType)
public void unregisterObjectModificationListener(ObjectModificationListener l, int eventType)
public void objectCreated(ObjectModificationEvent e)
objectCreated
in interface ObjectModificationListener
public void objectModified(ObjectModificationEvent e)
objectModified
in interface ObjectModificationListener
public void objectDeleted(ObjectModificationEvent e)
objectDeleted
in interface ObjectModificationListener
public void processGateEvent(GateEvent e)
GateListener
processGateEvent
in interface GateListener
public boolean isValidSecurityInfo(SecurityInfo si)
isValidSecurityInfo
in interface AccessController
public void finalize()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |