diff --git a/src/bosh_azure_cpi/lib/cloud/azure/restapi/azure_client.rb b/src/bosh_azure_cpi/lib/cloud/azure/restapi/azure_client.rb index d9f84d83c..6a2b27897 100644 --- a/src/bosh_azure_cpi/lib/cloud/azure/restapi/azure_client.rb +++ b/src/bosh_azure_cpi/lib/cloud/azure/restapi/azure_client.rb @@ -2262,7 +2262,7 @@ def redact_credentials_in_response_body(body) def http(uri, use_ssl = true) http = Net::HTTP.new(uri.host, uri.port) http.use_ssl = true && use_ssl - http.ssl_options = OpenSSL::SSL::OP_IGNORE_UNEXPECTED_EOF + http.ssl_options = OpenSSL::SSL::OP_IGNORE_UNEXPECTED_EOF if OpenSSL::SSL.const_defined? :OP_IGNORE_UNEXPECTED_EOF # Does not exist if using openssl 1.x if @azure_config.environment == ENVIRONMENT_AZURESTACK && uri.host.include?(@azure_config.azure_stack.domain) # The CA cert is only specified for the requests to AzureStack domain. If specified for other domains, the request will fail. http.ca_file = get_ca_cert_path