diff options
| -rw-r--r-- | acme/acme.go | 7 | ||||
| -rw-r--r-- | acme/autocert/internal/acmetest/ca.go | 12 |
2 files changed, 0 insertions, 19 deletions
diff --git a/acme/acme.go b/acme/acme.go index cfb1dfd..3902b94 100644 --- a/acme/acme.go +++ b/acme/acme.go @@ -33,7 +33,6 @@ import ( "encoding/base64" "encoding/hex" "encoding/json" - "encoding/pem" "errors" "fmt" "math/big" @@ -816,11 +815,5 @@ func tlsChallengeCert(san []string, opt []CertOption) (tls.Certificate, error) { }, nil } -// encodePEM returns b encoded as PEM with block of type typ. -func encodePEM(typ string, b []byte) []byte { - pb := &pem.Block{Type: typ, Bytes: b} - return pem.EncodeToMemory(pb) -} - // timeNow is time.Now, except in tests which can mess with it. var timeNow = time.Now diff --git a/acme/autocert/internal/acmetest/ca.go b/acme/autocert/internal/acmetest/ca.go index 504a9a0..28e6e7d 100644 --- a/acme/autocert/internal/acmetest/ca.go +++ b/acme/autocert/internal/acmetest/ca.go @@ -782,15 +782,3 @@ func decodePayload(v interface{}, r io.Reader) error { func challengeToken(domain, challType string, authzID int) string { return fmt.Sprintf("token-%s-%s-%d", domain, challType, authzID) } - -func unique(a []string) []string { - seen := make(map[string]bool) - var res []string - for _, s := range a { - if s != "" && !seen[s] { - seen[s] = true - res = append(res, s) - } - } - return res -} |
