mirror of
https://github.com/spring-projects/spring-security.git
synced 2025-06-25 13:32:30 +00:00
Update kotlin.adoc to add required spread operator(*)
Signed-off-by: Michael Samborski <msamborski@orbiscommunications.com>
This commit is contained in:
parent
d864e51ff6
commit
bfb4878e29
@ -288,7 +288,7 @@ class BankingSecurityConfig {
|
|||||||
open fun approvalsSecurityFilterChain(http: HttpSecurity): SecurityFilterChain {
|
open fun approvalsSecurityFilterChain(http: HttpSecurity): SecurityFilterChain {
|
||||||
val approvalsPaths = arrayOf("/accounts/approvals/**", "/loans/approvals/**", "/credit-cards/approvals/**")
|
val approvalsPaths = arrayOf("/accounts/approvals/**", "/loans/approvals/**", "/credit-cards/approvals/**")
|
||||||
http {
|
http {
|
||||||
securityMatcher(approvalsPaths)
|
securityMatcher(*approvalsPaths)
|
||||||
authorizeHttpRequests {
|
authorizeHttpRequests {
|
||||||
authorize(anyRequest, hasRole("ADMIN"))
|
authorize(anyRequest, hasRole("ADMIN"))
|
||||||
}
|
}
|
||||||
@ -303,7 +303,7 @@ class BankingSecurityConfig {
|
|||||||
val bankingPaths = arrayOf("/accounts/**", "/loans/**", "/credit-cards/**", "/balances/**")
|
val bankingPaths = arrayOf("/accounts/**", "/loans/**", "/credit-cards/**", "/balances/**")
|
||||||
val viewBalancePaths = arrayOf("/balances/**")
|
val viewBalancePaths = arrayOf("/balances/**")
|
||||||
http {
|
http {
|
||||||
securityMatcher(bankingPaths)
|
securityMatcher(*bankingPaths)
|
||||||
authorizeHttpRequests {
|
authorizeHttpRequests {
|
||||||
authorize(viewBalancePaths, hasRole("VIEW_BALANCE"))
|
authorize(viewBalancePaths, hasRole("VIEW_BALANCE"))
|
||||||
authorize(anyRequest, hasRole("USER"))
|
authorize(anyRequest, hasRole("USER"))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user