Forum: Ruby Encrypted By Ezcrypto but cannot decrypt with PHP mcrypt

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Kwonnam S. (Guest)
on 2007-03-08 04:42
Hello, I'm a Ruby newbie.

Our site is developed with Ruby On Rails mainly, but some parts use PHP
5.
So, in Ruby, it encrypt username with EzCrypto aes-128-cbc with a key
and save it to browser cookie.
But cannot decrypt the cookie  with PHP5's mcrypt RIJNDAEL128 CBC
algorithm with the same key.
(AFAIK RIJNDAEL128 == AES, am I right??)
How can I decrypt the value which is encrypted with EzCrypto?
I don't have to use aes-128-cbc.

Would you recomend any algorithm good for this kind problem?

Regards,
Kwonnam S. (Guest)
on 2007-03-08 10:24
I solved the problem with aes-128-ecb in EzCrypto, and
MCRYPT_RIJNDAEL_128, MCRYPT_MODE_ECB in PHP.

Kwonnam Son wrote:
> Hello, I'm a Ruby newbie.
>
> Our site is developed with Ruby On Rails mainly, but some parts use PHP
> 5.
> So, in Ruby, it encrypt username with EzCrypto aes-128-cbc with a key
> and save it to browser cookie.
> But cannot decrypt the cookie  with PHP5's mcrypt RIJNDAEL128 CBC
> algorithm with the same key.
> (AFAIK RIJNDAEL128 == AES, am I right??)
> How can I decrypt the value which is encrypted with EzCrypto?
> I don't have to use aes-128-cbc.
>
> Would you recomend any algorithm good for this kind problem?
>
> Regards,
This topic is locked and can not be replied to.