Add deprecation warning
This commit is contained in:
parent
80401e4c98
commit
455811066b
|
@ -134,7 +134,6 @@ func main() {
|
|||
MinVersion: tls.VersionTLS12,
|
||||
}
|
||||
if cf.Settings.TLS.MinVersion != "" {
|
||||
|
||||
var err error
|
||||
tlsConfig.MinVersion, err = ParseTLSVersion(cf.Settings.TLS.MinVersion)
|
||||
if err != nil {
|
||||
|
@ -150,6 +149,9 @@ func main() {
|
|||
os.Exit(1)
|
||||
}
|
||||
}
|
||||
if tlsConfig.MinVersion == tls.VersionTLS10 || tlsConfig.MinVersion == tls.VersionTLS11 {
|
||||
fmt.Fprintf(os.Stderr, "warning: using of a deprecated TLS version (< 1.2) is not recommended\n")
|
||||
}
|
||||
// Create self-signed certificate, when no keyfile and no certificates are present
|
||||
if cf.Settings.TLS.Keyfile == "" && len(cf.Settings.TLS.Certificates) == 0 {
|
||||
// TODO
|
||||
|
|
Loading…
Reference in a new issue