If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

Applet -> Servlet Communication Losing Session ID Crossing Firewall

Hi All,

I'm baffled, somewhat new to Applet/Servlet work, and in need of some assistance.

My app has an applet front end and a servlet back end. The user first contacts the servlet, which writes an HTTP response back as an APPLET tag, passing the JSESSIONID as a PARAM tag for the applet. In the applet, I rewrite the server's URL and append ";jsessionid=[the session id]" before using the URL to communicate via a URLConnection, so that the server knows that this is still the same session.

This works fine as long as everyone is on one side or the other of the firewall, but when I put the server behind the firewall, trying to talk to it from outside the firewall fails (HTTP error 500, i.e. the server messed up.) Upon debugging, I noticed that the requestedSessionID is null, where it normally picks up the session id I supply in the APPLET tag.

My network keepers assure me that the firewall is not blocking cookies, there are no proxies or NATs or anything in the way, but I'm losing the jsessionid and as a result the server thinks that the reply from the applet is a request for a new session...which kills the app. Argh.

Does anyone have any ideas as to how I can figure out what is mangling my applet's requests across the firewall? Any information would be very much appreciated!

Rick,
Did you ever resolve the issue you had with the disappearing jsessionid? I seem to be having a similiar problem. My app runs on the phone and emulator. When running on the emulator behind my firewall, my sessionid is intact. But when running the app over particular phone, i lose my jsessionid. In particular t-mobile on a Sony K750i. Seems to work ok on a Sanyo M1 on Sprint. Not sure if it's carrier or phone related. It it could be my code. What did you discover?