|
EAF 7.6 Implementation | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjava.lang.Thread
com.lutris.appserver.server.sessionEnhydra.StandardSessionKeyGen
public class StandardSessionKeyGen
The session random key generator. This class implements a background thread
that wakes up and counts the number of Standard Session Manager requests
completed at one or more different interval periods, and
supplements the seed of the Manager's random number generator
in order to make the value of the cookies extremely unpredictable.
This is an absolute requirement if random cookie values are to
be used for any type of security purpose.
This random number generator uses the JDK 1.1 SecureRandom
object, which implements a cryptographic grade random number
generator based on the RSA MD5 one-way hash. In combination with
external user-generated time delay information, the numbers
generated by this object are highly unpredictable, and therefore
suitably secure for their use as session keys.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class java.lang.Thread |
---|
java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler |
Field Summary |
---|
Fields inherited from class java.lang.Thread |
---|
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
Constructor Summary | |
---|---|
StandardSessionKeyGen(long[] intervals)
Constructor a new key generator random number entropy generator. |
Method Summary | |
---|---|
void |
incrementRandomCounter()
Increment the random counter. |
java.lang.String |
newSessionKey()
Generates a new random key to identify a session. |
void |
run()
The main code body of the Idle Timer Thread. |
void |
shutdown()
Shutdown the thread associated with this object. |
Methods inherited from class java.lang.Thread |
---|
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public StandardSessionKeyGen(long[] intervals)
manager
- The Standard session manager to be randomized.intervals
- An array of one or more intervals, in seconds
in which to periodically supplement the random number
generator with external user-generated entropy.Method Detail |
---|
public void run()
run
in interface java.lang.Runnable
run
in class java.lang.Thread
public void incrementRandomCounter()
public java.lang.String newSessionKey()
randomizer
object is
used to generate this key.This function is reentrant and does not need synchronization.
public void shutdown()
|
EAF 7.6 Implementation | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |