Remove Jasypt, moving encrypted configuration to AWS Secrets Manager
ProprietaryReplaces each Jasypt-encrypted Spring Boot property value (ENC(...) by default) with a reference to a key of an AWS Secrets Manager secret. Spring Cloud AWS loads the secret, imported with spring.config.import=${secrets.import:aws-secretsmanager:...} on Spring Boot 2.4 and later and named in bootstrap.properties on Spring Boot 2.0 to 2.3; where it cannot, a generated EnvironmentPostProcessor on the AWS SDK v2 does. Projects with Spring Boot tests get a test-only config/application.properties that loads no secret and stands in for each moved value. Code that reads such a config file with EncryptableProperties reads the same keys from Spring's Environment. Removes jasypt-spring-boot: its dependencies and Maven plugin, @EnableEncryptableProperties, @EncryptablePropertySource, custom StringEncryptor, detector and filter beans, tests that only produce encrypted values, and jasypt.encryptor.* properties, unless the StringEncryptor bean is kept for other code (a literal password then moves to the secret). Values a custom resolver or detector decrypts stay as they are, on a shim. Every other use of Jasypt, which has no AWS Secrets Manager replacement, is kept working by compatibility shims added to the repository, compatible with what Jasypt encrypted and hashed, and every Jasypt dependency is removed. A Jasypt password encryptor used only to hash and check passwords becomes a Spring Security DelegatingPasswordEncoder that hashes new passwords with bcrypt and verifies the hashes Jasypt made. A recipe cannot decrypt, so every value moved to a secret is reported in a data table with the settings needed to decrypt it.
io. moderne. cryptography. jasypt. RemoveJasyptOptional
Put before the application name to name the secret. A profile-specific file or document imports the secret named <prefix><application>_<profile>.
mod run . --recipe= io. moderne. cryptography. jasypt. RemoveJasyptInstall it once from Recipe actions, then run it on every repository under the current directory. New to the Moderne CLI? Set it up.