I have a servlet that receives a request for access to a Domino application in our network and then it posts a response back to the requestor. When my servlet receives the request, i pull a userid and password parameters out of the XML they are sending and I use this information to log them into the Domino site. I then send a response back to them with 1) a message saying that they are authenticated and 2) the URL of the Domino site that they have been authenticated with. The e-procurement site should then redirect their browser to this URL. All of this is working, but the redirect forces them to login again from the Domino default login screen. I get the login screen with a message saying “Your session with the server has expired or is invalid. Please type your user name and password”. The application resides on an SSL enabled server and the sesion is established in the following manner:
try {
NotesThread.sinitThread();
String args[] = new String[1];
args[0] = "-ORBEnableSSLSecurity";
diiopSession = NotesFactory.createSession("",args,un,pw);
db = diiopSession.getDatabase( "", theDB );
} catch (NotesException e) {
System.out.println("Couldn't get domino objects: " + e.text);
}
I can access the database object just fine from within the context of the servlet, however, access to the db / session only lasts as long as the servlet’s life, which is over by the time the user tries to access the site.
My question is: Can the session remain alive after the request/response cycle of my servlet or does the termination of the servlet kill any sessions that I have established in the servlet?
You might have questions about the way this all works, like “why don’t you just authenticate the user and then have the servlet redirect the user to the application?” This process is part of a larger process (Ariba e-procurement) and the request/response/site access cycle described above MUST happen in this way.
Anyway, thanks in advance for any responses. I’ll keep trying stuff in the memantime…