core/config: disable strict-transport-security header with staging autocert (#4741)

This commit is contained in:
Caleb Doxsey 2023-11-13 09:21:44 -07:00 committed by GitHub
parent 3ad72db2fb
commit cfc339548f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 10 additions and 1 deletions

View file

@ -1155,7 +1155,7 @@ func (o *Options) GetSetResponseHeadersForPolicy(policy *Policy) map[string]stri
hdrs[k] = v
}
if !o.HasCertificates() {
if !o.HasCertificates() || o.AutocertOptions.UseStaging {
delete(hdrs, "Strict-Transport-Security")
}
}