Avoid ridiculously low values for proxy.certRefreshDelay

This commit is contained in:
Frank Denis 2019-11-08 22:51:04 +01:00
parent 0f7bd23b8a
commit a31e7c0c61
1 changed files with 1 additions and 1 deletions

View File

@ -313,7 +313,7 @@ func ConfigLoad(proxy *Proxy, flags *ConfigFlags) error {
if config.ForceTCP { if config.ForceTCP {
proxy.mainProto = "tcp" proxy.mainProto = "tcp"
} }
proxy.certRefreshDelay = time.Duration(config.CertRefreshDelay) * time.Minute proxy.certRefreshDelay = time.Duration(Max(60, config.CertRefreshDelay)) * time.Minute
proxy.certRefreshDelayAfterFailure = time.Duration(10 * time.Second) proxy.certRefreshDelayAfterFailure = time.Duration(10 * time.Second)
proxy.certIgnoreTimestamp = config.CertIgnoreTimestamp proxy.certIgnoreTimestamp = config.CertIgnoreTimestamp
proxy.ephemeralKeys = config.EphemeralKeys proxy.ephemeralKeys = config.EphemeralKeys