Preparing report...

Report for github.com/xenolf/lego

A+    Excellent!    Found 54 issues across 409 files

Tweet

gofmt100%

Gofmt formats Go programs. We run gofmt -s on your code, where -s is for the "simplify" command

No problems detected. Good job!


go_vet100%

go vet examines Go source code and reports suspicious constructs, such as Printf calls whose arguments do not align with the format string.

No problems detected. Good job!


gocyclo99%

Gocyclo calculates cyclomatic complexities of functions in Go source code. The cyclomatic complexity of a function is calculated according to the following rules: 1 is the base complexity of a function +1 for each 'if', 'for', 'case', '&&' or '||' Go Report Card warns on functions with cyclomatic complexity > 15.


golint87%

Golint is a linter for Go source code.

    • lego/providers/dns/yandex/internal/client.go
    • Line 19: warning: exported type Client should have comment or be unexported (golint)
    • Line 25: warning: exported function NewClient should have comment or be unexported (golint)
    • Line 36: warning: exported method Client.AddRecord should have comment or be unexported (golint)
    • Line 60: warning: exported method Client.RemoveRecord should have comment or be unexported (golint)
    • Line 80: warning: exported method Client.GetRecords should have comment or be unexported (golint)
    • lego/certcrypto/crypto.go
    • Line 52: warning: exported type DERCertificateBytes should have comment or be unexported (golint)
    • Line 113: warning: exported function GeneratePrivateKey should have comment or be unexported (golint)
    • Line 130: warning: exported function GenerateCSR should have comment or be unexported (golint)
    • Line 146: warning: exported function PEMEncode should have comment or be unexported (golint)
    • Line 150: warning: exported function PEMBlock should have comment or be unexported (golint)
    • Line 176: warning: exported function PemDecodeTox509CSR should have comment or be unexported (golint)
    • Line 201: warning: exported function ExtractDomains should have comment or be unexported (golint)
    • Line 218: warning: exported function ExtractDomainsCSR should have comment or be unexported (golint)
    • Line 247: warning: exported function GeneratePemCert should have comment or be unexported (golint)
    • lego/providers/dns/clouddns/internal/models.go
    • Line 3: warning: exported type APIError should have comment or be unexported (golint)
    • Line 7: warning: exported type ErrorContent should have comment or be unexported (golint)
    • Line 12: warning: exported type Authorization should have comment or be unexported (golint)
    • Line 17: warning: exported type AuthResponse should have comment or be unexported (golint)
    • Line 21: warning: exported type Auth should have comment or be unexported (golint)
    • Line 26: warning: exported type SearchQuery should have comment or be unexported (golint)
    • Line 41: warning: exported type Sort should have comment or be unexported (golint)
    • Line 46: warning: exported type SearchResponse should have comment or be unexported (golint)
    • Line 53: warning: exported type Domain should have comment or be unexported (golint)
    • Line 68: warning: exported type DomainInfo should have comment or be unexported (golint)
    • lego/providers/dns/checkdomain/client.go
    • Line 32: warning: exported type DomainListingResponse should have comment or be unexported (golint)
    • Line 40: warning: exported type EmbeddedDomainList should have comment or be unexported (golint)
    • Line 44: warning: exported type Domain should have comment or be unexported (golint)
    • Line 49: warning: exported type DomainResponse should have comment or be unexported (golint)
    • Line 57: warning: exported type NameserverResponse should have comment or be unexported (golint)
    • Line 63: warning: exported type NameserverGeneral should have comment or be unexported (golint)
    • Line 69: warning: exported type NameserverSOA should have comment or be unexported (golint)
    • Line 77: warning: exported type Nameserver should have comment or be unexported (golint)
    • Line 81: warning: exported type RecordListingResponse should have comment or be unexported (golint)
    • Line 89: warning: exported type EmbeddedRecordList should have comment or be unexported (golint)
    • Line 93: warning: exported type Record should have comment or be unexported (golint)
    • lego/challenge/http01/http_challenge.go
    • Line 12: warning: exported type ValidateFunc should have comment or be unexported (golint)
    • Line 19: warning: exported type Challenge should have comment or be unexported (golint)
    • Line 25: warning: exported function NewChallenge should have comment or be unexported (golint)
    • Line 33: warning: exported method Challenge.SetProvider should have comment or be unexported (golint)
    • Line 37: warning: exported method Challenge.Solve should have comment or be unexported (golint)
    • lego/challenge/dns01/nameserver.go
    • Line 59: warning: exported function AddDNSTimeout should have comment or be unexported (golint)
    • Line 66: warning: exported function AddRecursiveNameservers should have comment or be unexported (golint)
    • Line 83: warning: exported function ParseNameservers should have comment or be unexported (golint)
    • lego/cmd/certs_storage.go
    • Line 57: warning: exported method CertificatesStorage.CreateRootFolder should have comment or be unexported (golint)
    • Line 64: warning: exported method CertificatesStorage.CreateArchiveFolder should have comment or be unexported (golint)
    • Line 71: warning: exported method CertificatesStorage.GetRootPath should have comment or be unexported (golint)
    • Line 75: warning: exported method CertificatesStorage.SaveResource should have comment or be unexported (golint)
    • Line 121: warning: exported method CertificatesStorage.ReadResource should have comment or be unexported (golint)
    • Line 135: warning: exported method CertificatesStorage.ExistsFile should have comment or be unexported (golint)
    • Line 146: warning: exported method CertificatesStorage.ReadFile should have comment or be unexported (golint)
    • Line 150: warning: exported method CertificatesStorage.GetFileName should have comment or be unexported (golint)
    • Line 155: warning: exported method CertificatesStorage.ReadCertificate should have comment or be unexported (golint)
    • Line 165: warning: exported method CertificatesStorage.WriteFile should have comment or be unexported (golint)
    • Line 178: warning: exported method CertificatesStorage.MoveToArchive should have comment or be unexported (golint)
    • lego/registration/registar.go
    • Line 20: warning: exported type RegisterOptions should have comment or be unexported (golint)
    • Line 24: warning: exported type RegisterEABOptions should have comment or be unexported (golint)
    • Line 30: warning: exported type Registrar should have comment or be unexported (golint)
    • Line 35: warning: exported function NewRegistrar should have comment or be unexported (golint)
    • lego/providers/dns/autodns/client.go
    • Line 18: warning: exported type ResponseMessage should have comment or be unexported (golint)
    • Line 26: warning: exported type ResponseStatus should have comment or be unexported (golint)
    • Line 32: warning: exported type ResponseObject should have comment or be unexported (golint)
    • Line 39: warning: exported type DataZoneResponse should have comment or be unexported (golint)
    • Line 65: warning: exported type ZoneStream should have comment or be unexported (golint)
    • lego/cmd/accounts_storage.go
    • Line 97: warning: exported method AccountsStorage.ExistsAccountFilePath should have comment or be unexported (golint)
    • Line 107: warning: exported method AccountsStorage.GetRootPath should have comment or be unexported (golint)
    • Line 111: warning: exported method AccountsStorage.GetRootUserPath should have comment or be unexported (golint)
    • Line 115: warning: exported method AccountsStorage.GetUserID should have comment or be unexported (golint)
    • Line 119: warning: exported method AccountsStorage.Save should have comment or be unexported (golint)
    • Line 128: warning: exported method AccountsStorage.LoadAccount should have comment or be unexported (golint)
    • Line 158: warning: exported method AccountsStorage.GetPrivateKey should have comment or be unexported (golint)
    • lego/providers/dns/wedos/internal/client.go
    • Line 29: warning: exported type ResponsePayload should have comment or be unexported (golint)
    • Line 38: warning: exported type DNSRow should have comment or be unexported (golint)
    • Line 46: warning: exported type DNSRowRequest should have comment or be unexported (golint)
    • Line 55: warning: exported type APIRequest should have comment or be unexported (golint)
    • Line 62: warning: exported type Client should have comment or be unexported (golint)
    • Line 69: warning: exported function NewClient should have comment or be unexported (golint)
    • Line 161: warning: exported method Client.Ping should have comment or be unexported (golint)
    • lego/challenge/tlsalpn01/tls_alpn_challenge.go
    • Line 22: warning: exported type ValidateFunc should have comment or be unexported (golint)
    • Line 24: warning: exported type Challenge should have comment or be unexported (golint)
    • Line 30: warning: exported function NewChallenge should have comment or be unexported (golint)
    • Line 38: warning: exported method Challenge.SetProvider should have comment or be unexported (golint)
    • lego/challenge/dns01/dns_challenge.go
    • Line 30: warning: exported type ValidateFunc should have comment or be unexported (golint)
    • Line 32: warning: exported type ChallengeOption should have comment or be unexported (golint)
    • Line 54: warning: exported function NewChallenge should have comment or be unexported (golint)
    • Line 102: warning: exported method Challenge.Solve should have comment or be unexported (golint)
    • Line 163: warning: exported method Challenge.Sequential should have comment or be unexported (golint)
    • lego/lego/client_config.go
    • Line 37: warning: exported type Config should have comment or be unexported (golint)
    • Line 45: warning: exported function NewConfig should have comment or be unexported (golint)
    • Line 57: warning: exported type CertificateConfig should have comment or be unexported (golint)
    • lego/providers/dns/yandex/internal/types.go
    • Line 3: warning: exported type Record should have comment or be unexported (golint)
    • Line 13: warning: exported type AddResponse should have comment or be unexported (golint)
    • Line 20: warning: exported type RemoveResponse should have comment or be unexported (golint)
    • Line 27: warning: exported type ListResponse should have comment or be unexported (golint)
    • lego/e2e/loader/loader.go
    • Line 26: warning: exported type CmdOption should have comment or be unexported (golint)
    • Line 33: warning: exported type EnvLoader should have comment or be unexported (golint)
    • Line 40: warning: exported method EnvLoader.MainTest should have comment or be unexported (golint)
    • Line 91: warning: exported method EnvLoader.RunLego should have comment or be unexported (golint)
    • Line 296: warning: exported function CleanLegoFiles should have comment or be unexported (golint)
    • lego/internal/dnsdocs/generator.go
    • Line 38: warning: exported type Model should have comment or be unexported (golint)
    • Line 51: warning: exported type Configuration should have comment or be unexported (golint)
    • Line 56: warning: exported type Links should have comment or be unexported (golint)
    • Line 61: warning: exported type Providers should have comment or be unexported (golint)
    • lego/providers/dns/internal/rimuhosting/model.go
    • Line 5: warning: exported type ActionParameter should have comment or be unexported (golint)
    • Line 31: warning: exported type APIError should have comment or be unexported (golint)
    • Line 40: warning: exported type DNSAPIResult should have comment or be unexported (golint)
    • Line 47: warning: exported type ResultCounts should have comment or be unexported (golint)
    • Line 54: warning: exported type Actions should have comment or be unexported (golint)
    • Line 58: warning: exported type Action should have comment or be unexported (golint)
    • Line 65: warning: exported type Record should have comment or be unexported (golint)
    • lego/challenge/challenges.go
    • Line 29: warning: exported function FindChallenge should have comment or be unexported (golint)
    • Line 39: warning: exported function GetTargetedDomain should have comment or be unexported (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


misspell99%

Misspell Finds commonly misspelled English words