driver

package
v0.0.0-...-c3859bf Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 20, 2023 License: MIT Imports: 12 Imported by: 0

Documentation

Overview

This package implements database/sql/driver interface, so we can use go-mysql with database/sql

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SetCustomTLSConfig

func SetCustomTLSConfig(dsn string, caPem []byte, certPem []byte, keyPem []byte, insecureSkipVerify bool, serverName string) error

SetCustomTLSConfig sets a custom TLSConfig for the address (host:port) of the supplied DSN. It requires a full import of the driver (not by side-effects only). Example of supplying a custom CA, no client cert, no key, validating the certificate, and supplying a serverName for the validation:

driver.SetCustomTLSConfig(CaPem, make([]byte, 0), make([]byte, 0), false, "my.domain.name")

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL