Skip to content

Commit

Permalink
Remove production check for hosts (bigbluebutton#1549)
Browse files Browse the repository at this point in the history
  • Loading branch information
farhatahmad authored May 8, 2020
1 parent 6104b3d commit 6b628d6
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions app/controllers/application_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,8 @@ def bbb_server

# Block unknown hosts to mitigate host header injection attacks
def block_unknown_hosts
return unless Rails.env.production?
return if config.hosts.blank?
raise UnsafeHostError, "#{request.host} is not a safe host" unless config.hosts.include?(request.host)
return if Rails.configuration.hosts.blank?
raise UnsafeHostError, "#{request.host} is not a safe host" unless Rails.configuration.hosts.include?(request.host)
end

# Force SSL
Expand Down

0 comments on commit 6b628d6

Please sign in to comment.