| 36 | |
| 37 | === [[IdPSetup|Failover connectors]] === |
| 38 | |
| 39 | If a !DataConnector fails in attribute resolution - for example, if the connection to the server fails because the server is off-line, or connection is refused due to expired credentials or invalid SSL certificate - attribute resolution is aborted, even if attributes were successfully retrieved using other !DataConnectors. To minimize the impact of such connection failures, include failover in the !DataConnector definition. |
| 40 | {{{ |
| 41 | <!-- LDAP Connector to edir, a multi-node cluster of LDAP directories --> |
| 42 | <resolver:DataConnector id="myLDAP" xsi:type="LDAPDirectory" xmlns="urn:mace:shibboleth:2.0:resolver:dc" |
| 43 | ldapURL="ldaps://edir.alaska.edu:636" baseDN="ou=people,dc=alaska,dc=edu" |
| 44 | principal="uid=shibboleth03,ou=resource,dc=alaska,dc=edu" principalCredential="shibboleth+20090303"> |
| 45 | <resolver:FailoverDataConnector ref="FailoverStaticConnector" /> |
| 46 | <FilterTemplate> |
| 47 | <![CDATA[ |
| 48 | (|(uid=$requestContext.principalName)(uasystemid=$requestContext.principalName)(bannerid=$requestContext.principalName)) |
| 49 | ]]> |
| 50 | </FilterTemplate> |
| 51 | </resolver:DataConnector> |
| 52 | |
| 53 | <!-- Primary UA AD server using Global Catalog search per https://wiki.shibboleth.net/confluence/display/SHIB2/LdapServerIssues --> |
| 54 | <resolver:DataConnector id="uaADLDAP" xsi:type="LDAPDirectory" xmlns="urn:mace:shibboleth:2.0:resolver:dc" |
| 55 | ldapURL="ldaps://fbk-adua01.ua.ad.alaska.edu:3269" baseDN="ou=useraccounts,dc=ua,dc=ad,dc=alaska,dc=edu" |
| 56 | principal="cn=uashib,ou=uaf_service,ou=uaf,dc=ua,dc=ad,dc=alaska,dc=edu" principalCredential="lkjhyuio87"> |
| 57 | <resolver:FailoverDataConnector ref="FailoverADConnector" /> |
| 58 | <FilterTemplate> |
| 59 | <![CDATA[ |
| 60 | (|(sAMAccountName=$requestContext.principalName)(uaIdentifier=$requestContext.principalName)) |
| 61 | ]]> |
| 62 | </FilterTemplate> |
| 63 | </resolver:DataConnector> |
| 64 | <!-- Failover to unencrypted LDAP on second AD node; retrieve public attributes even if certificate issue prevents ldaps connection --> |
| 65 | <resolver:DataConnector id="FailoverADConnector" xsi:type="LDAPDirectory" xmlns="urn:mace:shibboleth:2.0:resolver:dc" |
| 66 | ldapURL="ldap://fbk-adua02.ua.ad.alaska.edu:389" baseDN="ou=useraccounts,dc=ua,dc=ad,dc=alaska,dc=edu" |
| 67 | principal="cn=uashib,ou=uaf_service,ou=uaf,dc=ua,dc=ad,dc=alaska,dc=edu" principalCredential="lkjhyuio87"> |
| 68 | <resolver:FailoverDataConnector ref="FailoverStaticConnector" /> |
| 69 | <FilterTemplate> |
| 70 | <![CDATA[ |
| 71 | (|(sAMAccountName=$requestContext.principalName)(uaIdentifier=$requestContext.principalName)) |
| 72 | ]]> |
| 73 | </FilterTemplate> |
| 74 | </resolver:DataConnector> |
| 75 | |
| 76 | <!-- Last resort to avoid DataConnector failure & aborted resolution: provide generic attributes --> |
| 77 | <resolver:DataConnector id="FailoverStaticConnector" xsi:type="Static" xmlns="urn:mace:shibboleth:2.0:resolver:dc"> |
| 78 | <Attribute id="eduPersonAffiliation"> |
| 79 | <Value>affiliate</Value> |
| 80 | <Value>member</Value> |
| 81 | </Attribute> |
| 82 | </resolver:DataConnector> |
| 83 | }}} |