public class SessionServiceImpl extends Object implements SessionService
| Modifier and Type | Field and Description |
|---|---|
static String |
AT |
static String |
AUTHENTICATION_TYPE_PROPERTY |
static String |
GSS_PATTERN_PROPERTY |
static String |
PASSWORD_PATTERN_PROPERTY |
static String |
SECURITY_DOMAIN_PROPERTY |
protected SecurityHelper |
securityHelper |
DEFAULT_MAX_SESSIONS, DEFAULT_SESSION_EXPIRATION, MAX_SESSIONS, NAME, SESSION_EXPIRATION| Constructor and Description |
|---|
SessionServiceImpl() |
| Modifier and Type | Method and Description |
|---|---|
void |
closeSession(String sessionID)
Closes the specified session.
|
SessionMetadata |
createSession(String vdbName,
String vdbVersion,
AuthenticationType authType,
String userName,
Credentials credentials,
String applicationName,
Properties properties)
Create a session for the given user authenticating against the given
Credentials. |
SessionMetadata |
getActiveSession(String sessionID) |
Collection<SessionMetadata> |
getActiveSessions()
Get the collection of active user sessions on the system.
|
int |
getActiveSessionsCount()
Get the number of active user sessions on the system.
|
protected VDBMetaData |
getActiveVDB(String vdbName,
String vdbVersion) |
AuthenticationType |
getAuthenticationType(String vdbName,
String version,
String userName) |
AuthenticationType |
getDefaultAuthenticationType() |
String |
getSecurityDomain(String userName,
String vdbName,
String version,
VDB vdb) |
SecurityHelper |
getSecurityHelper() |
long |
getSessionExpirationTimeLimit() |
long |
getSessionMaxLimit() |
Collection<SessionMetadata> |
getSessionsLoggedInToVDB(VDBKey key)
Get all Sessions that are in the ACTIVE state
and currently logged in to a VDB.
|
boolean |
isAllowSecurityDomainQualifier() |
boolean |
isTrustAllLocal() |
GSSResult |
neogitiateGssLogin(String user,
String vdbName,
String vdbVersion,
byte[] serviceTicket) |
void |
pingServer(String sessionID)
Periodically called by the client to indicate the client is still alive.
|
void |
setAllowSecurityDomainQualifier(boolean useSecurityDomainQualifier) |
void |
setAuthenticationType(AuthenticationType flag) |
void |
setDqp(DQPCore dqp) |
void |
setSecurityDomain(String domainName) |
void |
setSecurityHelper(SecurityHelper securityHelper) |
void |
setSessionExpirationTimeLimit(long limit) |
void |
setSessionMaxLimit(long limit) |
void |
setTrustAllLocal(boolean trustAllLocal) |
void |
setVDBRepository(VDBRepository repo) |
void |
start() |
void |
stop() |
boolean |
terminateSession(String terminatedSessionID,
String adminSessionID)
Terminates the specified session.
|
SessionMetadata |
validateSession(String sessionID)
This method is intended to verify that the session is valid, and, if
need be, set the session in an active state, ready to be used.
|
public static final String GSS_PATTERN_PROPERTY
public static final String PASSWORD_PATTERN_PROPERTY
public static final String SECURITY_DOMAIN_PROPERTY
public static final String AUTHENTICATION_TYPE_PROPERTY
public static final String AT
protected SecurityHelper securityHelper
public void setSecurityDomain(String domainName)
public void closeSession(String sessionID) throws InvalidSessionException
SessionServicecloseSession in interface SessionServiceInvalidSessionExceptionpublic SessionMetadata createSession(String vdbName, String vdbVersion, AuthenticationType authType, String userName, Credentials credentials, String applicationName, Properties properties) throws LoginException, SessionServiceException
SessionServiceCredentials.createSession in interface SessionServiceLoginExceptionSessionServiceExceptionprotected VDBMetaData getActiveVDB(String vdbName, String vdbVersion) throws SessionServiceException
vdbName - vdbVersion - SessionServiceException - if the version is not valid or the vdb doesn't accept connectionspublic Collection<SessionMetadata> getActiveSessions()
SessionServicegetActiveSessions in interface SessionServicepublic SessionMetadata getActiveSession(String sessionID)
getActiveSession in interface SessionServicepublic int getActiveSessionsCount()
throws SessionServiceException
SessionServicegetActiveSessionsCount in interface SessionServiceSessionServiceExceptionpublic Collection<SessionMetadata> getSessionsLoggedInToVDB(VDBKey key)
SessionServicegetSessionsLoggedInToVDB in interface SessionServicepublic void pingServer(String sessionID) throws InvalidSessionException
SessionServicepingServer in interface SessionServicesessionID - - identifies the clientInvalidSessionExceptionpublic boolean terminateSession(String terminatedSessionID, String adminSessionID)
SessionServiceterminateSession in interface SessionServiceterminatedSessionID - The SessionID identifying user's session to be terminatedadminSessionID - The session id identifying session of administratorpublic SessionMetadata validateSession(String sessionID) throws InvalidSessionException, SessionServiceException
SessionServicevalidateSession in interface SessionServicesessionID - SessionID representing the sessionInvalidSessionExceptionSessionServiceExceptionpublic long getSessionMaxLimit()
public void setSessionMaxLimit(long limit)
public long getSessionExpirationTimeLimit()
public void setSessionExpirationTimeLimit(long limit)
public void setAuthenticationType(AuthenticationType flag)
public void start()
public void stop()
public void setVDBRepository(VDBRepository repo)
public void setSecurityHelper(SecurityHelper securityHelper)
public void setDqp(DQPCore dqp)
setDqp in interface SessionServicepublic SecurityHelper getSecurityHelper()
getSecurityHelper in interface SessionServicepublic AuthenticationType getAuthenticationType(String vdbName, String version, String userName) throws LogonException
getAuthenticationType in interface SessionServiceLogonExceptionpublic String getSecurityDomain(String userName, String vdbName, String version, VDB vdb) throws LoginException
LoginExceptionpublic GSSResult neogitiateGssLogin(String user, String vdbName, String vdbVersion, byte[] serviceTicket) throws LoginException, LogonException
neogitiateGssLogin in interface SessionServiceLoginExceptionLogonExceptionpublic AuthenticationType getDefaultAuthenticationType()
getDefaultAuthenticationType in interface SessionServicepublic boolean isTrustAllLocal()
public void setTrustAllLocal(boolean trustAllLocal)
public void setAllowSecurityDomainQualifier(boolean useSecurityDomainQualifier)
public boolean isAllowSecurityDomainQualifier()
Copyright © 2018 JBoss by Red Hat. All rights reserved.