Reputation: 513
We have a batch application using OpenJPA. We are specifying all the DB connection parameters in persistence.xml. Although its a functional setup it looks very insecure to have all the ip,username,password in clear text and a serious concern in production.
As it is a standalone batch app we cant use server configurations etc. Is there a way to may JPA read the properties from an encrypted file...or at the least something like MD5 hashing the parameter values?
Upvotes: 1
Views: 3090
Reputation: 631
At least passwords can be encrypted. Since OpenJPA 1.3.0 your can set an EncryptionProvider in OpenJPAConfiguration. See also the manual.
Upvotes: 3