Class ServerHttpSecurity.HttpBasicSpec
- java.lang.Object
-
- org.springframework.security.config.web.server.ServerHttpSecurity.HttpBasicSpec
-
- Enclosing class:
- ServerHttpSecurity
public final class ServerHttpSecurity.HttpBasicSpec extends java.lang.ObjectConfigures HTTP Basic Authentication- Since:
- 5.0
- See Also:
ServerHttpSecurity.httpBasic()
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ServerHttpSecurityand()Allows method chaining to continue configuring theServerHttpSecurityServerHttpSecurity.HttpBasicSpecauthenticationEntryPoint(ServerAuthenticationEntryPoint authenticationEntryPoint)Allows easily setting the entry point.ServerHttpSecurity.HttpBasicSpecauthenticationManager(ReactiveAuthenticationManager authenticationManager)TheReactiveAuthenticationManagerused to authenticate.protected voidconfigure(ServerHttpSecurity http)ServerHttpSecuritydisable()Disables HTTP Basic authentication.ServerHttpSecurity.HttpBasicSpecsecurityContextRepository(ServerSecurityContextRepository securityContextRepository)TheServerSecurityContextRepositoryused to save theAuthentication.
-
-
-
Method Detail
-
authenticationManager
public ServerHttpSecurity.HttpBasicSpec authenticationManager(ReactiveAuthenticationManager authenticationManager)
TheReactiveAuthenticationManagerused to authenticate. Defaults toServerHttpSecurity.authenticationManager(ReactiveAuthenticationManager).- Parameters:
authenticationManager- the authentication manager to use- Returns:
- the
ServerHttpSecurity.HttpBasicSpecto continue configuring
-
securityContextRepository
public ServerHttpSecurity.HttpBasicSpec securityContextRepository(ServerSecurityContextRepository securityContextRepository)
TheServerSecurityContextRepositoryused to save theAuthentication. Defaults toNoOpServerSecurityContextRepository. For theSecurityContextto be loaded on subsequent requests theReactorContextWebFiltermust be configured to be able to load the value (they are not implicitly linked).- Parameters:
securityContextRepository- the repository to use- Returns:
- the
ServerHttpSecurity.HttpBasicSpecto continue configuring
-
authenticationEntryPoint
public ServerHttpSecurity.HttpBasicSpec authenticationEntryPoint(ServerAuthenticationEntryPoint authenticationEntryPoint)
Allows easily setting the entry point.- Parameters:
authenticationEntryPoint- theServerAuthenticationEntryPointto use- Returns:
ServerHttpSecurity.HttpBasicSpecfor additional customization- Since:
- 5.2.0
-
and
public ServerHttpSecurity and()
Allows method chaining to continue configuring theServerHttpSecurity- Returns:
- the
ServerHttpSecurityto continue configuring
-
disable
public ServerHttpSecurity disable()
Disables HTTP Basic authentication.- Returns:
- the
ServerHttpSecurityto continue configuring
-
configure
protected void configure(ServerHttpSecurity http)
-
-