Rename TlsVerify to TLSVerify
This commit is contained in:
parent
900bb1254e
commit
fb0c7292ac
@ -467,7 +467,7 @@ func UnmarshalPluginsFromIni(sections ini.File, cfg *ServerCommonConf) {
|
|||||||
Addr: section["addr"],
|
Addr: section["addr"],
|
||||||
Path: section["path"],
|
Path: section["path"],
|
||||||
Ops: strings.Split(section["ops"], ","),
|
Ops: strings.Split(section["ops"], ","),
|
||||||
TlsVerify: tls_verify,
|
TLSVerify: tls_verify,
|
||||||
}
|
}
|
||||||
for i := range options.Ops {
|
for i := range options.Ops {
|
||||||
options.Ops[i] = strings.TrimSpace(options.Ops[i])
|
options.Ops[i] = strings.TrimSpace(options.Ops[i])
|
||||||
|
@ -32,7 +32,7 @@ type HTTPPluginOptions struct {
|
|||||||
Addr string
|
Addr string
|
||||||
Path string
|
Path string
|
||||||
Ops []string
|
Ops []string
|
||||||
TlsVerify bool
|
TLSVerify bool
|
||||||
}
|
}
|
||||||
|
|
||||||
type httpPlugin struct {
|
type httpPlugin struct {
|
||||||
@ -44,7 +44,7 @@ type httpPlugin struct {
|
|||||||
|
|
||||||
func NewHTTPPluginOptions(options HTTPPluginOptions) Plugin {
|
func NewHTTPPluginOptions(options HTTPPluginOptions) Plugin {
|
||||||
var client *http.Client
|
var client *http.Client
|
||||||
if options.TlsVerify == false {
|
if options.TLSVerify == false {
|
||||||
tr := &http.Transport{
|
tr := &http.Transport{
|
||||||
TLSClientConfig: &tls.Config{InsecureSkipVerify: true},
|
TLSClientConfig: &tls.Config{InsecureSkipVerify: true},
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user