summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/chef/data_collector.rb4
-rw-r--r--spec/support/shared/context/client.rb2
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/chef/data_collector.rb b/lib/chef/data_collector.rb
index bcd15ea323..0a92b800a6 100644
--- a/lib/chef/data_collector.rb
+++ b/lib/chef/data_collector.rb
@@ -288,9 +288,9 @@ class Chef
# raise an exception.
def setup_http_client
if data_collector_token.nil?
- Chef::ServerAPI.new(data_collector_server_url)
+ Chef::ServerAPI.new(data_collector_server_url, validate_utf8: false)
else
- Chef::HTTP::SimpleJSON.new(data_collector_server_url)
+ Chef::HTTP::SimpleJSON.new(data_collector_server_url, validate_utf8: false)
end
end
diff --git a/spec/support/shared/context/client.rb b/spec/support/shared/context/client.rb
index 295bd6ce5f..c65650e6b1 100644
--- a/spec/support/shared/context/client.rb
+++ b/spec/support/shared/context/client.rb
@@ -95,7 +95,7 @@ shared_context "a client run" do
def stub_for_data_collector_init
expect(Chef::ServerAPI).to receive(:new).
- with(Chef::Config[:data_collector][:server_url]).
+ with(Chef::Config[:data_collector][:server_url], validate_utf8: false).
exactly(:once).
and_return(http_data_collector)
end