Single-sign-on is a key feature of the WSO2 Identity Server that enables users to access multiple applications using the same set of credentials. Additionally, the user can access all these applications without having to log into each and every one of them individually. For instance, if users log into application A, they would automatically have access to application B as well for the duration of that session without having to re-enter their credentials.
...
Tip | ||||||||||
---|---|---|---|---|---|---|---|---|---|---|
Tip: If you wish to change properties like the issuer ID, consumer URL and IdP URL, you can edit the travelocity.properties file found inside the
If you edit the travelocity.properties file, you must restart the Apache Tomcat server for the changes to take effect. |
...
Click Configure. The following form appears. The values entered in the screen below are configurations for the sample.
Register the new service provider by providing the following values. See Configuring Inbound Authentication for a Service Provider for more information on the fields available in this form.
Field Description Sample Value Issuer This is the entity ID for the SAML2 service provider
Info This value should be same as the
SAML2.SPEntityId
value specified inside thetravelocity.com/WEB-INF/classes/travelocity.properties
file.travelocity.com Assertion Consumer URLs This is the Assertion Consumer Service (ACS) URL of the service provider. The identity provider redirects the SAML2 response to this ACS URL. However, if the SAML2 request is signed and SAML2 request contains the ACS URL, the Identity Server will honor the ACS URL of the SAML2 request.
Info This value should be same as the
SAML2.AssertionConsumerURL
value mentioned inside thetravelocity.com/WEB-INF/classes/travelocity.properties
file.Enter this value: http://localhost:8080/travelocity.com/home.jsp and click Add. Default Assertion Consumer URL This must be the same value defined above. If you have defined multiple Assertion Consumer URLs, this value must be the same as the SAML2.AssertionConsumerURL
value mentioned inside thetravelocity.com/WEB-INF/classes/travelocity.properties
file as that is the default.NameID format The service provider and identity provider usually communicate with each other regarding a specific subject. That subject should be identified through a Name-Identifier (NameID) , which should be in some format so that It is easy for the other party to identify it based on the format. There are some formats that are defined by SAML2 specification. Enter the default value of this format (urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress ) urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress Certificate Alias This is used to validate the signature of SAML2 requests and is used to generate encryption. Select wso2carbon
Response Signing Algorithm Specifies the ‘SignatureMethod’ algorithm to be used in the ‘Signature’ element in POST binding. The default value can be configured in the <IS_HOME>/repository/conf/identity/identity.xml
file, in theSSOService
element withSAMLDefaultSigningAlgorithmURI
tag. If it is not provided, the default algorithm is RSASHA 1, at URI ‘http://www.w3.org/2000/09/xmldsig#rsasha1
’.http://www.w3.org/2000/09/xmldsig#rsa-sha1 Response Digest Algorithm Specifies the ‘DigestMethod’ algorithm to be used in the ‘Signature’ element in POST binding. The default value can be configured in the <IS_HOME>/repository/conf/identity/identity.xml
file, in theSSOService
element withSAMLDefaultDigestAlgorithmURI
tag. If it is not provided the default algorithm is SHA 1, at URI ‘http://www.w3.org/2000/09/xmldsig#sha1
’.http://www.w3.org/2000/09/xmldsig#sha1 Enable Response Signing This is used to sign the SAML2 Responses returned after the authentication process is complete.
Set as true by selecting the checkbox Enable Signature Validation in Authentication Requests and Logout Requests This specifies whether the identity provider must validate the signature of the SAML2 authentication request and the SAML2 logout request that are sent by the service provider. Set as true by selecting the checkbox Enable Assertion Encryption This defines whether the SAML2 assertion must be encrypted or not. Enable Single Logout Enable this to ensure that all sessions are terminated once the user signs out from one server. Set this as true by selecting the checkbox Enable Attribute Profile The Identity Server supports a basic attribute profile where the identity provider can include the user’s attributes in the SAML Assertions as an attribute statement. You can define the claims that must be included under service provider claim configurations. Also, once you select the “Include Attributes in the Response Always” checkbox, the identity provider always includes the attribute values related to selected claims in the SAML Attribute statement. Enable Audience Restriction You can define multiple audiences in the SAML Assertion. Configured audiences would be added into the SAML2 Assertion. Enable Recipient Validation The recipient attribute of a SAML assertion contains the service provider's Assertion Consumer Service (ACS) URL, and the Identity Server, by default, sends the registered service provider's ACS URL as the recipient.
Tip Tip: There can be situations where the same SAML assertion can be consumed by multiple service providers. A scenario where we use SAML2 Bearer Grant is one such example. In such a scenario the assertion consumer endpoints of all those intended service providers should be added as recipients. Enabling recipient validation allows you to do just that.
Enable IdP Initiated SSO The service provider is not required to send the SAML2 request when this is enabled. Do a GET request following this pattern:https://{Hostname}:{Port}/samlsso?spEntityID={SAML2 SSO Issuer name}
Note If your SAML2 SSO issuer has been configured in any other separate tenant other than super tenant, then you need to append thetenantDomain parameter as well.
If the tenant domain is
soasecurity.org
, the GET request would be as follows:https://localhost:9443/samlsso?spEntityID=travelocity.com&tenantDomain=soasecurity.org
https://localhost:9443/samlsso?spEntityID=travelocity.com
Enable IdP initiated SLO The Identity Server facilitates IdP initiated SAML2 single log out requests. The following parameters can be used with the IdP initiated SLO request:
- slo (mandatory parameter) - Must have the value “true” to mark the request as an IdP initiated log out request
- spEntityID (optional) - Value of the parameter should be the SAML issuer name as in “Issuer” field in the SAML service provider configuration UI.
returnTo (optional) - Value of the parameter should be the URL which needs to be redirected to, after the log out.
Note If this parameter is present in the request, then the ‘spEntityID’ parameter must also be present.
Since this needs to be a trusted location, the value that comes with the request must match with one of the assertion consumer URLs or returnTo ULRs of the service provider.
returnTo URL: https://localhost:8080/avs.com/slo
...