OpenSSL blow-up in Rails ActiveSupport tests
--------------------------------------------

                 Key: JRUBY-3366
                 URL: http://jira.codehaus.org/browse/JRUBY-3366
             Project: JRuby
          Issue Type: Bug
    Affects Versions: JRuby-OpenSSL 0.3
            Reporter: Charles Oliver Nutter
            Assignee: Ola Bini
             Fix For: JRuby-OpenSSL 0.4


The Rails error is here:

{noformat}
  1) Failure:
test_messing_with_either_value_causes_failure(MessageEncryptorTest)
    [test/message_encryptor_test.rb:36:in `assert_not_decrypted'
     test/message_encryptor_test.rb:23:in 
`test_messing_with_either_value_causes_failure'
     
/Users/headius/projects/jruby/lib/ruby/gems/1.8/gems/mocha-0.9.5/lib/mocha/test_case_adapter.rb:69:in
 `run']:
<ActiveSupport::MessageEncryptor::InvalidMessage> exception expected but was
Class: <ArgumentError>
Message: <"dump format error(Ü)">
---Backtrace---
./test/../lib/active_support/message_encryptor.rb:46:in `load'
./test/../lib/active_support/message_encryptor.rb:46:in `decrypt'
test/message_encryptor_test.rb:37:in `assert_not_decrypted'
test/message_encryptor_test.rb:36:in `assert_not_decrypted'
test/message_encryptor_test.rb:23:in 
`test_messing_with_either_value_causes_failure'
/Users/headius/projects/jruby/lib/ruby/gems/1.8/gems/mocha-0.9.5/lib/mocha/test_case_adapter.rb:69:in
 `run'
---------------
{noformat}

And it produces the following Java backtrace:

{noformat}
java.security.InvalidAlgorithmParameterException: IV must be 16 bytes long.
        at org.bouncycastle.jce.provider.JCEBlockCipher.engineInit(Unknown 
Source)
        at javax.crypto.Cipher.init(DashoA13*..)
        at javax.crypto.Cipher.init(DashoA13*..)
        at org.jruby.ext.openssl.Cipher.doInitialize(Cipher.java:529)
        at org.jruby.ext.openssl.Cipher.update(Cipher.java:551)
        at 
org.jruby.ext.openssl.Cipher$i_method_1_0$RUBYINVOKER$update.call(org/jruby/ext/openssl/Cipher$i_method_1_0$RUBYINVOKER$update.gen)
        at 
org.jruby.runtime.callsite.CachingCallSite.cacheAndCall(CachingCallSite.java:273)
        at 
org.jruby.runtime.callsite.CachingCallSite.call(CachingCallSite.java:112)
        at org.jruby.ast.CallOneArgNode.interpret(CallOneArgNode.java:57)
        at org.jruby.ast.LocalAsgnNode.interpret(LocalAsgnNode.java:123)
        at org.jruby.ast.NewlineNode.interpret(NewlineNode.java:104)
        at org.jruby.ast.BlockNode.interpret(BlockNode.java:71)
        at org.jruby.ast.RescueNode.executeBody(RescueNode.java:225)
        at 
org.jruby.ast.RescueNode.interpretWithJavaExceptions(RescueNode.java:147)
        at org.jruby.ast.RescueNode.interpret(RescueNode.java:110)
        at 
org.jruby.internal.runtime.methods.InterpretedMethod.call(InterpretedMethod.java:163)
{noformat}

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira



---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to