aboutsummaryrefslogtreecommitdiffstats
path: root/railties/CHANGELOG.md
diff options
context:
space:
mode:
authorRafael Mendonça França <rafaelmfranca@gmail.com>2013-12-04 17:17:51 -0800
committerRafael Mendonça França <rafaelmfranca@gmail.com>2013-12-04 17:17:51 -0800
commit4f330b042833452d590122ce524d4e06e5039216 (patch)
tree779da00d5586b082b59ff82c2c271cdc98fcdf22 /railties/CHANGELOG.md
parentc9223dc366f17b61d0cffeff14a7e670ece9d0d4 (diff)
parentf56e51d4e43f257b85cff3e9479564890f1317f8 (diff)
downloadrails-4f330b042833452d590122ce524d4e06e5039216.tar.gz
rails-4f330b042833452d590122ce524d4e06e5039216.tar.bz2
rails-4f330b042833452d590122ce524d4e06e5039216.zip
Merge pull request #12995 from rails/application-verifier
Add Application#message_verifier method to return a message verifier
Diffstat (limited to 'railties/CHANGELOG.md')
-rw-r--r--railties/CHANGELOG.md17
1 files changed, 17 insertions, 0 deletions
diff --git a/railties/CHANGELOG.md b/railties/CHANGELOG.md
index 0eda858cca..166080c5b0 100644
--- a/railties/CHANGELOG.md
+++ b/railties/CHANGELOG.md
@@ -1,3 +1,20 @@
+* Add `Application#message_verifier` method to return a message verifier.
+
+ This verifier can be used to generate and verify signed messages in the application.
+
+ message = Rails.application.message_verifier('salt').generate('my sensible data')
+ Rails.application.message_verifier('salt').verify(message)
+ # => 'my sensible data'
+
+ It is recommended not to use the same verifier for different things, so you can get different
+ verifiers passing the name argument.
+
+ message = Rails.application.message_verifier('cookies').generate('my sensible cookie data')
+
+ See the `ActiveSupport::MessageVerifier` documentation for more information.
+
+ *Rafael Mendonça França*
+
* The [Spring application
preloader](https://github.com/jonleighton/spring) is now installed
by default for new applications. It uses the development group of