To enable it for one Origin, specify the full service URL in the
*allowOrigins[0]* property.  Example:

cas.httpWebRequest.cors.enabled:            true
cas.httpWebRequest.cors.allowCredentials:   true
cas.httpWebRequest.cors.allowOrigins[0]:    'full.url'

If you need to add an additional service:
cas.httpWebRequest.cors.allowOrigins[1]:    'next.full.url'

If you need to allow any service, you can set *allowOrigins[0]* to "*".
This will enable it for all services.  Note that you cannot use the star
like a wildcard, like '*.full.url'.

-Nick

--
Nathaniel N. Petersen
Systems Architect
IT - Administrative Information Systems
University of Northern Iowa


On Tue, Feb 26, 2019 at 3:20 PM Aaron Bennett <[email protected]> wrote:

> Greetings,
>
> We've got a need to enable the CORS headers in CAS.
>
> The document here:
> https://apereo.github.io/cas/5.2.x/installation/Configuration-Properties.html#http-web-requests
> shows how to enable them, but there's no explanation of what the following
> attributes mean:
>
> # cas.httpWebRequest.cors.enabled=false
> # cas.httpWebRequest.cors.allowCredentials=false
> # cas.httpWebRequest.cors.allowOrigins[0]=
> # cas.httpWebRequest.cors.allowMethods[0]=*
> # cas.httpWebRequest.cors.allowHeaders[0]=*
> # cas.httpWebRequest.cors.maxAge=3600
> # cas.httpWebRequest.cors.exposedHeaders[0]=
>
> We really only need this for one service.  Is there a way to enable it, or
> allow it, per-service? What do all of the other attribute represent?
>
> Thanks,
>
> Aaron Bennett
>
>
> ---
> Aaron Bennett
> Manager of Systems Administration
> Clark University ITS
>
>
> --
> - Website: https://apereo.github.io/cas
> - Gitter Chatroom: https://gitter.im/apereo/cas
> - List Guidelines: https://goo.gl/1VRrw7
> - Contributions: https://goo.gl/mh7qDG
> ---
> You received this message because you are subscribed to the Google Groups
> "CAS Community" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/a/apereo.org/d/msgid/cas-user/BN6PR03MB3169D7496166D5A91F1A1133A17B0%40BN6PR03MB3169.namprd03.prod.outlook.com
> .
>

-- 
- Website: https://apereo.github.io/cas
- Gitter Chatroom: https://gitter.im/apereo/cas
- List Guidelines: https://goo.gl/1VRrw7
- Contributions: https://goo.gl/mh7qDG
--- 
You received this message because you are subscribed to the Google Groups "CAS 
Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/a/apereo.org/d/msgid/cas-user/CAAWVSYRN-O_cN6LfXvH1aGPHOz7m3BNQQFbdcDyJ6hXE2x9CKQ%40mail.gmail.com.

Reply via email to