You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We can add an util to return an encrypted version of the password. Then decrypt it before using it in the connection path. That would fix the issue.
To do that, we can use javax.crypto.Cipher which contains a lot of functionality for this task. This, however, will require a password to decode the encoded password (within the application). The question is then, how do we provide the decipher password? Would giving it as a runtime property ( option -D in the JVM) work? How do people like to handle this?
Another related question is how do we identify whether the password is encrypted or not? Should we have two different fields in the YAML config file (e.g., db_password and also db_password_encrypted?) This would work because we can then check at runtime that at least one has a value and: i) use it directly if not encrypted or; ii) decrypt with the provided decryption password and use.
Encryption or reading passwords from centralized location will help
The text was updated successfully, but these errors were encountered: