views:

26

answers:

2

I am looking for a very basic encryption that is built into both languages where I can encrypt a string in pHP, and be able to get the data back out in Java. So it cannot be things like MD5.

A: 

There are built-in or easily discoverable libraries for most major encryption schemes in both languages. Try AES.

http://www.phpaes.com/

http://download.oracle.com/javase/1.4.2/docs/api/javax/crypto/Cipher.html

Dan Grossman
A: 

Look at mcrypt for PHP, which is the preferred encryption suite. Pick a cipher, any cipher. You'll find corresponding software in Java to do decryption of any common cipher suite.

tylerl