I am not able to understand what's going on. On one of the env. of my webapp (written using ExtJS 4.0) - I see the login request successfully completes but subsequent request fails with 401.
When digged a bit more I found in Browser(F12) that 1st request's response header has JSESSIONID, which is set as a cookie, but 2nd request doesn't send it in its request headers. That's why 2nd request creates a new session and returns a new JSESSIONID.
In the client code where request is sent,Ext.Ajax.request({url:'', callback..})
- there is NO explicit setting of JSessionId or any cookie.
Strange part is NOT ALL cookie keys are missing, only JSESSIONID, that means cookies are not disabled and set by browser.
Why is the browser not sending JSESSIONID? I tried this in firefox/chrome both.
Also this is happening only in my local env., QA env. of the webapp is working fine.
I figured it out myself.. this was the issue http://tomcat.apache.org/migration-7.html#Session_cookie_configuration
Thanks to all the people who spent time reading my question.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With