File tree Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Expand file tree Collapse file tree 1 file changed +16
-0
lines changed Original file line number Diff line number Diff line change @@ -27,7 +27,9 @@ const (
2727 TLSVersion11 TLSVersion = tls .VersionTLS11
2828 TLSVersion12 TLSVersion = tls .VersionTLS12
2929 TLSVersion13 TLSVersion = tls .VersionTLS13
30+ )
3031
32+ var (
3133 // TLSVersionMin is the min TLS version supported.
3234 TLSVersionMin = TLSVersion10
3335
@@ -58,6 +60,20 @@ var tlsProtocolVersions = map[string]TLSVersion{
5860 "TLSv1.3" : TLSVersion13 ,
5961}
6062
63+ // SetInsecureDefaults is currently a nop as the default versions have not changed.
64+ //
65+ // This function is used to avoid a breaking change on previous releases.
66+ // We plan on the default minimum versions list to exclude TLS1.1, and not allow TLS1.0 in a future library update.
67+ func SetInsecureDefaults () {
68+ TLSVersionMin = TLSVersion10
69+ TLSVersionDefaultMin = TLSVersion11
70+ TLSDefaultVersions = []TLSVersion {
71+ TLSVersion11 ,
72+ TLSVersion12 ,
73+ TLSVersion13 ,
74+ }
75+ }
76+
6177// Intended for ECS's tls.version_protocol_field, which does not include
6278// numeric version and should be lower case
6379type TLSVersionDetails struct {
You can’t perform that action at this time.
0 commit comments