public class SAMLContextProviderLBConfigurer extends org.springframework.security.config.annotation.SecurityConfigurerAdapter<Void,ServiceProviderBuilder>
SAMLContextProviderLB bean.
Common strategy across most internal configurers is to first give priority to a Spring Bean if present in the
Context. So if not SAMLContextProvider bean is defined, priority goes to a custom SAMLContextProvider
provided explicitly to this SAMLContextProviderConfigurer. And if not provided through the constructor, a
default implementation is instantiated.
This configurer also reads the values from SAMLSSOProperties#getContextProvider() and
SAMLContextProviderProperties#getLb() if no custom SAMLContextProvider or SAMLContextProviderLB
is provided. In other words, the user is able to configure the SAMLContextProvider through the
following properties:
saml.sso.context-provider.lb.scheme
saml.sso.context-provider.lb.server-name
saml.sso.context-provider.lb.include-server-port-in-request-url
saml.sso.context-provider.lb.server-port
saml.sso.context-provider.lb.context-path
| Constructor and Description |
|---|
SAMLContextProviderLBConfigurer() |
SAMLContextProviderLBConfigurer(org.springframework.security.saml.context.SAMLContextProviderLB samlContextProvider) |
| Modifier and Type | Method and Description |
|---|---|
void |
configure(ServiceProviderBuilder builder) |
SAMLContextProviderLBConfigurer |
contextPath(String contextPath)
Context path of the LB, must be starting with slash, e.g.
|
protected org.springframework.security.saml.context.SAMLContextProviderLB |
createDefaultSamlContextProviderLB() |
SAMLContextProviderLBConfigurer |
includeServerPortInRequestURL(boolean includeServerPortInRequestURL)
When true serverPort will be used in construction of LB requestURL.
|
void |
init(ServiceProviderBuilder builder) |
SAMLContextProviderLBConfigurer |
scheme(String scheme)
Scheme of the LB server - either http or https.
|
SAMLContextProviderLBConfigurer |
serverName(String serverName)
Server name of the LB, e.g.
|
SAMLContextProviderLBConfigurer |
serverPort(int serverPort)
Port of the server, in case value is <= 0 port will not be included in the requestURL and port
from the original request will be used for getServerPort calls.
|
public SAMLContextProviderLBConfigurer()
public SAMLContextProviderLBConfigurer(org.springframework.security.saml.context.SAMLContextProviderLB samlContextProvider)
public void init(ServiceProviderBuilder builder) throws Exception
init in interface org.springframework.security.config.annotation.SecurityConfigurer<Void,ServiceProviderBuilder>init in class org.springframework.security.config.annotation.SecurityConfigurerAdapter<Void,ServiceProviderBuilder>Exceptionpublic void configure(ServiceProviderBuilder builder) throws Exception
configure in interface org.springframework.security.config.annotation.SecurityConfigurer<Void,ServiceProviderBuilder>configure in class org.springframework.security.config.annotation.SecurityConfigurerAdapter<Void,ServiceProviderBuilder>Exceptionprotected org.springframework.security.saml.context.SAMLContextProviderLB createDefaultSamlContextProviderLB()
public SAMLContextProviderLBConfigurer scheme(String scheme)
Alternatively use property:
saml.sso.context-provider.lb.scheme
scheme - Scheme of the LB server - either http or https.public SAMLContextProviderLBConfigurer serverName(String serverName)
Alternatively use property:
saml.sso.context-provider.lb.server-name
serverName - Server name of the LB, e.g. www.myserver.com.public SAMLContextProviderLBConfigurer includeServerPortInRequestURL(boolean includeServerPortInRequestURL)
Alternatively use property:
saml.sso.context-provider.lb.include-server-port-in-request-url
includeServerPortInRequestURL - SWhen true serverPort will be used in construction of LB requestURL.public SAMLContextProviderLBConfigurer serverPort(int serverPort)
Alternatively use property:
saml.sso.context-provider.lb.server-port
serverPort - Port of the server, in case value is <= 0 port will not be included in the requestURL and port
from the original request will be used for getServerPort calls.public SAMLContextProviderLBConfigurer contextPath(String contextPath)
Alternatively use property:
saml.sso.context-provider.lb.context-path
contextPath - Context path of the LB, must be starting with slash, e.g. /saml-extension.Copyright © 2018. All rights reserved.