Currently For SS 6.1.1 the User class has the withDefaultPasswordEncoder deprecated method with its respective javadoc.

About the second part of this javadoc is indicated what is the correct approach to take, but I think is wise add as a complement a better alternative. Spring Boot CLI with the respective command execution spring encodepassword password as sample