• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

password and connection's details in persistence.xml

 
Peter Smorada
Greenhorn
Posts: 12
Java Netbeans IDE Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi everyone,

I’d like to ask if there is a way how to encrypt my connection’s details in persistence.xml. I am a bit concerned about the security of my app and I don’t want to have anyone with basic knowledge of JPA (or even without) having my DB user, password and URL taken out of the jar file.

I know that it is possible to create a wrapper (launch4j), but I don’t want to go that way…

I use hibernate as a persistence provider.
Thank you in advance.
 
Vijitha Kumara
Bartender
Pie
Posts: 3930
21
Chrome Fedora Hibernate
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Not sure it is provided by the spec yet. But OpenJPA seems to have similar to this in the API. I Haven't checked with the Hibernate either. Or you can check some alternatives given here.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic