diff options
author | Xavier Noria <fxn@hashref.com> | 2012-01-02 14:00:32 -0800 |
---|---|---|
committer | Xavier Noria <fxn@hashref.com> | 2012-01-02 14:00:32 -0800 |
commit | 7bdfbac580f7b03953f2aabf610d98c437da376e (patch) | |
tree | c130e4279ffee79d0cd6a69610480ff9eb9ca0d1 /activesupport/lib/active_support/message_verifier.rb | |
parent | 6e9cd3846811718611543dae049c000076319587 (diff) | |
parent | 5f09414f85edfa60ab54ce8b9f8b03874e0670dc (diff) | |
download | rails-7bdfbac580f7b03953f2aabf610d98c437da376e.tar.gz rails-7bdfbac580f7b03953f2aabf610d98c437da376e.tar.bz2 rails-7bdfbac580f7b03953f2aabf610d98c437da376e.zip |
Merge pull request #4267 from lest/3-2-deprecate-activesupport-base64
deprecate ActiveSupport::Base64
Diffstat (limited to 'activesupport/lib/active_support/message_verifier.rb')
-rw-r--r-- | activesupport/lib/active_support/message_verifier.rb | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/activesupport/lib/active_support/message_verifier.rb b/activesupport/lib/active_support/message_verifier.rb index 9d7c81142a..bbb239e194 100644 --- a/activesupport/lib/active_support/message_verifier.rb +++ b/activesupport/lib/active_support/message_verifier.rb @@ -1,4 +1,4 @@ -require 'active_support/base64' +require 'base64' require 'active_support/core_ext/object/blank' module ActiveSupport @@ -42,14 +42,14 @@ module ActiveSupport data, digest = signed_message.split("--") if data.present? && digest.present? && secure_compare(digest, generate_digest(data)) - @serializer.load(ActiveSupport::Base64.decode64(data)) + @serializer.load(::Base64.decode64(data)) else raise InvalidSignature end end def generate(value) - data = ActiveSupport::Base64.encode64s(@serializer.dump(value)) + data = ::Base64.strict_encode64(@serializer.dump(value)) "#{data}--#{generate_digest(data)}" end |