Delegated Authentication
CAS can act as a client (i.e. service provider or proxy) using the Pac4j library and delegate the authentication to:
- CAS servers
- SAML2 identity providers
- OAuth2 providers such as Facebook, Twitter, GitHub, Google, LinkedIn, etc
- OpenID Connect identity providers such as Google, Apple
- ADFS
Support is enabled by including the following dependency in the WAR overlay:
1
2
3
4
5
<dependency>
<groupId>org.apereo.cas</groupId>
<artifactId>cas-server-support-pac4j-webflow</artifactId>
<version>${cas.version}</version>
</dependency>
1
implementation "org.apereo.cas:cas-server-support-pac4j-webflow:${project.'cas.version'}"
1
2
3
4
5
6
7
8
9
dependencyManagement {
imports {
mavenBom "org.apereo.cas:cas-server-support-bom:${project.'cas.version'}"
}
}
dependencies {
implementation "org.apereo.cas:cas-server-support-pac4j-webflow"
}
The following settings and properties are available from the CAS configuration catalog:
cas.authn.pac4j.core.groovy-provider-post-processor.location=
The location of the resource. Resources can be URLS, or files found either on the classpath or outside somewhere in the file system. In the event the configured resource is a Groovy script, specially if the script set to reload on changes, you may need to adjust the total number ofinotify instances. On Linux, you may need to add the following line to /etc/sysctl.conf : fs.inotify.max_user_instances = 256 . You can check the current value via cat /proc/sys/fs/inotify/max_user_instances .
|
cas.authn.pac4j.core.groovy-redirection-strategy.location=
The location of the resource. Resources can be URLS, or files found either on the classpath or outside somewhere in the file system. In the event the configured resource is a Groovy script, specially if the script set to reload on changes, you may need to adjust the total number ofinotify instances. On Linux, you may need to add the following line to /etc/sysctl.conf : fs.inotify.max_user_instances = 256 . You can check the current value via cat /proc/sys/fs/inotify/max_user_instances .
|
cas.authn.pac4j.core.discovery-selection.json.location=
The location of the resource. Resources can be URLS, or files found either on the classpath or outside somewhere in the file system. In the event the configured resource is a Groovy script, specially if the script set to reload on changes, you may need to adjust the total number ofinotify instances. On Linux, you may need to add the following line to /etc/sysctl.conf : fs.inotify.max_user_instances = 256 . You can check the current value via cat /proc/sys/fs/inotify/max_user_instances .
|
cas.authn.pac4j.core.discovery-selection.selection-type=MENU
Indicate how the selection and presentation of identity providers would be controlled. Available values are as follows:
|
cas.authn.pac4j.core.lazy-init=true
Whether initialization of delegated identity providers should be done eagerly typically during startup. |
cas.authn.pac4j.core.name=
The name of the authentication handler in CAS used for delegation. |
cas.authn.pac4j.core.order=
Order of the authentication handler in the chain. |
cas.authn.pac4j.core.principal-attribute-id=
The attribute to use as the principal identifier built during and upon a successful authentication attempt. |
cas.authn.pac4j.core.replicate-sessions=true
Indicates whether profiles and other session data, collected as part of pac4j flows and requests that are kept by the container session, should be replicated across the cluster using CAS and its own ticket registry. Without this option, profile data and other related pieces of information should be manually replicated via means and libraries outside of CAS. |
cas.authn.pac4j.core.typed-id-used=false
When constructing the final user profile from the delegated provider, determines if the provider id should be combined with the principal id. |