public class SecureReferenceLocator extends UnicastRemoteObject implements SecureEntityReferenceLocator, ServerReferenceLocator, ConnectionOptimizer, RemotelyManageable, UtilReferenceLocator, RemoteReportReferencer, RemoteApplicationPreferenceReferencer, RemoteLControlAdministration, RemoteLOk, INoticeSystem, INoticeSendMails, XMLClientProvider, ISSOServer
| Modifier and Type | Class and Description |
|---|---|
static class |
SecureReferenceLocator.BMessage
Internal class for utility messages.
|
protected class |
SecureReferenceLocator.LogStream |
static class |
SecureReferenceLocator.SMessage
Internal class for utility messages.
|
protected class |
SecureReferenceLocator.TWatchDog |
protected class |
SecureReferenceLocator.UpdateListThread |
UtilReferenceLocator.MessagerefACCESS_DENIEDADMINISTRATION_PERMISSION, CONNECTION_INFO, IS_MULTICONNECTION, LOADED_ENTITIES, MULTICONNECTION_IDLIST, MULTICONNECTION_INFOINTERNAL_NOTICE_PERIOD, MAIL_CONF_PROPERTIES, NOTICE_CONTENT, NOTICE_CREATE_DATE, NOTICE_DELETE_RECEIVE_NOTICE, NOTICE_DELETE_SEND_NOTICE, NOTICE_DESTINY_KEY, NOTICE_ENTITY_DESTINY_TABLE_DB, NOTICE_ENTITY_TABLE_DB, NOTICE_FORCE_READ, NOTICE_FROM_PARAMETER, NOTICE_KEY, NOTICE_MAILTO_PARAMETER, NOTICE_MESSAGE_COLUMN_NAME, NOTICE_MESSAGE_TYPE_COLUMN_NAME, NOTICE_OTHER_COLUMNS, NOTICE_READ, NOTICE_READ_DATE, NOTICE_RESPONSE_REQUEST, NOTICE_SEND, NOTICE_SEND_DATE, NOTICE_SEND_MAIL, NOTICE_SUBJECT, NOTICE_SYSTEM, NOTICE_TO_PARAMETER, PROP_NOTICE_CLASS_MAIL, PROP_NOTICE_CONFIG_DEFAULT_TEMPLATE, PROP_NOTICE_CONFIG_MAIL, PROP_NOTICE_CONFIG_REQUEST_TEMPLATE, PROP_NOTICE_CONFIG_TEMPLATES, PROP_NOTICE_ENTITY_DESTINY_NAME, PROP_NOTICE_ENTITY_NAME, SEND_MAIL_PERIOD| Constructor and Description |
|---|
SecureReferenceLocator(DatabaseConnectionManager databaseManager,
String entitiesPackage,
int port) |
SecureReferenceLocator(DatabaseConnectionManager databaseManager,
String entitiesPackage,
int port,
boolean uniqueSession) |
SecureReferenceLocator(DatabaseConnectionManager connectionManager,
String entitiesPackage,
int port,
boolean uniqueSession,
String loginEntity) |
SecureReferenceLocator(int port,
Hashtable params)
Creates a secure reference locator.
|
| Modifier and Type | Method and Description |
|---|---|
void |
addRemoteReportStore(ReportStore rs) |
void |
blockUserDB(String user)
Blocks an user in database
|
EntityResult |
changePassword(String password,
int sessionId,
Hashtable av,
Hashtable kv) |
boolean |
checkBlockUserDB(String user)
Check if an user is blocked in database
|
protected void |
checkLogFileChange(int bytesToWriteCount) |
void |
checkNoticeAsSend(Object noticeKey)
This method marks the specified notice as sent
|
void |
checkNoticeSent(int sessionId,
Object noticeKey)
This method sets a notices as sent
|
protected boolean |
checkTemporaryPassword(String user,
String password) |
boolean |
checkToken(String token) |
void |
closeLockedConnections(String id,
String databaseId) |
void |
closeServer() |
void |
closeServer(Frame fAux) |
void |
closeSession(int sessionId) |
boolean |
closeSession(String id,
int sessionId)
This method close the user's session with the given sessionID.
|
protected DatabaseConnectionManager |
configureConnectionManager(boolean bStatisticViewer,
URL dbPropertiesURL,
URL autonumericalURL)
Deprecated.
|
protected void |
configureModuleRemoteReferences() |
protected void |
configureMultiConnectionManager() |
protected void |
configureReference(Node currentNode) |
protected void |
configureReferences(String xmlDefinitionResource)
The constructor of each reference must have the next parameters:
EntityReferenceLocator: locator reference. |
protected void |
configureRemoteReference(Node currentNode) |
protected void |
configureRemoteReferences(String xmlDefinitionResource)
The constructor of each remote reference must have the next parameters:
int: rmi port EntityReferenceLocator: locator reference. |
protected DatabaseConnectionManager |
createConnectionManager(boolean bStatisticViewer,
URL dbPropertiesURL,
URL autonumericalURL) |
protected DatabaseConnectionManager |
createConnectionManager(Hashtable databaseParams) |
protected DatabaseEntityManager |
createDatabaseEntityManager(Hashtable param)
Create the object to create the database entities
|
protected Entity |
createEntity(String sEntityClass,
DatabaseConnectionManager entityConnectionManager,
int port,
String props) |
protected Object |
createReference(String className,
Hashtable parameters) |
protected Object |
createRemoteReference(String className,
Hashtable parameters) |
void |
endAdministrationSession() |
void |
endSession(int id)
This method finishes a client session.
|
void |
finishAdministrationRemoteSession(String id)
Method that finishes the remote session.
|
protected void |
flushLogBuffer() |
protected void |
forceFinishSession(int sessionId) |
protected Class<Entity> |
foundModuleEntityClass(String entityName) |
void |
freeServerResources() |
static int |
generatePrivilegedId() |
boolean |
getAccessControl()
Check if the control access attempts is enabled
|
Entity |
getAttachmentEntity(int sessionId) |
protected Certificate |
getCertificateFromText(String certText) |
Hashtable |
getConfigurationParameters(String clientName) |
List |
getConnectedSessionIds(int sessionId) |
List |
getConnectedUsers(int sessionId) |
protected Hashtable |
getConnectionInfo(DatabaseConnectionManager dBManager)
Method that returns the characteristics of the database connection to the
given DatabaseConnecionManager.
|
DatabaseConnectionManager |
getConnectionManager() |
int |
getDataCompressionThreshold(int sessionId)
Gets the value of the data compression threshold for the specified user
|
boolean |
getDEBUGValueRemote(String id,
String v)
Method to obtain the current value of the DEBUG Server variables.
|
String |
getDefaultPackage() |
protected Entity |
getEntity(String entityName)
Get a entity reference
|
protected Entity |
getEntity(String entityName,
boolean checkDataBase)
Get the reference for the specified entity.
|
Entity |
getEntityReference(String entityName)
This method always throws a Exception because the secure implementation
is not particularly interesting
|
Entity |
getEntityReference(String entityName,
String user,
int id)
This method replaces to
EntityReferenceLocator.getEntityReference(String) and gets entity
references with security |
Entity |
getEntityReferenceFromServer(String entityName)
This method allows to get an entity reference only in the server side.
|
ErrorAccessControl |
getErrorAccessControl()
Return the ErrorAccesControl
|
Hashtable |
getFormManagerParameters(String formManagerId,
int userid) |
BytesBlock |
getImage(String image,
int userId) |
EntityResult |
getInternalNotices(int sessionId,
boolean unsend,
boolean unread,
boolean deleted)
Method to get all notices for the specified user.
|
String |
getLastNCharactersFromLogFile(int nCharacters)
Method that recovers the n characters indicated from the log file.
|
String |
getLContent(int sessionId) |
Object |
getLInfoObject(int sessionId) |
List |
getLoadedEntities() |
List |
getLoadedEntities(int sessionId) |
Locale |
getLocale(int sessionId) |
String |
getLocaleEntity() |
Object |
getLocaleId(int sessionId) |
String |
getLogFile() |
String |
getLoginEntityName(int sessionId)
Get the name of the login entity (LoginEntity parameter)
|
String |
getLValue(int sessionId,
String name) |
Vector |
getMessages(int sessionIdTo,
int sessionId) |
EntityResult |
getNewMailNotice()
This method allows to get all e-mail notices not yet sent
|
protected int |
getNextLogFileIndex(File fileLog)
Get index of next log file and calls
#zipLogFile(String) when
isZipLogFile enabled. |
protected String |
getNodeValue(Node son) |
protected Entity |
getNoticeEntity(String entityName,
boolean isDestinyEntity) |
String |
getNoticeEntityDestinyName()
Get the name of the notice destiny entity
|
String |
getNoticeEntityName()
Get the name of the notice entity
|
Vector |
getNoticeTypes()
Get the identifies for all notices types in the application
|
Hashtable |
getParameters(String login,
String password) |
protected String |
getPasswordFromCert(Certificate cert)
Returns the text of
CertificateUtils.DNIe_SERIALNUMBER
field. |
String |
getPasswordFromCert(String certificate)
Returns the password.
|
Entity |
getPrintingTemplateEntity(int sessionId) |
Object |
getReference(String name)
Allows to get local references defined in 'references.xml' file when
app is remote .
|
Vector |
getRemoteAdministrationMessages(int sessionIdTo,
int sessionId) |
RemoteApplicationPreferences |
getRemoteApplicationPreferences(int sessionId)
getRemoteApplicationPreferences
|
IRemoteLogManager |
getRemoteLogManager(String id) |
RemoteOperationManager |
getRemoteOperationManager(int sessionId) |
Properties |
getRemotePreferencesFile(String id)
Method to get remotely the Server Preferences file.
|
Object |
getRemoteReference(String name) |
Object |
getRemoteReference(String name,
int sessionId)
Gets a remote reference.
|
List |
getRemoteReportStore(int sessionId) |
List |
getReportEntityNames(int sessionId) |
EntityResult |
getSentNotices(int sessionId,
Boolean deleted)
Method to query all notices sent by the specified user
|
String |
getSerial(String userAdmin,
String password) |
String |
getServerServiceName(String clientName) |
TimeZone |
getServerTimeZone(int sessionId)
Get the Server TimeZone.
|
int |
getSessionId()
Always return -1 because the client session identifier is not available
in server side.
|
SessionInfo[] |
getSessionInfo(String id)
This method returns the main information of all available user's
sessions.
|
protected Entity |
getSpecialEntity(String entityName,
String originalEntity) |
Hashtable |
getStartSessionTime(String id)
This method obtains a list with all the start times of all connections.
|
String |
getSuffixString() |
Hashtable |
getSystemInfo(String id,
String key)
Method that returns system information about the connection with the
database.
|
String |
getTemporaryPassword(String user)
Get a temporary password for the given user, this method is only
accesible from server side.
|
String |
getToken() |
String |
getUser(int id) |
protected String |
getUserFromCert(Certificate cert)
Returns the user from certificate.
|
String |
getUserFromCert(String certificate) |
Object |
getUserId(int sessionId)
Get the identification of the user that must be stored in the notice
system to identify this application user.
|
Hashtable |
getUserIds(String id)
This method returns a Hashtable with the current list of users's IDs.
|
ListModel |
getUserInfoListModel() |
String |
getXMLForm(String form,
int userid) |
String |
getXMLMenu(int userid) |
String |
getXMLRules(String form,
int userid) |
String |
getXMLToolbar(int userid) |
boolean |
hasSession(int sessionId) |
boolean |
hasSession(String user,
int sessionId)
Return true if the user 'user' with session identifier 'id' has a current
session opened
|
static boolean |
isAllowCertificateLogin() |
boolean |
isDevelopementL(int sessionId) |
protected boolean |
isLDAPUser(String user,
String password) |
boolean |
isMultiConnectionManager() |
protected boolean |
isValidCertificateText(String certText) |
protected Entity |
loadEntity(String entityName,
boolean checkDatabase,
DatabaseConnectionManager entityConnectionManager)
Load the entity with the specified name.
|
protected boolean |
localAuthenticate(Exception e) |
boolean |
ok(int sessionId) |
boolean |
ok(int sessionId,
String number) |
boolean |
ok(String login,
String password) |
boolean |
ping()
unimplemented.
|
void |
reloadXMLMenu(int userid) |
void |
reloadXMLToolbar(int userid) |
void |
removeEntity(String entityName) |
void |
removeEntity(String entityName,
int sessionId) |
void |
removeEntity(String id,
String entityName) |
void |
removeReceivedNotices(int sessionId,
Vector idNotices)
This method removes the specified received notices for the user with this
session identifier.
|
void |
removeSentNotices(int sessionId,
Vector idNotices)
This method sets the specified notices as deleted
|
void |
restartServer(String id) |
InitialContext |
retrieveInitialContext(int sessionId,
Hashtable params) |
byte[] |
returnMessage(String contextRef,
byte[] inData) |
void |
sendMessage(String message,
String user,
int sessionId) |
void |
sendMessage(UtilReferenceLocator.Message message,
String user,
int sessionId) |
void |
sendMessageToAll(String message,
int sessionId) |
void |
sendNotice(Hashtable messageValues,
int sessionId,
boolean request)
Method used to send notices.
|
void |
sendRemoteAdministrationMessages(String message,
int sessionId) |
void |
setCompressionEnabled(boolean enabled) |
void |
setDataCompressionThreshold(String user,
int sessionId,
int compressionThreshold)
Establishes the compression type for this user
|
void |
setDEBUGValueRemote(String id,
String v,
boolean b)
Method to set the DEBUG Server variables.
|
protected void |
setDefaultLocaleId(int sessionId) |
void |
setLocale(int sessionId,
Locale locale) |
void |
setMultiConnectionManager(boolean multiConnectionManager) |
void |
setNoticesRead(int sessionId,
Vector idNotices)
Method to set some notices as read
|
void |
setRemotePreferencesFile(String id,
Properties prop)
Method to set remotely the Server Preferences file.
|
void |
setSessionIdLastAccessTime(long time,
int sessionId) |
String |
startAdministrationRemoteSession(String user,
String password)
This method starts a new remote session.
|
protected int |
startCertificateSession(String user,
String password,
ClientWatch clientWatch)
Checks whether session contains a valid certificate or is a usual
user-password session.
|
int |
startSession(String user,
String password,
ClientWatch clientWatch)
Method to start a client session.
|
protected int |
startSessionInner(String user,
String password,
ClientWatch clientWatch) |
protected String |
startTemporalAdminitrationSession(String user,
String password) |
void |
stopServer(String id) |
boolean |
supportChangePassword(String user,
int sessionId) |
EntityResult |
testConnectionSpeed(int sizeInBytes,
boolean compressed)
This method test the connection speed an return an EntityResult to check
the line
|
Hashtable |
updateL(Hashtable h,
String login,
String password) |
protected void |
updateListInfo(Integer id) |
protected File |
zipLogFile(File directory,
String logFilePath)
Zips custom log file just when this just reaches maximum log file
capacity.
|
clone, exportObject, exportObject, exportObject, unexportObjectgetClientHost, getLog, setLogpublic static final String REMOTE_PREFERENCES_CONFIGURATION_FILE
protected static final String MISSING_PARAMETER
protected static final String FORM_PROVIDER_ENTITY
protected static final String FORM_PROVIDER_ENTITY_FORMNAME_COLUMN
protected static final String FORM_PROVIDER_ENTITY_FORMXML_COLUMN
protected static final String FORM_PROVIDER_ENTITY_FORMRULE_COLUMN
protected static final String FORM_MANAGER_PROVIDER_ENTITY
protected static final String FORM_MANAGER_PROVIDER_ENTITY_ID_COLUMN
protected static final String FORM_MANAGER_PROVIDER_ENTITY_FORM_NAME_COLUMN
protected static final String FORM_MANAGER_PROVIDER_ENTITY_INTERACTION_MANAGER_COLUMN
protected static final String IMAGE_PROVIDER_ENTITY
protected static final String IMAGE_PROVIDER_ENTITY_IMAGENAME_COLUMN
protected static final String IMAGE_PROVIDER_ENTITY_IMAGEBYTES_COLUMN
protected static final String MENU_PROVIDER_ENTITY
protected static final String MENU_PROVIDER_ENTITY_XML_COLUMN
protected static final String TOOLBAR_PROVIDER_ENTITY
protected static final String TOOLBAR_PROVIDER_ENTITY_XML_COLUMN
protected static final String PREFERENCE_CLASS
protected static final String DATABASE_PROPERTIES
protected static final String PRINTING_TEMPLATE_ENTITY
protected static final String PRIVATE_REPORT_STORE
protected static final String REPORT_STORE
protected static final String REPORT_STORE_PATH
protected static final String LDAP_SSL
protected static final String MODULES
protected static final String MODULE_DISCOVERY
@Deprecated protected static final String USER_DNS_STRING
protected static final String USER_DN_STRING
protected static final String SEARCH_USER_PASSWORD
protected static final String SEARCH_USER
protected static final String SEARCH_USER_STRING
protected static final String JAAS_CONFIG_FILE
protected static final String DOMAIN
protected static final String LDAP_PORT
protected static final String LDAP_HOST
protected static final String KDC
protected static final String KREALM
protected static final String LOG_BUFFER_SIZE
protected static final String MAX_LOG_FILE_SIZE
protected static final String LOG_FILE
public static final String ZIP_LOG_FILE
protected static final String RESTART_COMMAND
protected static final String ADMIN_PASSWORD
protected static final String ADMIN_USER
protected static final String LOGIN_ENTITY
protected static final String ID_CARD_COLUMN
protected static final String USE_APPLICATION_USER
protected static final String CHECK_SESSIONS_TIME
protected static final String MAX_INACTIVE_SESSION_TIME
protected static final String CLOSE_WAIT_TIME
protected static final String MAXUSERS
protected static final String MULTICONNECTION_MANAGER
protected static final String PACKAGE
protected static final String REMOTE_OPERATION_MANAGER
public static final String REMOTE_REFERENCES
protected ModuleManager moduleManager
protected EntitiesPropertiesParser parserProperties
protected Hashtable remoteReferenceInstances
public static final String REFERENCES
protected Hashtable referenceClassNames
protected Hashtable referenceParameters
protected Hashtable referenceInstances
protected static final String LDAP_USERDN_KEY
protected String formProviderEntity
protected String formProviderEntityFormNameColumn
protected String formProviderEntityFormXMLColumn
protected String formProviderEntityFormRuleColumn
protected DatabaseEntityManager databaseEntityManager
protected String imageProviderEntity
protected String imageProviderEntityImageNameColumn
protected String imageProviderEntityImageBytesColumn
protected String formManagerProviderEntity
protected String formManagerProviderEntityIdColumn
protected String formManagerProviderEntityFormNameColumn
protected String formManagerProviderEntityInteractionManagerColumn
protected String menuProviderEntity
protected String menuProviderEntityXMLColumn
protected String toolbarProviderEntity
protected String toolbarProviderEntityXMLColumn
protected Hashtable loadedEntities
protected DatabaseConnectionManager manager
protected String packageS
protected int maximumUsers
protected boolean oneSessionAllowed
protected Vector userIdList
public static int MIN_COMPRESSION_THRESHOLD
protected SendMailThread sendMailThread
protected IRemoteLogManager remoteLogManager
protected Hashtable currentUserList
protected Hashtable startSessionTimeList
protected Hashtable lastSessionAccessTimeList
protected Hashtable compressionThresholds
protected Hashtable clientWatchUserList
protected Hashtable idHostList
protected Hashtable entitiesclasses_extends
protected static EntityResult testRE
protected int port
protected String loginEntity
protected String idCardColumn
protected boolean useApplicationUser
protected int privilegedId
protected String logFile
protected String baseLogFileName
protected String fileLogExtension
protected int maximumLogFileSize
protected boolean isZipLogFile
protected Hashtable propertiesEntities
protected String entitiesClass
protected DefaultListModel userInfoListModel
protected int maximumSessionTime
protected int checkSessionsTime
protected boolean closedServer
protected boolean compressionEnabled
protected SecureReferenceLocator.LogStream logStreamOut
protected SecureReferenceLocator.LogStream logStreamErr
protected SecureReferenceLocator.UpdateListThread updateListThread
protected boolean logSessionEvents
protected FileWriter fileWriterLog
protected BufferedWriter buffWriterLog
protected String krealm
protected String kdc
protected String ldaphost
protected int ldapport
protected String domain
protected String jaasconfigfile
protected String userDNString
protected String searchUserString
protected String searchUser
protected String searchUserPassword
protected boolean ldapSSL
protected List reportEntities
protected String attachmentEntity
protected String attachmentPath
protected String printingTemplatesEntity
protected RemoteApplicationPreferences rPrefs
protected boolean encrypt
protected String pathProperties
protected static String defaultNoticeEntityClass
protected static String defaultNoticeDestinyEntityClass
public static String NOTICE_ENTITY_NAME
public static String NOTICE_ENTITY_DESTINY_NAME
protected String noticesPath
protected boolean noticeSystem
public static final String CA_CERTIFICATES_PROP
public static final String CRL_CERTIFICATES_PROP
public static final String ALLOW_CERTIFICATE_LOGIN
public static final String SSO_CONFIG_FILE
protected String ssoconfigfile
protected static boolean allowSSOLogin
public static final String LOCALE_ENTITY
public static final String LOCALE_SUFFIX
protected static final String CONTROL_ACCESS_ATTEMPTS
protected static final String NUMBER_ACCESS_ATTEMPTS
protected String localeEntity
protected String localeSuffix
protected boolean controlAccessAttempt
protected int numberAccessAttemps
protected ErrorAccessControl errorAccessControl
protected boolean multiConnectionManager
protected TimeZone serverTimeZone
protected String multiConnectionManagerPath
protected SecureReferenceLocator.TWatchDog watchDog
public static final String REMOTE_REFERENCES_ELEMENT
public static final String REMOTE_REFERENCE_ELEMENT
protected static final String PARAM_ELEMENT
protected static final String NAME_ELEMENT
protected static final String CLASS_ELEMENT
protected static final String VALUE_ELEMENT
public static final String REFERENCES_ELEMENT
public static final String REFERENCE_ELEMENT
protected StringBuffer logBuffer
protected int logBufferSize
protected com.ontimize.locator.SecureReferenceLocator.MessagesBuffer messagesBuffer
protected com.ontimize.locator.SecureReferenceLocator.MessagesBuffer remoteAdministrationMessagesBuffer
protected List remoteStoreList
protected LCMS lcms
protected String xmlDynamicMenu
protected String xmlDynamicToolbar
protected RemoteOperationManager rOperationManager
protected ISSOServer ssoServer
protected Map<String,String> temporaryUsersPasswords
public static long TEMPORARY_PASSWORDS_DURATION
public SecureReferenceLocator(int port,
Hashtable params)
throws Exception
port - params - Parameters: ServerMonitor does it if it
is specified.TableEntity class and will be automatically generated.
Each line in this file represents one entity. File format is:
"entity_name entity_properties_path"
LDAP {
com.sun.security.auth.module.Krb5LoginModule required;
};
Exceptionpublic SecureReferenceLocator(DatabaseConnectionManager connectionManager, String entitiesPackage, int port, boolean uniqueSession, String loginEntity) throws Exception
Exceptionpublic SecureReferenceLocator(DatabaseConnectionManager databaseManager, String entitiesPackage, int port) throws Exception
Exceptionpublic SecureReferenceLocator(DatabaseConnectionManager databaseManager, String entitiesPackage, int port, boolean uniqueSession) throws Exception
Exceptionpublic static boolean isAllowCertificateLogin()
public boolean isMultiConnectionManager()
public void setMultiConnectionManager(boolean multiConnectionManager)
@Deprecated protected DatabaseConnectionManager configureConnectionManager(boolean bStatisticViewer, URL dbPropertiesURL, URL autonumericalURL) throws Exception
bStatisticViewer - dbPropertiesURL - autonumericalURL - Exceptionprotected DatabaseConnectionManager createConnectionManager(boolean bStatisticViewer, URL dbPropertiesURL, URL autonumericalURL) throws Exception
Exceptionprotected DatabaseConnectionManager createConnectionManager(Hashtable databaseParams) throws Exception
Exceptionprotected DatabaseEntityManager createDatabaseEntityManager(Hashtable param) throws Exception
param - Exceptionprotected void configureRemoteReferences(String xmlDefinitionResource)
<RemoteReferences>
<RemoteReference>
<Name>name</Name>
<Class>className</Class>
<Param>
<Name>paramName1</Name>
<Value>paramValue1</Value>
</Param>
<Param>
<Name>paramName2</Name>
<Value>paramValue2</Value>
</Param>
</RemoteReference>
</RemoteReferences>
xmlDefinitionResource - resource path where is loaded the xml definition in.protected void configureModuleRemoteReferences()
protected void configureRemoteReference(Node currentNode) throws Exception
Exceptionprotected void configureReferences(String xmlDefinitionResource)
<References>
<Reference>
<Name>name</Name>
<Class>className</Class>
<Param>
<Name>paramName1</Name>
<Value>paramValue1</Value>
</Param>
<Param>
<Name>paramName2</Name>
<Value>paramValue2</Value>
</Param>
</Reference>
</References>
xmlDefinitionResource - resource path where is loaded the xml definition in.protected void configureReference(Node currentNode) throws Exception
Exceptionprotected void configureMultiConnectionManager()
public Entity getEntityReference(String entityName) throws Exception
getEntityReference in interface EntityReferenceLocatorentityName - Entity nameExceptionpublic int getSessionId()
getSessionId in interface EntityReferenceLocatorpublic Entity getEntityReferenceFromServer(String entityName)
ServerReferenceLocatorgetEntityReferenceFromServer in interface ServerReferenceLocatorentityName - Entity nameprotected Entity getEntity(String entityName)
entityName - getEntity(String, boolean)protected Entity getEntity(String entityName, boolean checkDataBase)
entityName - Name of the entitycheckDataBase - If true then it checks if this entity name exists in the
database, only if database entities provider has been
configuredprotected Entity createEntity(String sEntityClass, DatabaseConnectionManager entityConnectionManager, int port, String props) throws Exception
Exceptionprotected Entity loadEntity(String entityName, boolean checkDatabase, DatabaseConnectionManager entityConnectionManager) throws Exception
checkDatabase is true it searches the properties in the
database. Secondly it search the entity name in the entities properties
file and if it exists then creates a default entity object. At last, if
entity has not been created yet then use the name of the entity to search
for a class with the same name and uses this class.entityName - Name of the entitycheckDatabase - If this is true then use the database to search for the
properties, the class name and the alias to configure the
entityentityConnectionManager - DatabaseConnectionManager configured for this entity
nameExceptionpublic void removeEntity(String entityName, int sessionId) throws Exception
removeEntity in interface UtilReferenceLocatorExceptionpublic void removeEntity(String entityName) throws Exception
removeEntity in interface ServerReferenceLocatorExceptionpublic List getLoadedEntities()
getLoadedEntities in interface ServerReferenceLocatorpublic List getLoadedEntities(int sessionId) throws Exception
getLoadedEntities in interface UtilReferenceLocatorExceptionpublic Entity getEntityReference(String entityName, String user, int id) throws Exception
SecureEntityReferenceLocatorEntityReferenceLocator.getEntityReference(String) and gets entity
references with securitygetEntityReference in interface SecureEntityReferenceLocatorentityName - Requested entity nameuser - Name of the user who is asking for the referenceid - Session identifier for the user who is asking the referenceExceptionpublic int startSession(String user, String password, ClientWatch clientWatch) throws Exception
EntityReferenceLocatorstartSession in interface EntityReferenceLocatoruser - User namepassword - User passwordclientWatch - Object to checks if this session is openExceptionprotected void setDefaultLocaleId(int sessionId)
protected Certificate getCertificateFromText(String certText) throws Exception
Exceptionprotected boolean isValidCertificateText(String certText)
protected int startCertificateSession(String user, String password, ClientWatch clientWatch) throws Exception
user - Application userpassword - Application password or when is certificated corresponds with
certificate content.clientWatch - Exception - When locator throws invalid session Exceptionprotected int startSessionInner(String user, String password, ClientWatch clientWatch) throws Exception
Exceptionpublic void endSession(int id)
throws Exception
EntityReferenceLocatorendSession in interface EntityReferenceLocatorid - Client session identifierExceptionpublic EntityResult testConnectionSpeed(int sizeInBytes, boolean compressed) throws Exception
ConnectionOptimizertestConnectionSpeed in interface ConnectionOptimizerExceptionpublic void setDataCompressionThreshold(String user, int sessionId, int compressionThreshold)
setDataCompressionThreshold in interface ConnectionOptimizeruser - User namesessionId - User session identifiercompressionThreshold - Compression threshold valueprotected void updateListInfo(Integer id)
protected boolean localAuthenticate(Exception e)
public int getDataCompressionThreshold(int sessionId)
ConnectionOptimizergetDataCompressionThreshold in interface ConnectionOptimizersessionId - User session identifierpublic void setSessionIdLastAccessTime(long time,
int sessionId)
public boolean hasSession(int sessionId)
public boolean hasSession(String user, int sessionId) throws Exception
SecureEntityReferenceLocatorhasSession in interface SecureEntityReferenceLocatorExceptionpublic String startAdministrationRemoteSession(String user, String password) throws Exception
RemotelyManageablestartAdministrationRemoteSession in interface RemotelyManageableuser - String with the user.password - String with the password.String with the administrator id of the remote
session.Exceptionprotected String startTemporalAdminitrationSession(String user, String password) throws Exception
Exceptionpublic boolean closeSession(String id, int sessionId) throws Exception
RemotelyManageablecloseSession in interface RemotelyManageableid - String with the administrator id of the remote session.sessionId - int with the session id of the user's session.boolean with the result of the operation.Exceptionpublic Hashtable getStartSessionTime(String id) throws Exception
RemotelyManageablegetStartSessionTime in interface RemotelyManageableid - String with the administrator id of the remote session.Hashtable with the values.Exceptionpublic Hashtable getUserIds(String id) throws Exception
RemotelyManageablegetUserIds in interface RemotelyManageableid - String with the administrator id of the remote session.Hashtable with the user's IDs.Exceptionpublic List getConnectedUsers(int sessionId) throws Exception
getConnectedUsers in interface UtilReferenceLocatorExceptionpublic List getConnectedSessionIds(int sessionId) throws Exception
getConnectedSessionIds in interface UtilReferenceLocatorExceptionpublic IRemoteLogManager getRemoteLogManager(String id) throws Exception
getRemoteLogManager in interface RemotelyManageableExceptionpublic void freeServerResources()
public void closeServer(Frame fAux)
public void closeServer()
public void stopServer(String id) throws Exception
stopServer in interface RemotelyManageableExceptionpublic void restartServer(String id) throws Exception
restartServer in interface RemotelyManageableExceptionpublic void finishAdministrationRemoteSession(String id) throws Exception
RemotelyManageablefinishAdministrationRemoteSession in interface RemotelyManageableid - String with the administrator id of the remote session.Exceptionpublic ListModel getUserInfoListModel()
public DatabaseConnectionManager getConnectionManager()
public void setCompressionEnabled(boolean enabled)
public void closeSession(int sessionId)
protected void forceFinishSession(int sessionId)
public static int generatePrivilegedId()
public String getLogFile()
protected void checkLogFileChange(int bytesToWriteCount)
protected int getNextLogFileIndex(File fileLog)
#zipLogFile(String) when
isZipLogFile enabled.protected File zipLogFile(File directory, String logFilePath)
.zip fileprotected void flushLogBuffer()
public String getLastNCharactersFromLogFile(int nCharacters) throws Exception
RemotelyManageablegetLastNCharactersFromLogFile in interface RemotelyManageablenCharacters - int with the number of characters that will be recovered.String with the characters of the log file.Exceptionpublic SessionInfo[] getSessionInfo(String id) throws Exception
RemotelyManageablegetSessionInfo in interface RemotelyManageableid - String with the administrator id of the remote session.SessionInfo[] with the information of the
sessions.Exceptionpublic Vector getMessages(int sessionIdTo, int sessionId) throws Exception
getMessages in interface UtilReferenceLocatorExceptionpublic Vector getRemoteAdministrationMessages(int sessionIdTo, int sessionId) throws Exception
getRemoteAdministrationMessages in interface UtilReferenceLocatorExceptionpublic void sendMessage(UtilReferenceLocator.Message message, String user, int sessionId) throws Exception
sendMessage in interface UtilReferenceLocatorExceptionpublic void sendMessage(String message, String user, int sessionId) throws Exception
sendMessage in interface UtilReferenceLocatorExceptionpublic void sendMessageToAll(String message, int sessionId) throws Exception
sendMessageToAll in interface UtilReferenceLocatorExceptionpublic void sendRemoteAdministrationMessages(String message, int sessionId) throws Exception
sendRemoteAdministrationMessages in interface UtilReferenceLocatorExceptionpublic Entity getAttachmentEntity(int sessionId) throws Exception
getAttachmentEntity in interface UtilReferenceLocatorExceptionpublic Entity getPrintingTemplateEntity(int sessionId) throws Exception
getPrintingTemplateEntity in interface UtilReferenceLocatorExceptionpublic String getSerial(String userAdmin, String password) throws Exception
Exceptionpublic boolean ping()
throws Exception
RemotelyManageableping in interface RemotelyManageableExceptionpublic List getRemoteReportStore(int sessionId) throws Exception
getRemoteReportStore in interface RemoteReportReferencerExceptionpublic void addRemoteReportStore(ReportStore rs) throws Exception
Exceptionpublic List getReportEntityNames(int sessionId) throws Exception
getReportEntityNames in interface RemoteReportReferencerExceptionpublic RemoteApplicationPreferences getRemoteApplicationPreferences(int sessionId) throws Exception
getRemoteApplicationPreferences in interface RemoteApplicationPreferenceReferencersessionId - User session identifierExceptionpublic Hashtable getParameters(String login, String password) throws Exception
getParameters in interface RemoteLControlAdministrationExceptionpublic Hashtable updateL(Hashtable h, String login, String password) throws Exception
updateL in interface RemoteLControlAdministrationExceptionpublic boolean ok(String login, String password) throws Exception
ok in interface RemoteLControlAdministrationExceptionpublic boolean ok(int sessionId)
throws Exception
public boolean isDevelopementL(int sessionId)
throws Exception
isDevelopementL in interface RemoteLOkExceptionpublic String getLContent(int sessionId) throws Exception
getLContent in interface RemoteLOkExceptionpublic Object getLInfoObject(int sessionId) throws Exception
getLInfoObject in interface RemoteLOkExceptionpublic void sendNotice(Hashtable messageValues, int sessionId, boolean request) throws Exception
INoticeSystemsendNotice in interface INoticeSystemrequest - If this is true, the notices is a request notice. In this case
the correct template must be selectedExceptionpublic EntityResult getInternalNotices(int sessionId, boolean unsend, boolean unread, boolean deleted) throws Exception
INoticeSystemgetInternalNotices in interface INoticeSystemsessionId - User session identifierunsend - When this is true only return the unsend noticesunread - When this is true ontly return the unread noticesExceptionpublic void setNoticesRead(int sessionId,
Vector idNotices)
throws Exception
INoticeSystemsetNoticesRead in interface INoticeSystemsessionId - User session identifieridNotices - Array with the notice keysExceptionpublic EntityResult getSentNotices(int sessionId, Boolean deleted) throws Exception
INoticeSystemgetSentNotices in interface INoticeSystemsessionId - User session identifierdeleted - deleted = true only query the deleted notices Exceptionpublic void checkNoticeSent(int sessionId,
Object noticeKey)
throws Exception
INoticeSystemcheckNoticeSent in interface INoticeSystemsessionId - User session identifiernoticeKey - Notice key.Exceptionpublic void removeSentNotices(int sessionId,
Vector idNotices)
throws Exception
INoticeSystemremoveSentNotices in interface INoticeSystemsessionId - User session identifieridNotices - Keys of the notices to removeExceptionpublic void removeReceivedNotices(int sessionId,
Vector idNotices)
throws Exception
INoticeSystemremoveReceivedNotices in interface INoticeSystemsessionId - User session identifieridNotices - Notice keysExceptionpublic Vector getNoticeTypes() throws Exception
INoticeSystemgetNoticeTypes in interface INoticeSystemExceptionpublic String getNoticeEntityName()
INoticeSystemgetNoticeEntityName in interface INoticeSystempublic String getNoticeEntityDestinyName()
INoticeSystemgetNoticeEntityDestinyName in interface INoticeSystempublic EntityResult getNewMailNotice() throws Exception
INoticeSendMailsgetNewMailNotice in interface INoticeSendMailsExceptionpublic void checkNoticeAsSend(Object noticeKey) throws Exception
INoticeSendMailscheckNoticeAsSend in interface INoticeSendMailsnoticeKey - Notice keyExceptionpublic Object getUserId(int sessionId) throws Exception
INoticeSystemgetUserId in interface INoticeSystemsessionId - User session identifierExceptionpublic void reloadXMLMenu(int userid)
throws Exception
reloadXMLMenu in interface XMLClientProviderExceptionpublic String getXMLMenu(int userid) throws Exception
getXMLMenu in interface XMLClientProviderExceptionpublic void reloadXMLToolbar(int userid)
throws Exception
reloadXMLToolbar in interface XMLClientProviderExceptionpublic String getXMLToolbar(int userid) throws Exception
getXMLToolbar in interface XMLClientProviderExceptionpublic Hashtable getFormManagerParameters(String formManagerId, int userid) throws Exception
getFormManagerParameters in interface XMLClientProviderExceptionpublic String getXMLForm(String form, int userid) throws Exception
getXMLForm in interface XMLFormProviderExceptionpublic BytesBlock getImage(String image, int userId) throws Exception
getImage in interface XMLClientProviderExceptionpublic String getXMLRules(String form, int userid) throws Exception
getXMLRules in interface XMLClientProviderExceptionpublic RemoteOperationManager getRemoteOperationManager(int sessionId) throws Exception
getRemoteOperationManager in interface UtilReferenceLocatorExceptionpublic String getDefaultPackage()
public Object getRemoteReference(String name, int sessionId) throws Exception
UtilReferenceLocatorgetRemoteReference in interface UtilReferenceLocatorExceptionSecureReferenceLocator#configureRemoteReferences(String)}protected Object createRemoteReference(String className, Hashtable parameters) throws Exception
Exceptionprotected Object createReference(String className, Hashtable parameters) throws Exception
Exceptionpublic Object getReference(String name) throws Exception
ServerReferenceLocatorgetReference in interface ServerReferenceLocatorname - The name of reference defined in 'references.xml' file.Exception - when something fails.public TimeZone getServerTimeZone(int sessionId) throws Exception
UtilReferenceLocatorgetServerTimeZone in interface UtilReferenceLocatorExceptionpublic String getLoginEntityName(int sessionId) throws Exception
UtilReferenceLocatorgetLoginEntityName in interface UtilReferenceLocatorExceptionpublic boolean getDEBUGValueRemote(String id, String v) throws Exception
RemotelyManageablegetDEBUGValueRemote in interface RemotelyManageableid - String with the administrator id of the remote session.v - String with the name of the variable.boolean with the value of the indicated variable.Exceptionpublic void setDEBUGValueRemote(String id, String v, boolean b) throws Exception
RemotelyManageablesetDEBUGValueRemote in interface RemotelyManageableid - String with the administrator id of the remote session.v - String with the name of the variable.b - Boolean with the value.Exceptionpublic Hashtable getSystemInfo(String id, String key) throws Exception
RemotelyManageable
| key | meaning |
| CONNECTION_INFO | To get the connection information when exist only one connection. |
| IS_MULTICONNECTION | To know if multiconnection is available. Returns a String "true" or "false". |
| MULTICONNECTION_IDLIST | To get the list of Strings with the identification of the connections. |
| MULTICONNECTION_INFO | To get the connection information of all connections available. |
NOTE: the connection information contains into the Hashtable returned is:
getSystemInfo in interface RemotelyManageableid - String with the administrator id of the remote session.key - String indicating what information you wish to request.Hashtable with the values.Exceptionpublic void removeEntity(String id, String entityName) throws Exception
removeEntity in interface RemotelyManageableExceptionprotected Hashtable getConnectionInfo(DatabaseConnectionManager dBManager)
| key | value | meaning |
| nConnections | Integer | the number of connections |
| nLockedConnections | Integer | the number of locked connections |
| nLockTime | Double | the amount of locked time |
| tMaxLock | Double | the maximum locked time |
dBManager - The DatabaseConnectionManager.Hashtable with the values.public Properties getRemotePreferencesFile(String id) throws Exception
RemotelyManageablegetRemotePreferencesFile in interface RemotelyManageableid - String with the administrator id of the remote session.Properties with the preferences.Exceptionpublic void setRemotePreferencesFile(String id, Properties prop) throws Exception
RemotelyManageablesetRemotePreferencesFile in interface RemotelyManageableid - String with the administrator id of the remote session.prop - The properties file to be established. This file will contain
the structure of pair values: key-value.Exceptionpublic void closeLockedConnections(String id, String databaseId) throws Exception
closeLockedConnections in interface RemotelyManageableExceptionpublic String getToken() throws Exception
getToken in interface UtilReferenceLocatorExceptionpublic String getUserFromCert(String certificate) throws Exception
getUserFromCert in interface UtilReferenceLocatorExceptionpublic String getPasswordFromCert(String certificate) throws Exception
getPasswordFromCert in interface UtilReferenceLocatorException5.2057EN-1.4 this method returned the password from
cert., 5.2061EN returns the same value passed as parameter
because password ( = the certificate text) is not checked in
database, only certificate is validated in
startSessionInner(String, String, ClientWatch).protected String getUserFromCert(Certificate cert)
CertificateUtils.DNIe_CN.cert - Certificateprotected String getPasswordFromCert(Certificate cert)
CertificateUtils.DNIe_SERIALNUMBER
field.cert - Certificatepublic InitialContext retrieveInitialContext(int sessionId, Hashtable params) throws Exception
retrieveInitialContext in interface UtilReferenceLocatorExceptionpublic String getServerServiceName(String clientName) throws Exception
getServerServiceName in interface ISSOServerExceptionpublic byte[] returnMessage(String contextRef, byte[] inData) throws Exception
returnMessage in interface ISSOServerExceptionpublic Hashtable getConfigurationParameters(String clientName) throws Exception
getConfigurationParameters in interface ISSOServerExceptionpublic String getTemporaryPassword(String user)
public Locale getLocale(int sessionId) throws Exception
getLocale in interface UtilReferenceLocatorExceptionpublic void setLocale(int sessionId,
Locale locale)
throws Exception
setLocale in interface UtilReferenceLocatorExceptionpublic Object getLocaleId(int sessionId) throws Exception
getLocaleId in interface ServerReferenceLocatorExceptionpublic String getSuffixString()
getSuffixString in interface UtilReferenceLocatorpublic String getLocaleEntity() throws Exception
getLocaleEntity in interface UtilReferenceLocatorExceptionpublic boolean supportChangePassword(String user, int sessionId) throws Exception
supportChangePassword in interface UtilReferenceLocatorExceptionpublic EntityResult changePassword(String password, int sessionId, Hashtable av, Hashtable kv) throws Exception
changePassword in interface UtilReferenceLocatorExceptionpublic boolean getAccessControl()
throws Exception
getAccessControl in interface UtilReferenceLocatorExceptionpublic ErrorAccessControl getErrorAccessControl() throws Exception
getErrorAccessControl in interface UtilReferenceLocatorExceptionpublic void blockUserDB(String user) throws Exception
blockUserDB in interface UtilReferenceLocatorExceptionpublic boolean checkBlockUserDB(String user) throws Exception
checkBlockUserDB in interface UtilReferenceLocatorExceptionCopyright © 2016 Imatia Innovation S.L.. All rights reserved.