aboutsummaryrefslogtreecommitdiffstats
path: root/railties/test
diff options
context:
space:
mode:
authorStephen Touset <stephen@squareup.com>2017-02-23 14:41:40 -0800
committerStephen Touset <stephen@squareup.com>2017-03-01 14:54:34 -0800
commit6aa6f9ae44ed999e972a58f729bdc5b2fcdc127b (patch)
treea16ecd4f51bdf20b88c566cb4aebe0bf3ae8cf88 /railties/test
parent771637269dca82782b30e0ef0ef96b5428c6defb (diff)
downloadrails-6aa6f9ae44ed999e972a58f729bdc5b2fcdc127b.tar.gz
rails-6aa6f9ae44ed999e972a58f729bdc5b2fcdc127b.tar.bz2
rails-6aa6f9ae44ed999e972a58f729bdc5b2fcdc127b.zip
Default Secrets to AES-128-GCM, using ActiveSupport::MessageEncryptor
Fixes #28135.
Diffstat (limited to 'railties/test')
-rw-r--r--railties/test/secrets_test.rb5
1 files changed, 3 insertions, 2 deletions
diff --git a/railties/test/secrets_test.rb b/railties/test/secrets_test.rb
index 36e42cf1f9..6650a37d2b 100644
--- a/railties/test/secrets_test.rb
+++ b/railties/test/secrets_test.rb
@@ -54,9 +54,10 @@ class Rails::SecretsTest < ActiveSupport::TestCase
test "reading from key file" do
run_secrets_generator do
- File.binwrite("config/secrets.yml.key", "How do I know you feel it?")
+ key = "00112233445566778899aabbccddeeff"
+ File.binwrite("config/secrets.yml.key", key)
- assert_equal "How do I know you feel it?", Rails::Secrets.key
+ assert_equal [key].pack("H*"), Rails::Secrets.key
end
end