Commit 1cd7d14e authored by mbergeron's avatar mbergeron

Disable the dns_rebind_protection in the validation

parent cb865035
...@@ -298,7 +298,10 @@ module EE ...@@ -298,7 +298,10 @@ module EE
# ElasticSearch only exposes a RESTful API, hence we need # ElasticSearch only exposes a RESTful API, hence we need
# to use the HTTP protocol on all URLs. # to use the HTTP protocol on all URLs.
elasticsearch_url.each do |str| elasticsearch_url.each do |str|
::Gitlab::UrlBlocker.validate!(str, schemes: %w[http https], allow_localhost: true) ::Gitlab::UrlBlocker.validate!(str,
schemes: %w[http https],
allow_localhost: true,
dns_rebind_protection: false)
end end
rescue ::Gitlab::UrlBlocker::BlockedUrlError rescue ::Gitlab::UrlBlocker::BlockedUrlError
errors.add(:elasticsearch_url, "only supports valid HTTP(S) URLs.") errors.add(:elasticsearch_url, "only supports valid HTTP(S) URLs.")
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment