Polish Documentation

Changed indentation on saml2Login() snippets to align more closely
with surrounding documentation.

Also removed call to super.configure as this would enable formLogin as
well as httpBasic. Replaced with default endpoint authorization
statement.

Issue gh-7654
This commit is contained in:
Josh Cummings 2019-12-18 10:53:59 -07:00
parent c745889ae7
commit 40d4dce329
No known key found for this signature in database
GPG Key ID: 49EF60DD7FF83443
1 changed files with 12 additions and 6 deletions

View File

@ -258,10 +258,12 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter {
};
http
.authorizeRequests()
.anyRequest().authenticated()
.and()
.saml2Login()
.addObjectPostProcessor(processor)
;
super.configure(http);
}
}
----
@ -282,10 +284,12 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter {
authProvider.setAuthoritiesMapper(AUTHORITIES_MAPPER);
authProvider.setAuthoritiesExtractor(AUTHORITIES_EXTRACTOR);
http
.authorizeRequests()
.anyRequest().authenticated()
.and()
.saml2Login()
.authenticationManager(new ProviderManager(asList(authProvider)))
;
super.configure(http);
}
}
----
@ -305,10 +309,12 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter {
protected void configure(HttpSecurity http) throws Exception {
AuthenticationManager authenticationManager = new MySaml2AuthenticationManager(...);
http
.authorizeRequests()
.anyRequest().authenticated()
.and()
.saml2Login()
.authenticationManager(authenticationManager)
;
super.configure(http);
}
}
----