@@ -230,9 +230,9 @@ func main() {
230
230
"Enable leader election for controller manager. " +
231
231
"Enabling this will ensure there is only one active controller manager.")
232
232
flag.BoolVar(&secureMetrics, "metrics-secure", false,
233
- "Whether or not the metrics endpoint should be served securely")
233
+ "If set the metrics endpoint is served securely")
234
234
flag.BoolVar(&enableHTTP2, "enable-http2", false,
235
- "Whether or not HTTP/2 should be enabled for the metrics and webhook servers")
235
+ "If set, HTTP/2 will be enabled for the metrics and webhook servers")
236
236
{{- else }}
237
237
var configFile string
238
238
flag.StringVar(&configFile, "config", "",
@@ -249,6 +249,12 @@ func main() {
249
249
ctrl.SetLogger(zap.New(zap.UseFlagOptions(&opts)))
250
250
251
251
{{ if not .ComponentConfig }}
252
+ // if the enable-http2 flag is false (the default), http/2 should be disabled
253
+ // due to its vulnerabilities. More specifically, disabling http/2 will
254
+ // prevent from being vulnerable to the HTTP/2 Stream Cancelation and
255
+ // Rapid Reset CVEs. For more information see:
256
+ // - https://github.com/advisories/GHSA-qppj-fm5r-hxr3
257
+ // - https://github.com/advisories/GHSA-4374-p667-p6c8
252
258
disableHTTP2 := func(c *tls.Config) {
253
259
setupLog.Info("disabling http/2")
254
260
c.NextProtos = []string{"http/1.1"}
0 commit comments