Makes ALPN protocols configurable
This commit is contained in:
parent
fa53f7ec85
commit
2644c1f598
18 changed files with 216 additions and 15 deletions
|
@ -703,6 +703,12 @@ func buildTLSOptions(ctx context.Context, client Client) map[string]tls.Options
|
|||
id = tlsOption.Name
|
||||
nsDefault = append(nsDefault, tlsOption.Namespace)
|
||||
}
|
||||
|
||||
alpnProtocols := tls.DefaultTLSOptions.ALPNProtocols
|
||||
if len(tlsOption.Spec.ALPNProtocols) > 0 {
|
||||
alpnProtocols = tlsOption.Spec.ALPNProtocols
|
||||
}
|
||||
|
||||
tlsOptions[id] = tls.Options{
|
||||
MinVersion: tlsOption.Spec.MinVersion,
|
||||
MaxVersion: tlsOption.Spec.MaxVersion,
|
||||
|
@ -714,6 +720,7 @@ func buildTLSOptions(ctx context.Context, client Client) map[string]tls.Options
|
|||
},
|
||||
SniStrict: tlsOption.Spec.SniStrict,
|
||||
PreferServerCipherSuites: tlsOption.Spec.PreferServerCipherSuites,
|
||||
ALPNProtocols: alpnProtocols,
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue