Browse Source

chore: update CI to Go 1.18 / 1.19, update webtransport-go to v0.1.0

pull/1737/head
Marten Seemann 2 years ago
parent
commit
60a40710ab
  1. 8
      p2p/transport/webtransport/cert_manager.go

8
p2p/transport/webtransport/cert_manager.go

@ -40,10 +40,10 @@ func newCertConfig(start, end time.Time) (*certConfig, error) {
}
// Certificate renewal logic:
// 1. On startup, we generate one cert that is valid from now (-1h, to allow for clock skew), and another
// cert that is valid from the expiry date of the first certificate (again, with allowance for clock skew).
// 2. Once we reach 1h before expiry of the first certificate, we switch over to the second certificate.
// At the same time, we stop advertising the certhash of the first cert and generate the next cert.
// 1. On startup, we generate one cert that is valid from now (-1h, to allow for clock skew), and another
// cert that is valid from the expiry date of the first certificate (again, with allowance for clock skew).
// 2. Once we reach 1h before expiry of the first certificate, we switch over to the second certificate.
// At the same time, we stop advertising the certhash of the first cert and generate the next cert.
type certManager struct {
clock clock.Clock
ctx context.Context

Loading…
Cancel
Save