Secure a database password
Base64 encoding
We don't recommend Base64 encoding in production for securing secrets because it doesn't provide encryption, and therefore cannot guarantee sufficient data protection.
Learn more about base64 encoding
AES encryption
This method allows you to choose an algorithm to encrypt a database password. It provides more security as you don't have to store the encrypted password anywhere in the configuration file, which makes it difficult for unauthorized parties to find and decrypt it.
Learn more about AES encryption
AWS Secrets Manager
AWS Secrets Manager provides a high-level secure storage option for your database credentials. This service retrieves credentials through a runtime call, eliminating hard-coded credentials, such as keys and tokens, altogether.
Learn more about AWS Secrets Manager for encryption
Custom encryption
If you have special requirements for database password encryption, you can create your own encryption mechanism based on our examples.