Skip to content

Commit

Permalink
Bring FS info level down to INFO, but store this information with the…
Browse files Browse the repository at this point in the history
… cert
  • Loading branch information
jedisct1 committed Jan 18, 2018
1 parent 25664b9 commit 941a7b6
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion dnscrypt-proxy/certs.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ type CertInfo struct {
SharedKey [32]byte
MagicQuery [ClientMagicLen]byte
CryptoConstruction CryptoConstruction
ForwardSecurity bool
}

func FetchCurrentCert(proxy *Proxy, proto string, pk ed25519.PublicKey, serverAddress string, providerName string) (CertInfo, int, error) {
Expand Down Expand Up @@ -77,7 +78,10 @@ func FetchCurrentCert(proxy *Proxy, proto string, pk ed25519.PublicKey, serverAd
}
ttl := tsEnd - tsBegin
if ttl > 86400*7 {
dlog.Warnf("[%v] the key validity period for this server is excessively long (%d days), significantly reducing reliability and forward security.", providerName, ttl/86400)
dlog.Infof("[%v] the key validity period for this server is excessively long (%d days), significantly reducing reliability and forward security.", providerName, ttl/86400)
certInfo.ForwardSecurity = false
} else {
certInfo.ForwardSecurity = true
}
if now > tsEnd || now < tsBegin {
dlog.Debugf("[%v] Certificate not valid at the current date", providerName)
Expand Down

0 comments on commit 941a7b6

Please sign in to comment.