I am trying to integrate a very old Java web application and a AngularJs front end. I can't use Spring framework and basically have to code the pieces by hand. Here are my specific questions:
I post the login form to the servlet for authentication, the servlet replies with a permission object and a Jsessionid. How do I avoid re-login when I navigate away and come back to the page ? Do I need another cookie to store username/password?
How do I provide CSRF protection with this architecture ?
An example would be very highly appreciated.