The sample application uses Spring Boot and the spring-security-saml2-service-provider module which is new in Spring Security 5.2. This shows how to integrate your spring-boot-saml application with WSO2 Identity Server
- The next step is to configure spring-boot-app as the service provider. The following steps instruct you on how to do this.
- Start the Identity Server and access the management console using https://localhost:9443/carbon/
- Log in to the Identity Server using default administrator credentials (the username and password are both "admin").
- In the management console found on the left of your screen, navigate to the Main menu and click Add under Service Provider.
- Expand the Inbound Authentication Configuration section and then expand SAML2 Web SSO Configuration.
Field | Value |
---|---|
Service Provider Name | sampleapp |
Issuer | http://localhost:8080/saml2/service-provider-metadata/wso2 |
Description | This is a spring-boot application secured with SAML using WSO2IS |
Assertion Consumer URL | http://localhost:8080/login/saml2/sso/wso2 |
- Add the following properties in application.properties file
spring.security.saml2.relyingparty.registration.wso2.signing.credentials[0].private-key-location={application-private-key}
spring.security.saml2.relyingparty.registration.wso2.signing.credentials[0].certificate-location={{application-public-key}
spring.security.saml2.relyingparty.registration.wso2.identityprovider.verification.credentials[0].certificate-location={public-key-of-IS}
spring.security.saml2.relyingparty.registration.wso2.identityprovider.entity-id={entity-id-of-is}
spring.security.saml2.relyingparty.registration.wso2.identityprovider.sso-url=https://{IS-HOST-NAME}:{IS-PORT}/samlsso