mirror of
https://github.com/AdguardTeam/AdGuardHome.git
synced 2025-05-05 23:42:54 +03:00
changes done as per review comments
This commit is contained in:
parent
24eb3476db
commit
15b19ff726
5 changed files with 41 additions and 22 deletions
internal/home
|
@ -383,7 +383,7 @@ func initWeb(args options, clientBuildFS fs.FS) (web *Web, err error) {
|
|||
clientBetaFS: clientBetaFS,
|
||||
|
||||
serveHTTP3: config.DNS.ServeHTTP3,
|
||||
tlsCiphers: config.TLS.TLSCiphers,
|
||||
tlsCiphers: getTLSCiphers(),
|
||||
}
|
||||
|
||||
web = newWeb(&webConf)
|
||||
|
@ -888,3 +888,16 @@ type jsonError struct {
|
|||
// Message is the error message, an opaque string.
|
||||
Message string `json:"message"`
|
||||
}
|
||||
|
||||
// getTLSCiphers check for overriden tls ciphers, if the slice is
|
||||
// empty, then default safe ciphers are used
|
||||
func getTLSCiphers() []uint16 {
|
||||
var cipher []uint16
|
||||
|
||||
if len(config.TLS.OverrideTLSCiphers) == 0 {
|
||||
cipher = aghtls.SaferCipherSuites()
|
||||
} else {
|
||||
cipher = aghtls.ParseCipherIDs(config.TLS.OverrideTLSCiphers)
|
||||
}
|
||||
return cipher
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue