diff options
author | Jeremy Kemper <jeremy@bitsweat.net> | 2008-11-23 15:29:03 -0800 |
---|---|---|
committer | Jeremy Kemper <jeremy@bitsweat.net> | 2008-11-23 15:29:03 -0800 |
commit | 51d155e6971acef7fee87cb5e218e05cb87d8f57 (patch) | |
tree | a71e387e4d674c5589db88f7d1791a24ed1abb36 /activesupport | |
parent | c26cb089988c81b355b2d48bcbe343601fe214a0 (diff) | |
download | rails-51d155e6971acef7fee87cb5e218e05cb87d8f57.tar.gz rails-51d155e6971acef7fee87cb5e218e05cb87d8f57.tar.bz2 rails-51d155e6971acef7fee87cb5e218e05cb87d8f57.zip |
Lazy-require OpenSSL
Diffstat (limited to 'activesupport')
-rw-r--r-- | activesupport/lib/active_support/message_verifier.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/activesupport/lib/active_support/message_verifier.rb b/activesupport/lib/active_support/message_verifier.rb index 304058253c..b24acb9f47 100644 --- a/activesupport/lib/active_support/message_verifier.rb +++ b/activesupport/lib/active_support/message_verifier.rb @@ -39,7 +39,8 @@ module ActiveSupport private def generate_digest(data) + require 'openssl' unless defined?(OpenSSL) OpenSSL::HMAC.hexdigest(OpenSSL::Digest::Digest.new(@digest), @secret, data) end end -end
\ No newline at end of file +end |