The documentation makes it clear that CAS provides first-class support for enabling HTTP access control (CORS). However, is it enabled by default or the setup needs to be done? I am working on a web application where client side Angular code is trying to access a server api on another domain. The server itself has CORS enabled. The communication was working fine without any security. As soon as I introduced CAS single sign-on into the mix, I got the following error:
Failed to load https://myCasServer.com/?service=http%3A%2F%2Flocalhost%3A8080%2Fauthenticate: Redirect from 'https://myCasServer.com/?service=http%3A%2F%2Flocalhost%3A8080%2Fauthenticate' to 'http://myCasServer.com/login?service=http%3A%2F%2Flocalhost%3A8080%2Fauthenticate' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'null' is therefore not allowed access.
There are NO Access-Control-Allow-Origin headers in the response. I am using Cas 2.0