From 593110b61afecc836f878d183f8223df0ce6232b Mon Sep 17 00:00:00 2001 From: Alexey Miasoedov Date: Mon, 30 May 2022 17:24:16 +0300 Subject: [PATCH] fix expiredCertsCounter condition --- pkg/vault-mon/pki.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/vault-mon/pki.go b/pkg/vault-mon/pki.go index f4aa117..31d7db0 100644 --- a/pkg/vault-mon/pki.go +++ b/pkg/vault-mon/pki.go @@ -152,7 +152,7 @@ func (pki *PKI) loadCerts() error { pki.certs[cert.Subject.CommonName] = cert } - if cert.NotAfter.Unix() > time.Now().Unix() { + if cert.NotAfter.Unix() < time.Now().Unix() { pki.expiredCertsCounter++ }