lidavidm commented on code in PR #355:
URL: https://github.com/apache/arrow-adbc/pull/355#discussion_r1081676269
##########
go/adbc/driver/flightsql/flightsql_adbc.go:
##########
@@ -116,22 +122,32 @@ type database struct {
func (d *database) SetOptions(cnOptions map[string]string) error {
if val, ok := cnOptions[OptionSSLInsecure]; ok && val ==
adbc.OptionValueEnabled {
- d.creds = insecure.NewCredentials()
- } else {
- // option specified path to certificate file
- if cert, ok := cnOptions[OptionSSLCertFile]; ok {
- c, err := credentials.NewClientTLSFromFile(cert, "")
- if err != nil {
- return adbc.Error{
- Msg: "invalid SSL certificate passed",
- Code: adbc.StatusInvalidArgument,
- }
+ if d.uri.Scheme != "grpc+tls" {
+ return adbc.Error{
+ Msg: "Connection is not TLS-enabled",
+ Code: adbc.StatusInvalidArgument,
+ }
+ }
+ d.creds = credentials.NewTLS(&tls.Config{InsecureSkipVerify:
true})
Review Comment:
Yes and yes, I plan to also double-check against the options that the C++
driver used to implement
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]