Skip to content

Commit de6fbd0

Browse files
upgrade to latest dependencies (#16423)
bumping k8s.io/apiextensions-apiserver 6b81add...79000f4: > 79000f4 Update dependencies to v0.35.2 tag bumping k8s.io/code-generator cf6ffee...df367fb: > df367fb Update dependencies to v0.35.2 tag bumping k8s.io/api 4aa217d...8a137cd: > 8a137cd Update dependencies to v0.35.2 tag bumping k8s.io/apimachinery 72d71ea...72d71ea: bumping k8s.io/client-go b464ad8...a21b329: > a21b329 Update dependencies to v0.35.2 tag bumping knative.dev/pkg b239e96...1f39e94: > 1f39e94 Bump golang.org/x/net from 0.50.0 to 0.51.0 in the golang-x group (# 3326) > 08c9466 Bump the k8s group with 5 updates (# 3325) > f62171b feat: add shared tls package for reading TLS config from environment (# 3324) bumping golang.org/x/net ebddb99...60b3f6f: > 60b3f6f internal/http3: prevent Server handler from writing longer body than declared > b0ca456 internal/http3: fix Write in Server Handler returning the wrong value > 1558ba7 publicsuffix: update to 2026-02-06 > 4e1c745 internal/http3: make Server response include headers that can be inferred > 19f580f http2: fix nil panic in typeFrameParser for unassigned frame types > 818aad7 internal/http3: add server to client trailer header support > c1bbe1a internal/http3: add client to server trailer header support > 29181b8 all: remove go1.25 and older build constraints > 8109305 all: upgrade go directive to at least 1.25.0 [generated] > 0b37bdf quic: don't run TestStreamsCreateConcurrency in synctest bubble > 9095c1c internal/http3: more robust handling of request & response with no body Signed-off-by: Knative Automation <automation@knative.team>
1 parent ef443fb commit de6fbd0

File tree

11 files changed

+257
-42
lines changed

11 files changed

+257
-42
lines changed

go.mod

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -29,17 +29,17 @@ require (
2929
golang.org/x/time v0.10.0
3030
google.golang.org/api v0.198.0
3131
google.golang.org/grpc v1.78.0
32-
k8s.io/api v0.35.1
33-
k8s.io/apiextensions-apiserver v0.35.1
34-
k8s.io/apimachinery v0.35.1
35-
k8s.io/client-go v0.35.1
36-
k8s.io/code-generator v0.35.1
32+
k8s.io/api v0.35.2
33+
k8s.io/apiextensions-apiserver v0.35.2
34+
k8s.io/apimachinery v0.35.2
35+
k8s.io/client-go v0.35.2
36+
k8s.io/code-generator v0.35.2
3737
k8s.io/kube-openapi v0.0.0-20250910181357-589584f1c912
3838
k8s.io/utils v0.0.0-20251002143259-bc988d571ff4
3939
knative.dev/caching v0.0.0-20260223015057-21f97c7d8048
4040
knative.dev/hack v0.0.0-20260212092700-0126b283bf20
4141
knative.dev/networking v0.0.0-20260223015858-080d52fcffb4
42-
knative.dev/pkg v0.0.0-20260225113719-b239e967f175
42+
knative.dev/pkg v0.0.0-20260302190359-1f39e94ef003
4343
sigs.k8s.io/randfill v1.0.0
4444
sigs.k8s.io/yaml v1.6.0
4545
)
@@ -148,7 +148,7 @@ require (
148148
go.yaml.in/yaml/v2 v2.4.3 // indirect
149149
golang.org/x/crypto v0.48.0 // indirect
150150
golang.org/x/mod v0.33.0 // indirect
151-
golang.org/x/net v0.50.0 // indirect
151+
golang.org/x/net v0.51.0 // indirect
152152
golang.org/x/oauth2 v0.34.0 // indirect
153153
golang.org/x/term v0.40.0 // indirect
154154
golang.org/x/text v0.34.0 // indirect

go.sum

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -401,8 +401,8 @@ golang.org/x/net v0.0.0-20211112202133-69e39bad7dc2/go.mod h1:9nx3DQGgdP8bBQD5qx
401401
golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c=
402402
golang.org/x/net v0.6.0/go.mod h1:2Tu9+aMcznHK/AK1HMvgo6xiTLG5rD5rZLDS+rp2Bjs=
403403
golang.org/x/net v0.10.0/go.mod h1:0qNGK6F8kojg2nk9dLZ2mShWaEBan6FAoqfSigmmuDg=
404-
golang.org/x/net v0.50.0 h1:ucWh9eiCGyDR3vtzso0WMQinm2Dnt8cFMuQa9K33J60=
405-
golang.org/x/net v0.50.0/go.mod h1:UgoSli3F/pBgdJBHCTc+tp3gmrU4XswgGRgtnwWTfyM=
404+
golang.org/x/net v0.51.0 h1:94R/GTO7mt3/4wIKpcR5gkGmRLOuE/2hNGeWq/GBIFo=
405+
golang.org/x/net v0.51.0/go.mod h1:aamm+2QF5ogm02fjy5Bb7CQ0WMt1/WVM7FtyaTLlA9Y=
406406
golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U=
407407
golang.org/x/oauth2 v0.34.0 h1:hqK/t4AKgbqWkdkcAeI8XLmbK+4m4G5YeQRrmiotGlw=
408408
golang.org/x/oauth2 v0.34.0/go.mod h1:lzm5WQJQwKZ3nwavOZ3IS5Aulzxi68dUSgRHujetwEA=
@@ -521,16 +521,16 @@ gotest.tools/v3 v3.1.0 h1:rVV8Tcg/8jHUkPUorwjaMTtemIMVXfIPKiOqnhEhakk=
521521
gotest.tools/v3 v3.1.0/go.mod h1:fHy7eyTmJFO5bQbUsEGQ1v4m2J3Jz9eWL54TP2/ZuYQ=
522522
honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
523523
honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4=
524-
k8s.io/api v0.35.1 h1:0PO/1FhlK/EQNVK5+txc4FuhQibV25VLSdLMmGpDE/Q=
525-
k8s.io/api v0.35.1/go.mod h1:28uR9xlXWml9eT0uaGo6y71xK86JBELShLy4wR1XtxM=
526-
k8s.io/apiextensions-apiserver v0.35.1 h1:p5vvALkknlOcAqARwjS20kJffgzHqwyQRM8vHLwgU7w=
527-
k8s.io/apiextensions-apiserver v0.35.1/go.mod h1:2CN4fe1GZ3HMe4wBr25qXyJnJyZaquy4nNlNmb3R7AQ=
528-
k8s.io/apimachinery v0.35.1 h1:yxO6gV555P1YV0SANtnTjXYfiivaTPvCTKX6w6qdDsU=
529-
k8s.io/apimachinery v0.35.1/go.mod h1:jQCgFZFR1F4Ik7hvr2g84RTJSZegBc8yHgFWKn//hns=
530-
k8s.io/client-go v0.35.1 h1:+eSfZHwuo/I19PaSxqumjqZ9l5XiTEKbIaJ+j1wLcLM=
531-
k8s.io/client-go v0.35.1/go.mod h1:1p1KxDt3a0ruRfc/pG4qT/3oHmUj1AhSHEcxNSGg+OA=
532-
k8s.io/code-generator v0.35.1 h1:yLKR2la7Z9cWT5qmk67ayx8xXLM4RRKQMnC8YPvTWRI=
533-
k8s.io/code-generator v0.35.1/go.mod h1:F2Fhm7aA69tC/VkMXLDokdovltXEF026Tb9yfQXQWKg=
524+
k8s.io/api v0.35.2 h1:tW7mWc2RpxW7HS4CoRXhtYHSzme1PN1UjGHJ1bdrtdw=
525+
k8s.io/api v0.35.2/go.mod h1:7AJfqGoAZcwSFhOjcGM7WV05QxMMgUaChNfLTXDRE60=
526+
k8s.io/apiextensions-apiserver v0.35.2 h1:iyStXHoJZsUXPh/nFAsjC29rjJWdSgUmG1XpApE29c0=
527+
k8s.io/apiextensions-apiserver v0.35.2/go.mod h1:OdyGvcO1FtMDWQ+rRh/Ei3b6X3g2+ZDHd0MSRGeS8rU=
528+
k8s.io/apimachinery v0.35.2 h1:NqsM/mmZA7sHW02JZ9RTtk3wInRgbVxL8MPfzSANAK8=
529+
k8s.io/apimachinery v0.35.2/go.mod h1:jQCgFZFR1F4Ik7hvr2g84RTJSZegBc8yHgFWKn//hns=
530+
k8s.io/client-go v0.35.2 h1:YUfPefdGJA4aljDdayAXkc98DnPkIetMl4PrKX97W9o=
531+
k8s.io/client-go v0.35.2/go.mod h1:4QqEwh4oQpeK8AaefZ0jwTFJw/9kIjdQi0jpKeYvz7g=
532+
k8s.io/code-generator v0.35.2 h1:3874swbO2c26VWTf6lKD4NWGyHIfyBeTCk7caCG3TuU=
533+
k8s.io/code-generator v0.35.2/go.mod h1:id4XLCm0yAQq5nlvyfAKibMOKnMjzlesAwGw6kM3Adc=
534534
k8s.io/gengo v0.0.0-20201203183100-97869a43a9d9/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E=
535535
k8s.io/gengo v0.0.0-20240404160639-a0386bf69313 h1:wBIDZID8ju9pwOiLlV22YYKjFGtiNSWgHf5CnKLRUuM=
536536
k8s.io/gengo v0.0.0-20240404160639-a0386bf69313/go.mod h1:FiNAH4ZV3gBg2Kwh89tzAEV2be7d5xI0vBa/VySYy3E=
@@ -552,8 +552,8 @@ knative.dev/hack v0.0.0-20260212092700-0126b283bf20 h1:Ocya6ILPQxGrozD5gPELC4J2A
552552
knative.dev/hack v0.0.0-20260212092700-0126b283bf20/go.mod h1:L5RzHgbvam0u8QFHfzCX6MKxu/a/gIGEdaRBqNiVbl0=
553553
knative.dev/networking v0.0.0-20260223015858-080d52fcffb4 h1:ZXE3pdtSPB0quCfAFUodFT+VsT2Xaoqdj4r//O+zk18=
554554
knative.dev/networking v0.0.0-20260223015858-080d52fcffb4/go.mod h1:ITVa/pZZpgmev4E64KDICg9ZC87YLulpF4J8iMgons4=
555-
knative.dev/pkg v0.0.0-20260225113719-b239e967f175 h1:xqlcqilSLcKK7FgKiKxSQir4FQsGv/liewPe8VzaiGk=
556-
knative.dev/pkg v0.0.0-20260225113719-b239e967f175/go.mod h1:M6o085LfZ+8XgJkNI5NI8jwEfYSUfjUWb6bJ5E1MD4A=
555+
knative.dev/pkg v0.0.0-20260302190359-1f39e94ef003 h1:VG+CUgVKm+mLEudP16wLj++xDM2PuVFeua9+MLLBUa8=
556+
knative.dev/pkg v0.0.0-20260302190359-1f39e94ef003/go.mod h1:mV8s7Uc92am8byZSJPIaVm1NBr0h8vsFL+sEEvMoBbk=
557557
pgregory.net/rapid v1.1.0 h1:CMa0sjHSru3puNx+J0MIAuiiEV4N0qj8/cMWGBBCsjw=
558558
pgregory.net/rapid v1.1.0/go.mod h1:PY5XlDGj0+V1FCq0o192FdRhpKHGTRIWBgqjDBTrq04=
559559
sigs.k8s.io/gateway-api v1.1.0 h1:DsLDXCi6jR+Xz8/xd0Z1PYl2Pn0TyaFMOPPZIj4inDM=

vendor/golang.org/x/net/http2/frame.go

Lines changed: 3 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
260 Bytes
Binary file not shown.
2.11 KB
Binary file not shown.

vendor/golang.org/x/net/publicsuffix/data/text

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

vendor/golang.org/x/net/publicsuffix/table.go

Lines changed: 6 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 176 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,176 @@
1+
/*
2+
Copyright 2026 The Knative Authors
3+
4+
Licensed under the Apache License, Version 2.0 (the "License");
5+
you may not use this file except in compliance with the License.
6+
You may obtain a copy of the License at
7+
8+
http://www.apache.org/licenses/LICENSE-2.0
9+
10+
Unless required by applicable law or agreed to in writing, software
11+
distributed under the License is distributed on an "AS IS" BASIS,
12+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13+
See the License for the specific language governing permissions and
14+
limitations under the License.
15+
*/
16+
17+
package tls
18+
19+
import (
20+
cryptotls "crypto/tls"
21+
"fmt"
22+
"os"
23+
"strings"
24+
)
25+
26+
// Environment variable name suffixes for TLS configuration.
27+
// Use with a prefix to namespace them, e.g. "WEBHOOK_" + MinVersionEnvKey
28+
// reads the WEBHOOK_TLS_MIN_VERSION variable.
29+
const (
30+
MinVersionEnvKey = "TLS_MIN_VERSION"
31+
MaxVersionEnvKey = "TLS_MAX_VERSION"
32+
CipherSuitesEnvKey = "TLS_CIPHER_SUITES"
33+
CurvePreferencesEnvKey = "TLS_CURVE_PREFERENCES"
34+
)
35+
36+
// Config holds parsed TLS configuration values that can be used
37+
// to build a *crypto/tls.Config.
38+
type Config struct {
39+
MinVersion uint16
40+
MaxVersion uint16
41+
CipherSuites []uint16
42+
CurvePreferences []cryptotls.CurveID
43+
}
44+
45+
// NewConfigFromEnv reads TLS configuration from environment variables and
46+
// returns a Config. The prefix is prepended to each standard env-var suffix;
47+
// for example with prefix "WEBHOOK_" the function reads
48+
// WEBHOOK_TLS_MIN_VERSION, WEBHOOK_TLS_MAX_VERSION, etc.
49+
// Fields whose corresponding env var is unset are left at their zero value.
50+
func NewConfigFromEnv(prefix string) (*Config, error) {
51+
var cfg Config
52+
53+
if v := os.Getenv(prefix + MinVersionEnvKey); v != "" {
54+
ver, err := parseVersion(v)
55+
if err != nil {
56+
return nil, fmt.Errorf("invalid %s%s %q: %w", prefix, MinVersionEnvKey, v, err)
57+
}
58+
cfg.MinVersion = ver
59+
}
60+
61+
if v := os.Getenv(prefix + MaxVersionEnvKey); v != "" {
62+
ver, err := parseVersion(v)
63+
if err != nil {
64+
return nil, fmt.Errorf("invalid %s%s %q: %w", prefix, MaxVersionEnvKey, v, err)
65+
}
66+
cfg.MaxVersion = ver
67+
}
68+
69+
if v := os.Getenv(prefix + CipherSuitesEnvKey); v != "" {
70+
suites, err := parseCipherSuites(v)
71+
if err != nil {
72+
return nil, fmt.Errorf("invalid %s%s: %w", prefix, CipherSuitesEnvKey, err)
73+
}
74+
cfg.CipherSuites = suites
75+
}
76+
77+
if v := os.Getenv(prefix + CurvePreferencesEnvKey); v != "" {
78+
curves, err := parseCurvePreferences(v)
79+
if err != nil {
80+
return nil, fmt.Errorf("invalid %s%s: %w", prefix, CurvePreferencesEnvKey, err)
81+
}
82+
cfg.CurvePreferences = curves
83+
}
84+
85+
return &cfg, nil
86+
}
87+
88+
// TLSConfig constructs a *crypto/tls.Config from the parsed configuration.
89+
// The caller typically adds additional fields such as GetCertificate.
90+
func (c *Config) TLSConfig() *cryptotls.Config {
91+
//nolint:gosec // Min version is caller-configurable; default is TLS 1.3.
92+
return &cryptotls.Config{
93+
MinVersion: c.MinVersion,
94+
MaxVersion: c.MaxVersion,
95+
CipherSuites: c.CipherSuites,
96+
CurvePreferences: c.CurvePreferences,
97+
}
98+
}
99+
100+
// parseVersion converts a TLS version string to the corresponding
101+
// crypto/tls constant. Accepted values are "1.2" and "1.3".
102+
func parseVersion(v string) (uint16, error) {
103+
switch v {
104+
case "1.2":
105+
return cryptotls.VersionTLS12, nil
106+
case "1.3":
107+
return cryptotls.VersionTLS13, nil
108+
default:
109+
return 0, fmt.Errorf("unsupported TLS version %q: must be %q or %q", v, "1.2", "1.3")
110+
}
111+
}
112+
113+
// parseCipherSuites parses a comma-separated list of TLS cipher-suite names
114+
// (e.g. "TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256,TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384")
115+
// into a slice of cipher-suite IDs. Names must match those returned by
116+
// crypto/tls.CipherSuiteName.
117+
func parseCipherSuites(s string) ([]uint16, error) {
118+
lookup := cipherSuiteLookup()
119+
parts := strings.Split(s, ",")
120+
suites := make([]uint16, 0, len(parts))
121+
122+
for _, name := range parts {
123+
name = strings.TrimSpace(name)
124+
if name == "" {
125+
continue
126+
}
127+
id, ok := lookup[name]
128+
if !ok {
129+
return nil, fmt.Errorf("unknown cipher suite %q", name)
130+
}
131+
suites = append(suites, id)
132+
}
133+
134+
return suites, nil
135+
}
136+
137+
// parseCurvePreferences parses a comma-separated list of elliptic-curve names
138+
// (e.g. "X25519,CurveP256") into a slice of crypto/tls.CurveID values.
139+
// Both Go constant names (CurveP256) and standard names (P-256) are accepted.
140+
func parseCurvePreferences(s string) ([]cryptotls.CurveID, error) {
141+
parts := strings.Split(s, ",")
142+
curves := make([]cryptotls.CurveID, 0, len(parts))
143+
144+
for _, name := range parts {
145+
name = strings.TrimSpace(name)
146+
if name == "" {
147+
continue
148+
}
149+
id, ok := curvesByName[name]
150+
if !ok {
151+
return nil, fmt.Errorf("unknown curve %q", name)
152+
}
153+
curves = append(curves, id)
154+
}
155+
156+
return curves, nil
157+
}
158+
159+
func cipherSuiteLookup() map[string]uint16 {
160+
m := make(map[string]uint16)
161+
for _, cs := range cryptotls.CipherSuites() {
162+
m[cs.Name] = cs.ID
163+
}
164+
return m
165+
}
166+
167+
var curvesByName = map[string]cryptotls.CurveID{
168+
"CurveP256": cryptotls.CurveP256,
169+
"CurveP384": cryptotls.CurveP384,
170+
"CurveP521": cryptotls.CurveP521,
171+
"X25519": cryptotls.X25519,
172+
"X25519MLKEM768": cryptotls.X25519MLKEM768,
173+
"P-256": cryptotls.CurveP256,
174+
"P-384": cryptotls.CurveP384,
175+
"P-521": cryptotls.CurveP521,
176+
}

vendor/knative.dev/pkg/webhook/env.go

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,8 @@ func SecretNameFromEnv(defaultSecretName string) string {
7272
return secret
7373
}
7474

75+
// Deprecated: Use knative.dev/pkg/tls.NewConfigFromEnv instead.
76+
// TLS configuration is now read automatically inside webhook.New via the shared tls package.
7577
func TLSMinVersionFromEnv(defaultTLSMinVersion uint16) uint16 {
7678
switch tlsMinVersion := os.Getenv(tlsMinVersionEnvKey); tlsMinVersion {
7779
case "1.2":

vendor/knative.dev/pkg/webhook/webhook.go

Lines changed: 39 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@ import (
3434
"knative.dev/pkg/network"
3535
"knative.dev/pkg/network/handlers"
3636
"knative.dev/pkg/observability/semconv"
37+
knativetls "knative.dev/pkg/tls"
3738

3839
"go.opentelemetry.io/contrib/instrumentation/net/http/otelhttp"
3940
"go.opentelemetry.io/otel/attribute"
@@ -48,7 +49,15 @@ import (
4849
"knative.dev/pkg/system"
4950
)
5051

51-
// Options contains the configuration for the webhook
52+
// Options contains the configuration for the webhook.
53+
//
54+
// TLS fields (TLSMinVersion, TLSMaxVersion, TLSCipherSuites, TLSCurvePreferences)
55+
// are resolved with the following precedence:
56+
// 1. Values set explicitly in Options (programmatic).
57+
// 2. WEBHOOK_TLS_* environment variables (WEBHOOK_TLS_MIN_VERSION,
58+
// WEBHOOK_TLS_MAX_VERSION, WEBHOOK_TLS_CIPHER_SUITES, WEBHOOK_TLS_CURVE_PREFERENCES).
59+
// 3. Defaults (TLS 1.3 minimum version; zero values for the rest, meaning the
60+
// Go standard library picks its defaults).
5261
type Options struct {
5362
// TLSMinVersion contains the minimum TLS version that is acceptable to communicate with the API server.
5463
// TLS 1.3 is the minimum version if not specified otherwise.
@@ -182,11 +191,36 @@ func New(
182191

183192
logger := logging.FromContext(ctx)
184193

185-
defaultTLSMinVersion := uint16(tls.VersionTLS13)
194+
tlsCfg, err := knativetls.NewConfigFromEnv("WEBHOOK_")
195+
if err != nil {
196+
return nil, fmt.Errorf("reading TLS configuration from environment: %w", err)
197+
}
198+
199+
// Replace the TLS configuration with the one from the environment if not set.
200+
// Default to TLS 1.3 as the minimum version when neither the caller nor the
201+
// environment specifies one.
186202
if opts.TLSMinVersion == 0 {
187-
opts.TLSMinVersion = TLSMinVersionFromEnv(defaultTLSMinVersion)
188-
} else if opts.TLSMinVersion != tls.VersionTLS12 && opts.TLSMinVersion != tls.VersionTLS13 {
189-
return nil, fmt.Errorf("unsupported TLS version: %d", opts.TLSMinVersion)
203+
if tlsCfg.MinVersion != 0 {
204+
opts.TLSMinVersion = tlsCfg.MinVersion
205+
} else {
206+
opts.TLSMinVersion = tls.VersionTLS13
207+
}
208+
}
209+
if opts.TLSMaxVersion == 0 && tlsCfg.MaxVersion != 0 {
210+
opts.TLSMaxVersion = tlsCfg.MaxVersion
211+
}
212+
if opts.TLSCipherSuites == nil && len(tlsCfg.CipherSuites) > 0 {
213+
opts.TLSCipherSuites = tlsCfg.CipherSuites
214+
}
215+
if opts.TLSCurvePreferences == nil && len(tlsCfg.CurvePreferences) > 0 {
216+
opts.TLSCurvePreferences = tlsCfg.CurvePreferences
217+
}
218+
219+
if opts.TLSMinVersion != 0 && opts.TLSMinVersion != tls.VersionTLS12 && opts.TLSMinVersion != tls.VersionTLS13 {
220+
return nil, fmt.Errorf("unsupported TLS minimum version %d: must be TLS 1.2 or TLS 1.3", opts.TLSMinVersion)
221+
}
222+
if opts.TLSMaxVersion != 0 && opts.TLSMinVersion > opts.TLSMaxVersion {
223+
return nil, fmt.Errorf("TLS minimum version (%#x) is greater than maximum version (%#x)", opts.TLSMinVersion, opts.TLSMaxVersion)
190224
}
191225

192226
syncCtx, cancel := context.WithCancel(context.Background())

0 commit comments

Comments
 (0)