Mentioned in https://github.com/spring-projects/spring-boot/issues/33645 and opening here.
@EnableMethodSecurity (and @EnableWebSecurity as well) dropped the meta annotation @Configuration between version 5.8 & 6.0.x. Projects that were relying on that annotation to register the class for component scanning will need to add the @Configuration annotation themselves.
I think this would be good to mention in the 6.0 Migration Guide
Comment From: adase11
If it helps, it looks like this commit is the one that removed the @Configuration annotation (from more classes that I originally mentioned).