-
Notifications
You must be signed in to change notification settings - Fork 6.1k
Closed
Labels
in: saml2An issue in SAML2 modulesAn issue in SAML2 modulesstatus: backportedAn issue that has been backported to maintenance branchesAn issue that has been backported to maintenance branchestype: bugA general bugA general bug
Milestone
Description
Describe the bug
A call to saml2Login().relyingPartyRegistrationRepository(...).and() does not return a type that can be further configured with spring security.
To Reproduce
public class WebSecurityConfig extends WebSecurityConfigurerAdapter {
protected void configure(HttpSecurity http) throws Exception {
http
.saml2Login()
.relyingPartyRegistrationRepository(relyingPartyRegistrationRepository())
.and() // <-- A SecurityBuilder object is returned here instead of an HttpSecurity object
.logout(); // <-- fails due to incorrect object returned by and()
}
}
Note that relyingPartyRegistrationRepository appears to be the only saml configuration method that causes this problem.
I assume that this:
public Saml2LoginConfigurer relyingPartyRegistrationRepository(RelyingPartyRegistrationRepository repo) {
needs to be changed to this:
public Saml2LoginConfigurer<B> relyingPartyRegistrationRepository(RelyingPartyRegistrationRepository repo) {
Expected behavior
Ability to configure other non-saml http security properties after configuring saml2 relying party registry.
Metadata
Metadata
Assignees
Labels
in: saml2An issue in SAML2 modulesAn issue in SAML2 modulesstatus: backportedAn issue that has been backported to maintenance branchesAn issue that has been backported to maintenance branchestype: bugA general bugA general bug