2019-10-20 21:06:17 +00:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2019-07-19 02:12:02 +00:00
|
|
|
require 'spec_helper'
|
|
|
|
|
2020-06-24 09:08:32 +00:00
|
|
|
RSpec.describe 'rest-client dns rebinding protection' do
|
2019-09-27 11:35:37 +00:00
|
|
|
it_behaves_like 'a request using Gitlab::UrlBlocker' do
|
|
|
|
let(:http_method) { :get }
|
|
|
|
let(:url_blocked_error_class) { ArgumentError }
|
2019-07-19 02:12:02 +00:00
|
|
|
|
2019-09-27 11:35:37 +00:00
|
|
|
def make_request(uri)
|
|
|
|
RestClient.get(uri)
|
2019-07-19 02:12:02 +00:00
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|