public class AnonymousAuthenticationWebFilter
extends java.lang.Object
implements org.springframework.web.server.WebFilter
Authentication object in the
ReactiveSecurityContextHolder, and populates it with one if needed.| Constructor and Description |
|---|
AnonymousAuthenticationWebFilter(java.lang.String key)
Creates a filter with a principal named "anonymousUser" and the single authority
"ROLE_ANONYMOUS".
|
AnonymousAuthenticationWebFilter(java.lang.String key,
java.lang.Object principal,
java.util.List<org.springframework.security.core.GrantedAuthority> authorities) |
| Modifier and Type | Method and Description |
|---|---|
protected org.springframework.security.core.Authentication |
createAuthentication(org.springframework.web.server.ServerWebExchange exchange) |
reactor.core.publisher.Mono<java.lang.Void> |
filter(org.springframework.web.server.ServerWebExchange exchange,
org.springframework.web.server.WebFilterChain chain) |
public AnonymousAuthenticationWebFilter(java.lang.String key)
key - the key to identify tokens created by this filterpublic AnonymousAuthenticationWebFilter(java.lang.String key,
java.lang.Object principal,
java.util.List<org.springframework.security.core.GrantedAuthority> authorities)
key - key the key to identify tokens created by this filterprincipal - the principal which will be used to represent anonymous usersauthorities - the authority list for anonymous userspublic reactor.core.publisher.Mono<java.lang.Void> filter(org.springframework.web.server.ServerWebExchange exchange,
org.springframework.web.server.WebFilterChain chain)
filter in interface org.springframework.web.server.WebFilterprotected org.springframework.security.core.Authentication createAuthentication(org.springframework.web.server.ServerWebExchange exchange)