diff options
author | Wim <wim@42.be> | 2022-11-27 00:42:16 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-27 00:42:16 +0100 |
commit | 4fd0a7672777f0ed15692ae2ba47838208537558 (patch) | |
tree | b119834a8b9ee78aa8f1b2ad05efa7da50516cbf /vendor/golang.org/x/crypto/acme | |
parent | 6da9d567dc9195e9a5211f23a6795a41f56a1bfc (diff) | |
download | matterbridge-msglm-4fd0a7672777f0ed15692ae2ba47838208537558.tar.gz matterbridge-msglm-4fd0a7672777f0ed15692ae2ba47838208537558.tar.bz2 matterbridge-msglm-4fd0a7672777f0ed15692ae2ba47838208537558.zip |
Update dependencies (#1929)
Diffstat (limited to 'vendor/golang.org/x/crypto/acme')
-rw-r--r-- | vendor/golang.org/x/crypto/acme/acme.go | 8 | ||||
-rw-r--r-- | vendor/golang.org/x/crypto/acme/autocert/autocert.go | 4 | ||||
-rw-r--r-- | vendor/golang.org/x/crypto/acme/autocert/cache.go | 5 | ||||
-rw-r--r-- | vendor/golang.org/x/crypto/acme/http.go | 6 | ||||
-rw-r--r-- | vendor/golang.org/x/crypto/acme/rfc8555.go | 5 | ||||
-rw-r--r-- | vendor/golang.org/x/crypto/acme/types.go | 4 |
6 files changed, 15 insertions, 17 deletions
diff --git a/vendor/golang.org/x/crypto/acme/acme.go b/vendor/golang.org/x/crypto/acme/acme.go index df574308..aaafea2b 100644 --- a/vendor/golang.org/x/crypto/acme/acme.go +++ b/vendor/golang.org/x/crypto/acme/acme.go @@ -88,7 +88,7 @@ type Client struct { // // The following algorithms are supported: // RS256, ES256, ES384 and ES512. - // See RFC7518 for more details about the algorithms. + // See RFC 7518 for more details about the algorithms. Key crypto.Signer // HTTPClient optionally specifies an HTTP client to use @@ -310,9 +310,9 @@ func (c *Client) UpdateReg(ctx context.Context, acct *Account) (*Account, error) // On success client's Key is updated which is not concurrency safe. // On failure an error will be returned. // The new key is already registered with the ACME provider if the following is true: -// - error is of type acme.Error -// - StatusCode should be 409 (Conflict) -// - Location header will have the KID of the associated account +// - error is of type acme.Error +// - StatusCode should be 409 (Conflict) +// - Location header will have the KID of the associated account // // More about account key rollover can be found at // https://tools.ietf.org/html/rfc8555#section-7.3.5. diff --git a/vendor/golang.org/x/crypto/acme/autocert/autocert.go b/vendor/golang.org/x/crypto/acme/autocert/autocert.go index 0061c288..6b4cdf40 100644 --- a/vendor/golang.org/x/crypto/acme/autocert/autocert.go +++ b/vendor/golang.org/x/crypto/acme/autocert/autocert.go @@ -463,7 +463,7 @@ func (m *Manager) cert(ctx context.Context, ck certKey) (*tls.Certificate, error leaf: cert.Leaf, } m.state[ck] = s - go m.startRenew(ck, s.key, s.leaf.NotAfter) + m.startRenew(ck, s.key, s.leaf.NotAfter) return cert, nil } @@ -609,7 +609,7 @@ func (m *Manager) createCert(ctx context.Context, ck certKey) (*tls.Certificate, } state.cert = der state.leaf = leaf - go m.startRenew(ck, state.key, state.leaf.NotAfter) + m.startRenew(ck, state.key, state.leaf.NotAfter) return state.tlscert() } diff --git a/vendor/golang.org/x/crypto/acme/autocert/cache.go b/vendor/golang.org/x/crypto/acme/autocert/cache.go index 3156a081..758ab12c 100644 --- a/vendor/golang.org/x/crypto/acme/autocert/cache.go +++ b/vendor/golang.org/x/crypto/acme/autocert/cache.go @@ -7,7 +7,6 @@ package autocert import ( "context" "errors" - "io/ioutil" "os" "path/filepath" ) @@ -48,7 +47,7 @@ func (d DirCache) Get(ctx context.Context, name string) ([]byte, error) { done = make(chan struct{}) ) go func() { - data, err = ioutil.ReadFile(name) + data, err = os.ReadFile(name) close(done) }() select { @@ -119,7 +118,7 @@ func (d DirCache) Delete(ctx context.Context, name string) error { // writeTempFile writes b to a temporary file, closes the file and returns its path. func (d DirCache) writeTempFile(prefix string, b []byte) (name string, reterr error) { // TempFile uses 0600 permissions - f, err := ioutil.TempFile(string(d), prefix) + f, err := os.CreateTemp(string(d), prefix) if err != nil { return "", err } diff --git a/vendor/golang.org/x/crypto/acme/http.go b/vendor/golang.org/x/crypto/acme/http.go index 2b4c1a10..58836e5d 100644 --- a/vendor/golang.org/x/crypto/acme/http.go +++ b/vendor/golang.org/x/crypto/acme/http.go @@ -12,7 +12,7 @@ import ( "encoding/json" "errors" "fmt" - "io/ioutil" + "io" "math/big" "net/http" "strconv" @@ -156,7 +156,7 @@ func (c *Client) get(ctx context.Context, url string, ok resOkay) (*http.Respons } } -// postAsGet is POST-as-GET, a replacement for GET in RFC8555 +// postAsGet is POST-as-GET, a replacement for GET in RFC 8555 // as described in https://tools.ietf.org/html/rfc8555#section-6.3. // It makes a POST request in KID form with zero JWS payload. // See nopayload doc comments in jws.go. @@ -310,7 +310,7 @@ func isRetriable(code int) bool { func responseError(resp *http.Response) error { // don't care if ReadAll returns an error: // json.Unmarshal will fail in that case anyway - b, _ := ioutil.ReadAll(resp.Body) + b, _ := io.ReadAll(resp.Body) e := &wireError{Status: resp.StatusCode} if err := json.Unmarshal(b, e); err != nil { // this is not a regular error response: diff --git a/vendor/golang.org/x/crypto/acme/rfc8555.go b/vendor/golang.org/x/crypto/acme/rfc8555.go index 940e70b8..ee24dfde 100644 --- a/vendor/golang.org/x/crypto/acme/rfc8555.go +++ b/vendor/golang.org/x/crypto/acme/rfc8555.go @@ -13,7 +13,6 @@ import ( "errors" "fmt" "io" - "io/ioutil" "net/http" "time" ) @@ -390,7 +389,7 @@ func (c *Client) fetchCertRFC(ctx context.Context, url string, bundle bool) ([][ // Get all the bytes up to a sane maximum. // Account very roughly for base64 overhead. const max = maxCertChainSize + maxCertChainSize/33 - b, err := ioutil.ReadAll(io.LimitReader(res.Body, max+1)) + b, err := io.ReadAll(io.LimitReader(res.Body, max+1)) if err != nil { return nil, fmt.Errorf("acme: fetch cert response stream: %v", err) } @@ -469,7 +468,7 @@ func (c *Client) ListCertAlternates(ctx context.Context, url string) ([]string, // We don't need the body but we need to discard it so we don't end up // preventing keep-alive - if _, err := io.Copy(ioutil.Discard, res.Body); err != nil { + if _, err := io.Copy(io.Discard, res.Body); err != nil { return nil, fmt.Errorf("acme: cert alternates response stream: %v", err) } alts := linkHeader(res.Header, "alternate") diff --git a/vendor/golang.org/x/crypto/acme/types.go b/vendor/golang.org/x/crypto/acme/types.go index 67b82520..4888726f 100644 --- a/vendor/golang.org/x/crypto/acme/types.go +++ b/vendor/golang.org/x/crypto/acme/types.go @@ -297,7 +297,7 @@ type Directory struct { // CAA consists of lowercase hostname elements, which the ACME server // recognises as referring to itself for the purposes of CAA record validation - // as defined in RFC6844. + // as defined in RFC 6844. CAA []string // ExternalAccountRequired indicates that the CA requires for all account-related @@ -440,7 +440,7 @@ func DomainIDs(names ...string) []AuthzID { // IPIDs creates a slice of AuthzID with "ip" identifier type. // Each element of addr is textual form of an address as defined -// in RFC1123 Section 2.1 for IPv4 and in RFC5952 Section 4 for IPv6. +// in RFC 1123 Section 2.1 for IPv4 and in RFC 5952 Section 4 for IPv6. func IPIDs(addr ...string) []AuthzID { a := make([]AuthzID, len(addr)) for i, v := range addr { |