|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.ifeth.sehr.lib.AccessControl
Security class for access control of users to SEHR services (modules).
Some methods are static to be used as a 'simple function call' by other modules.
Field Summary | |
static java.util.logging.Logger |
Log
|
Constructor Summary | |
AccessControl()
|
Method Summary | |
static java.util.Hashtable |
checkLogin2SEHRZone(java.lang.String usrname,
java.lang.String passwd,
java.lang.String zone,
SEHRCfg cfg)
Check username and password to login at SEHR host (zone). |
static java.util.Hashtable |
checkLogin2SEHRZone(java.lang.String usrname,
java.lang.String passwd,
java.lang.String zone,
SEHRDataSource fbds)
Check username and password to login at SEHR host (zone). |
static int |
checkLogin2Service(int usrid,
java.lang.String login,
java.lang.String passwd,
java.lang.String pik)
Check username and password to login for a module of SEHR. |
static int |
checkLogin2Service(int usrid,
java.lang.String login,
java.lang.String passwd,
java.lang.String pik,
SEHRCfg cfg)
Check username and password to login for a module of SEHR. |
static int |
checkLogin2Service(int usrid,
java.lang.String login,
java.lang.String passwd,
java.lang.String pik,
SEHRDataSource fbds)
Check username and password to login for a module of SEHR. |
static int |
checklogin4module(java.lang.String login,
java.lang.String passwd,
java.lang.String pik)
Deprecated. Conceptional error on authentification! |
static int |
checklogin4module(java.lang.String login,
java.lang.String passwd,
java.lang.String pik,
SEHRCfg cfg)
Deprecated. Conceptional error on authentification! |
static int |
checklogin4module(java.lang.String login,
java.lang.String passwd,
java.lang.String pik,
SEHRDataSource fbds)
Deprecated. Conceptional error on authentification! |
static java.lang.String |
generateRandomPassword()
Generate a random password |
static boolean |
LogoutFromZone(java.util.Hashtable session,
SEHRDataSource fbds)
Logout from zone... |
static void |
main(java.lang.String[] args)
For testing purposes |
static boolean |
testSOAPConnection(SEHRCfg cfg)
Static method to be called from startup to check if the required SOAP service is running (by testing the axis service 'Version') |
static boolean |
VerifySessionByID(java.lang.String sessionid,
SEHRDataSource fbds)
This method checks if the given 'sessionid' is valid. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static java.util.logging.Logger Log
Constructor Detail |
public AccessControl()
Method Detail |
public static java.lang.String generateRandomPassword()
public static boolean testSOAPConnection(SEHRCfg cfg)
public static java.util.Hashtable checkLogin2SEHRZone(java.lang.String usrname, java.lang.String passwd, java.lang.String zone, SEHRCfg cfg)
usrname
- Check given username against registered 'usrname' of table
USR_MAINpublic static java.util.Hashtable checkLogin2SEHRZone(java.lang.String usrname, java.lang.String passwd, java.lang.String zone, SEHRDataSource fbds)
usrname
- Check given username against registered 'usrname' of table
USR_MAIN
HashMap object
Integer usrid: 0=Admin/root, >0 regular user, -1 error/not
allowed
String sessionid
public static boolean VerifySessionByID(java.lang.String sessionid, SEHRDataSource fbds)
public static boolean LogoutFromZone(java.util.Hashtable session, SEHRDataSource fbds)
This method closes the current session of the user. To close the correct session the Hashtable object of the logon procedure is required.
public static int checkLogin2Service(int usrid, java.lang.String login, java.lang.String passwd, java.lang.String pik)
Important note:
The login procedure requires the module ID of the service application,
defined as "PIK".
The service to login may reside on another server connected to the healthnet. The 'link' to the other location is defined in table USR_SERVICES. But in any case the user has to be registered locally (in table USR_MAIN) for performing any login due to security aspects. This method calls a stored procedure that is handling this all.
Return Code Description:
0=ok, >0 or -1 not allowed
public static int checkLogin2Service(int usrid, java.lang.String login, java.lang.String passwd, java.lang.String pik, SEHRCfg cfg)
In this call the SEHRCfg is given as parameter to prevent recurrent reconfigurations
checkLogin2Service(int, String, String, String)
public static int checkLogin2Service(int usrid, java.lang.String login, java.lang.String passwd, java.lang.String pik, SEHRDataSource fbds)
In this call the SEHRDataSource itself is given as parameter to get the connection by this basic level object
checkLogin2Service(int, String, String, String)
public static int checklogin4module(java.lang.String login, java.lang.String passwd, java.lang.String pik)
public static int checklogin4module(java.lang.String login, java.lang.String passwd, java.lang.String pik, SEHRCfg cfg)
public static int checklogin4module(java.lang.String login, java.lang.String passwd, java.lang.String pik, SEHRDataSource fbds)
public static void main(java.lang.String[] args)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |