Skip to content

Commit 4084f63

Browse files
committed
Document difference between ssl_expiry metrics
blackbox-exporter currently offers two metrics to measure when TLS Certificates will expire. The difference between those is very subtle, but using `probe_ssl_earliest_cert_expiry` for checking whether a certificate is due to replacement can lead to false positive alerts. This documents the difference between those two. Generally `probe_ssl_last_chain_expiry_timestamp_seconds` seems to be what most people would want to use. Signed-off-by: Tobias Guggenmos <[email protected]>
1 parent 0d25513 commit 4084f63

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

prober/prober.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ import (
2525
type ProbeFn func(ctx context.Context, target string, config config.Module, registry *prometheus.Registry, logger log.Logger) bool
2626

2727
const (
28-
helpSSLEarliestCertExpiry = "Returns last SSL chain expiry in unixtime"
29-
helpSSLChainExpiryInTimeStamp = "Returns last SSL chain expiry in timestamp"
28+
helpSSLEarliestCertExpiry = "Returns the earliest expiry of any peer certificate returned by the server as an unix timestamp. This can include certificates that are not validated by TLS clients. In rare server configurations this might return a time in the past, even for valid TLS certificate chains."
29+
helpSSLChainExpiryInTimeStamp = "Returns the earliest expiry of any validated TLS certificate as an unix timestamp. This indicates the time when connections will start to fail, unless a certificate is renewed."
3030
helpProbeTLSInfo = "Returns the TLS version used or NaN when unknown"
3131
)
3232

0 commit comments

Comments
 (0)