Reputation: 1540
i'm setting up a new project in grails 3 with spring-security and want to authenticate controller using IS_AUTHENTICATED_FULLY.
i've already tried adding url to requestmap according to official documents
@Secured(['IS_AUTHENTICATED_FULLY'])
i expect the output to redirect to login controller if not login
Upvotes: 0
Views: 440
Reputation: 1
I do this under the application.yml file grails-app/conf directory
grails.plugin.springsecurity.interceptUrlMap
https://grails-plugins.github.io/grails-spring-security-core/3.2.x/index.html#configGroovyMap
grails:
plugin:
springsecurity:
interceptUrlMap:
- pattern: '/**' #This can be any URL you want to customize
access:
- 'IS_AUTHENTICATED_FULLY'
Do not copy paste that. Yaml is very picky with whitespace. Use tabs.
Upvotes: 0