Skip to content

Commit ff07024

Browse files
andyrzhaobroady
authored andcommitted
transport/http: Temporarily disable ADC for DCA
Currently, many services including compute, storage, and bigquery do not have working mTLS endpoints, so we will disable the ADC for DCA logic until we can confirm that all services have working mTLS endpoints. See Google internal bug: b/153088385 Change-Id: I4bd023e67cd5bf9abf218a380b50d6e0bf090723 Reviewed-on: https://code-review.googlesource.com/c/google-api-go-client/+/54232 Reviewed-by: Chris Broadfoot <cbro@google.com>
1 parent 34bd67e commit ff07024

1 file changed

Lines changed: 13 additions & 4 deletions

File tree

transport/http/dial.go

Lines changed: 13 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -202,10 +202,19 @@ func addOCTransport(trans http.RoundTripper, settings *internal.DialSettings) ht
202202
// We would like to avoid introducing client-side logic that parses whether the
203203
// endpoint override is an mTLS url, since the url pattern may change at anytime.
204204
func getClientCertificateSource(settings *internal.DialSettings) (cert.Source, error) {
205-
if settings.ClientCertSource != nil {
206-
return settings.ClientCertSource, nil
207-
}
208-
return cert.DefaultSource()
205+
return settings.ClientCertSource, nil
206+
// TODO(andyzhao): Currently, many services including compute, storage, and bigquery
207+
// do not have working mTLS endpoints, so we will disable the ADC for DCA logic
208+
// until we can confirm that all services have working mTLS endpoints.
209+
/*
210+
if settings.HTTPClient != nil {
211+
return nil, nil // HTTPClient is incompatible with ClientCertificateSource
212+
} else if settings.ClientCertSource != nil {
213+
return settings.ClientCertSource, nil
214+
} else {
215+
return cert.DefaultSoure()
216+
}
217+
*/
209218
}
210219

211220
// getEndpoint returns the endpoint for the service, taking into account the

0 commit comments

Comments
 (0)