How to enable secured-annotations with Java based configuration? December 25, 2023 by Tarik You need to use the @EnableGlobalMethodSecurity(securedEnabled = true) annotation, as defined in the docs.