RT is configured to use CAS authentication. RT is behind nginx reverse proxy that does TLS.
Everything works as expected except accessing a ticket using an emailed URL in a form: domain/Ticket/Display.html?id=123
If the user is not authenticated yet, this link gets redirected to the CAS and after a successful login the user gets redirected back to the Display.html, but each AJAX request to Basics,Times,People resources gets redirected to CAS again. Because the user is already authenticated, all those resources get a 302 redirect back to the original RT urls but fail because of the CORS.
The solution is to hit the root of RT and after that when clicking a link in the email, everything works without problems - there is no redirect to CAS for each AJAX request for the Ticket/Display.html page.
What is the solution for this problem?
Thanks.