code: func (tr *Transport) Lifespan() time.Duration {
  	cert := tr.Provider.Certificate()
  	if cert == nil {
  		return 0
  	}
  
  	now := time.Now()
  	if now.After(cert.NotAfter) {
  		return 0
  	}
  
  	now = now.Add(tr.Before)
  	ls := cert.NotAfter.Sub(now)
  	log.Debugf("   LIFESPAN:\t%s", ls)
  	if ls < 0 {
  		return 0
  	}
  	return ls
  }
docs: // Lifespan returns how much time is left before the transport's
  // certificate expires, or 0 if the certificate is not present or
  // expired.