Either alter the TomCat source code or implement your own session-id's.
I use a combination of userid, sessionid and current time in msecs to create
a unique ID that I know is rather unlikely to be repeated. I use that ID for
mapping entries in databases.
The code I use is:
// generate timeInMillis
/***************************************************************************
*/
class TimeInMillis extends GregorianCalendar {
public long getTimeStarDate() {
getInstance();
long now;
int y = get(1);
now = getTimeInMillis();
return now;
}
}
Then in the doGet method, I do:
// let's generate a random number here
TimeInMillis gcToday = new TimeInMillis();
long time = gcToday.getTimeStarDate();
String uniqueID="" + time;
session.setAttribute("user.session.ID", (userId + "." +
session.getId() + "." + uniqueID));
This happens in the Login controller for my app. All apps read this value
from the session
/Christopher
> -----Original Message-----
> From: Michael [mailto:[EMAIL PROTECTED]]
> Sent: den 27 mars 2002 18:36
> To: [EMAIL PROTECTED]
> Subject: session-id
>
>
> Hi!
>
> (tomcat 3.3.1)
>
> How can I create my own session-ids???
>
> I want my session-id to be a 10 digit number ...
> or a 10 uppercase-character word ...
>
> thanks
> michi
>
--
To unsubscribe: <mailto:[EMAIL PROTECTED]>
For additional commands: <mailto:[EMAIL PROTECTED]>
Troubles with the list: <mailto:[EMAIL PROTECTED]>