aboutsummaryrefslogtreecommitdiffstats
path: root/actionpack/test/controller/action_pack_assertions_test.rb
diff options
context:
space:
mode:
authorRafael França <rafaelmfranca@gmail.com>2019-01-17 14:37:22 -0500
committerGitHub <noreply@github.com>2019-01-17 14:37:22 -0500
commit9d046eb553f79cf6a6664edd2be72e6131f927a9 (patch)
tree86d64be54fc8e03acd4ad76d5f21e4a3cd210255 /actionpack/test/controller/action_pack_assertions_test.rb
parent3d7391cb76758c82c8ea7759b6dd8d4402bc2346 (diff)
parent9dde7d8de047b55ec636c4c7cba89ec95324d492 (diff)
downloadrails-9d046eb553f79cf6a6664edd2be72e6131f927a9.tar.gz
rails-9d046eb553f79cf6a6664edd2be72e6131f927a9.tar.bz2
rails-9d046eb553f79cf6a6664edd2be72e6131f927a9.zip
Merge pull request #34412 from gmcgibbon/redirect_to_allow_other_host
Ensure external redirects are explicitly allowed
Diffstat (limited to 'actionpack/test/controller/action_pack_assertions_test.rb')
-rw-r--r--actionpack/test/controller/action_pack_assertions_test.rb6
1 files changed, 3 insertions, 3 deletions
diff --git a/actionpack/test/controller/action_pack_assertions_test.rb b/actionpack/test/controller/action_pack_assertions_test.rb
index ecb8c37e6b..c7aae034dd 100644
--- a/actionpack/test/controller/action_pack_assertions_test.rb
+++ b/actionpack/test/controller/action_pack_assertions_test.rb
@@ -28,13 +28,13 @@ class ActionPackAssertionsController < ActionController::Base
def redirect_to_path() redirect_to "/some/path" end
- def redirect_invalid_external_route() redirect_to "ht_tp://www.rubyonrails.org" end
+ def redirect_invalid_external_route() redirect_to "ht_tp://www.rubyonrails.org", allow_other_host: true end
def redirect_to_named_route() redirect_to route_one_url end
- def redirect_external() redirect_to "http://www.rubyonrails.org"; end
+ def redirect_external() redirect_to "http://www.rubyonrails.org", allow_other_host: true; end
- def redirect_external_protocol_relative() redirect_to "//www.rubyonrails.org"; end
+ def redirect_external_protocol_relative() redirect_to "//www.rubyonrails.org", allow_other_host: true; end
def response404() head "404 AWOL" end