Advice on encryption technique
I have a program which requires a user to login. The username and password are stored in a Postgre database, with the password in clear text. In other words, when a user logs into the program the user/pass is checked against the database before continuing.
I want to make a change to the code, such that I can store a pre-encrypted password into the database, and have the password decrypted in the program.
I tried to use the AES algorithm using the Javax.crypto library, however the encrypted password won't store in my postgre database, which is currently set to accept 'varchar'. My assumption is, the database only allows UTF-8 text to be stored in it *shrug*.
Is there an easier method to encrypt/decrypt that will return utf-8 compliant results? Note, that the encryption really doesn't have to be fancy or 'uber' safe. My main concern is that it simply isn't cleartext.
Thanks!

