OpenSSL::Cipher

24 views
Skip to first unread message

Jonathan Mason

unread,
Feb 19, 2013, 8:06:41 PM2/19/13
to maglev-d...@googlegroups.com
Hello,

So I'm looking to AES encrypt/decrypt some data flowing from one app to another. One app is Rails on MRI 1.8.7 

Nothing fancy going on, but in maglev OpenSSL::Cipher raises uninitialized constant. This does makes sense, as MRI 1.8.7 OpenSSL is all thin wrappers around the C openssl libs.

But do we have an implementation of OpenSSL aes-256-cbc Cipher in Maglev? I'm not especially particular about that cipher, it's just the one I'm using at the moment.

cheers
Jon

pbm

unread,
Feb 20, 2013, 2:17:46 PM2/20/13
to MagLev Discussion
The OpenSSL support in MagLev is currently the basic support needed to
get md5 working and to get encrypted cookies in rails working (a few
other things may work as well). It was not an exhaustive
implementation. MagLev uses FFI to wrap the underlying libcrypto (see
lib/ruby/1.8/maglev/openssl/ffi).

You might be able to back-port some of the Cipher work from the 1.9
branch: E.g., see:
https://github.com/MagLev/maglev/blob/master-1.9/lib/ruby/1.9/maglev/openssl/cipher.rb

which appears to support aes-256-cbc. Perhaps Tim knows more?
Reply all
Reply to author
Forward
0 new messages