mirror of
https://github.com/AdguardTeam/AdGuardHome.git
synced 2024-11-16 02:18:28 -07:00
/tls/configure -- accept empty certificates for saving
This commit is contained in:
parent
885e4e16c8
commit
8c406427af
@ -1088,13 +1088,11 @@ func handleTLSConfigure(w http.ResponseWriter, r *http.Request) {
|
|||||||
|
|
||||||
restartHTTPS := false
|
restartHTTPS := false
|
||||||
data = validateCertificates(data)
|
data = validateCertificates(data)
|
||||||
if data.usable {
|
|
||||||
if !reflect.DeepEqual(config.TLS.tlsConfigSettings, data.tlsConfigSettings) {
|
if !reflect.DeepEqual(config.TLS.tlsConfigSettings, data.tlsConfigSettings) {
|
||||||
log.Printf("tls config settings have changed, will restart HTTPS server")
|
log.Printf("tls config settings have changed, will restart HTTPS server")
|
||||||
restartHTTPS = true
|
restartHTTPS = true
|
||||||
}
|
}
|
||||||
config.TLS = data
|
config.TLS = data
|
||||||
}
|
|
||||||
err = writeAllConfigsAndReloadDNS()
|
err = writeAllConfigsAndReloadDNS()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
httpError(w, http.StatusInternalServerError, "Couldn't write config file: %s", err)
|
httpError(w, http.StatusInternalServerError, "Couldn't write config file: %s", err)
|
||||||
|
Loading…
Reference in New Issue
Block a user