RequiresChannelDsl
Deprecated
since 6.5 use redirectToHttps instead
A Kotlin DSL to configure HttpSecurity channel security using idiomatic Kotlin code.
Author
Eleftheria Stein
Since
5.3
Properties
Functions
Link copied to clipboard
Adds a request authorization rule for an endpoint matching the provided pattern. If Spring MVC is not an the classpath, it will use an ant matcher. If Spring MVC is on the classpath, it will use an MVC matcher. The MVC will use the same rules that Spring MVC uses for matching. For example, often times a mapping of the path "/path" will match on "/path", "/path/", "/path.html", etc. If the current request will not be processed by Spring MVC, a reasonable default using the pattern as an ant pattern will be used.
fun secure(matches: RequestMatcher = AnyRequestMatcher.INSTANCE, attribute: String = "REQUIRES_SECURE_CHANNEL")
Adds a channel security rule.