Add guard against DNS rebinding attacks (#16087)
* Add guard against DNS rebinding attacks * Fix not to apply to test environmentgh/stable
parent
e243092a5a
commit
8323023464
|
@ -26,4 +26,10 @@ Rails.application.configure do
|
||||||
"ws://#{ENV['REMOTE_DEV'] == 'true' ? host.split(':').first : 'localhost'}:4000"
|
"ws://#{ENV['REMOTE_DEV'] == 'true' ? host.split(':').first : 'localhost'}:4000"
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
|
unless Rails.env.test?
|
||||||
|
config.hosts << host if host.present?
|
||||||
|
config.hosts << web_host if web_host.present?
|
||||||
|
config.hosts << alternate_domains if alternate_domains.present?
|
||||||
|
end
|
||||||
end
|
end
|
||||||
|
|
Reference in New Issue