Win a copy of Java 9 Revealed this week in the Features new in Java 9 forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

To Encrypt Password before storing using hibernate  RSS feed

S.R.K.Vivek Raju
Ranch Hand
Posts: 58
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi all

I have to encrypt password before storing into the database and i am using hibernate as the middle tier.

In pure JDBC we use the "encode" keyword as follows,
String insert_query="INSERT INTO table values(?,?,encode(?,'vivek'));

But using hibernate we do the to insert the values nto the database, So is there any way by which we could encode or encrypt passwords before storing into the database.

Any help will be very much appreciated.


With Regards
S.R.K.Vivek Raju.
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!