Class RandomSessionIdGenerator
java.lang.Object
org.apache.shiro.session.mgt.eis.RandomSessionIdGenerator
- All Implemented Interfaces:
SessionIdGenerator
Generates session IDs by using a
Random instance to generate random IDs. The default Random
implementation is a SecureRandom with the SHA1PRNG algorithm.- Since:
- 1.0
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongenerateId(Session session) Returns the String value of the configuredRandom'snextLong()invocation.void
-
Constructor Details
-
RandomSessionIdGenerator
public RandomSessionIdGenerator()
-
-
Method Details
-
getRandom
-
setRandom
-
generateId
Returns the String value of the configuredRandom'snextLong()invocation.- Specified by:
generateIdin interfaceSessionIdGenerator- Parameters:
session- theSessioninstance to which the ID will be applied.- Returns:
- the String value of the configured
Random'sRandom.nextLong()invocation.
-