Preparing report...

Report for github.com/plimble/clover

A+    Excellent!    Found 23 issues across 36 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!


gocyclo100%

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.

No problems detected. Good job!


golint38%

Golint is a linter for Go source code.

    • clover/oauth2/token.go
    • Line 3: warning: exported type CreateAccessTokenRequest should have comment or be unexported (golint)
    • Line 11: warning: exported type TokenGenerator should have comment or be unexported (golint)
    • clover/storage/dynamodb/storage.go
    • Line 13: warning: exported type DynamoDB should have comment or be unexported (golint)
    • Line 18: warning: exported function New should have comment or be unexported (golint)
    • Line 30: warning: exported method DynamoDB.GetClient should have comment or be unexported (golint)
    • Line 58: warning: exported method DynamoDB.GetClientWithSecret should have comment or be unexported (golint)
    • Line 71: warning: exported method DynamoDB.GetRefreshToken should have comment or be unexported (golint)
    • Line 99: warning: exported method DynamoDB.GetAuthorizeCode should have comment or be unexported (golint)
    • Line 127: warning: exported method DynamoDB.GetAccessToken should have comment or be unexported (golint)
    • Line 155: warning: exported method DynamoDB.SaveAccessToken should have comment or be unexported (golint)
    • Line 173: warning: exported method DynamoDB.SaveRefreshToken should have comment or be unexported (golint)
    • Line 191: warning: exported method DynamoDB.SaveAuthorizeCode should have comment or be unexported (golint)
    • Line 209: warning: exported method DynamoDB.IsAvailableScope should have comment or be unexported (golint)
    • Line 238: warning: exported method DynamoDB.RevokeRefreshToken should have comment or be unexported (golint)
    • Line 254: warning: exported method DynamoDB.RevokeAccessToken should have comment or be unexported (golint)
    • clover/oauth2/authcode.go
    • Line 5: warning: exported type AuthorizeCode should have comment or be unexported (golint)
    • Line 16: warning: exported method AuthorizeCode.Valid should have comment or be unexported (golint)
    • clover/oauth2/storage.go
    • Line 3: warning: comment on exported type Storage should be of the form "Storage ..." (with optional leading article) (golint)
    • clover/oauth2/accesstoken.go
    • Line 5: warning: exported type AccessToken should have comment or be unexported (golint)
    • Line 15: warning: exported method AccessToken.Valid should have comment or be unexported (golint)
    • Line 19: warning: exported method AccessToken.HasScope should have comment or be unexported (golint)
    • Line 29: warning: exported type JWTAccessToken should have comment or be unexported (golint)
    • Line 40: warning: exported method JWTAccessToken.Valid should have comment or be unexported (golint)
    • Line 44: warning: exported method JWTAccessToken.HasScope should have comment or be unexported (golint)
    • clover/oauth2/client.go
    • Line 3: warning: exported type Client should have comment or be unexported (golint)
    • Line 14: warning: exported method Client.HasGrantType should have comment or be unexported (golint)
    • clover/oauth2/refreshtoken.go
    • Line 5: warning: exported type RefreshToken should have comment or be unexported (golint)
    • Line 16: warning: exported method RefreshToken.Valid should have comment or be unexported (golint)
    • clover/storage/memory/storage.go
    • Line 11: warning: exported type Scope should have comment or be unexported (golint)
    • Line 20: warning: exported type MemoryStorage should have comment or be unexported (golint)
    • Line 33: warning: exported function NewMemoryStorage should have comment or be unexported (golint)
    • Line 43: warning: exported method MemoryStorage.Flush should have comment or be unexported (golint)
    • Line 51: warning: exported method MemoryStorage.RevokeAccessToken should have comment or be unexported (golint)
    • Line 65: warning: exported method MemoryStorage.SaveAccessToken should have comment or be unexported (golint)
    • Line 73: warning: exported method MemoryStorage.GetAccessToken should have comment or be unexported (golint)
    • Line 85: warning: exported method MemoryStorage.RevokeRefreshToken should have comment or be unexported (golint)
    • Line 99: warning: exported method MemoryStorage.SaveRefreshToken should have comment or be unexported (golint)
    • Line 107: warning: exported method MemoryStorage.GetRefreshToken should have comment or be unexported (golint)
    • Line 119: warning: exported method MemoryStorage.SaveAuthorizeCode should have comment or be unexported (golint)
    • Line 127: warning: exported method MemoryStorage.GetAuthorizeCode should have comment or be unexported (golint)
    • Line 139: warning: exported method MemoryStorage.GetClientWithSecret should have comment or be unexported (golint)
    • Line 155: warning: exported method MemoryStorage.GetClient should have comment or be unexported (golint)
    • Line 167: warning: exported method MemoryStorage.IsAvailableScope should have comment or be unexported (golint)
    • clover/oauth2/verify/handler.go
    • Line 10: warning: exported type VerifyHandlerRequest should have comment or be unexported (golint)
    • Line 15: warning: exported type VerifyHandler should have comment or be unexported (golint)
    • Line 19: warning: exported function New should have comment or be unexported (golint)
    • Line 51: warning: exported method VerifyHandler.Verify should have comment or be unexported (golint)
    • clover/oauth2/token_hmac.go
    • Line 18: warning: exported var TokenEntropy should have comment or be unexported (golint)
    • Line 29: warning: exported function NewHMACTokenGenerator should have comment or be unexported (golint)
    • Line 33: warning: comment on exported method HMACTokenGenerator.CreateAccessToken should be of the form "CreateAccessToken ..." (golint)
    • Line 105: warning: exported method HMACTokenGenerator.Signature should have comment or be unexported (golint)
    • Line 115: warning: exported method HMACTokenGenerator.CreateCode should have comment or be unexported (golint)
    • Line 119: warning: exported method HMACTokenGenerator.CreateRefreshToken should have comment or be unexported (golint)
    • clover/oauth2/token_jwt.go
    • Line 18: warning: exported type JWTTokenGenerator should have comment or be unexported (golint)
    • Line 22: warning: exported function NewJWTTokenGenerator should have comment or be unexported (golint)
    • Line 37: warning: exported method JWTTokenGenerator.CreateAccessToken should have comment or be unexported (golint)
    • Line 64: warning: exported method JWTTokenGenerator.CreateCode should have comment or be unexported (golint)
    • Line 68: warning: exported method JWTTokenGenerator.CreateRefreshToken should have comment or be unexported (golint)
    • Line 72: warning: exported function ClaimJWTAccessToken should have comment or be unexported (golint)
    • clover/oauth2/token/handler.go
    • Line 13: warning: exported type ProcessFunc should have comment or be unexported (golint)
    • Line 15: warning: exported type TokenHandlerRequest should have comment or be unexported (golint)
    • Line 22: warning: exported type TokenHandlerResponse should have comment or be unexported (golint)
    • Line 24: warning: exported type TokenHandler should have comment or be unexported (golint)
    • Line 30: warning: exported function New should have comment or be unexported (golint)
    • Line 34: warning: exported method TokenHandler.RegisterGrantType should have comment or be unexported (golint)
    • Line 72: warning: exported method TokenHandler.RequestToken should have comment or be unexported (golint)
    • clover/oauth2/errors.go
    • Line 8: warning: exported var Logger should have comment or be unexported (golint)
    • Line 10: warning: exported type AppErr should have comment or be unexported (golint)
    • Line 17: warning: exported function Error should have comment or be unexported (golint)
    • Line 21: warning: exported function InvalidClient should have comment or be unexported (golint)
    • Line 25: warning: exported function ServerError should have comment or be unexported (golint)
    • Line 29: warning: exported function UnknownError should have comment or be unexported (golint)
    • Line 33: warning: exported function NotFound should have comment or be unexported (golint)
    • Line 38: warning: exported method AppErr.Cause should have comment or be unexported (golint)
    • Line 39: warning: exported method AppErr.WithCause should have comment or be unexported (golint)
    • Line 44: warning: exported method AppErr.MarshalLogObject should have comment or be unexported (golint)
    • Line 54: warning: exported function IsNotFound should have comment or be unexported (golint)
    • clover/oauth2/response.go
    • Line 8: warning: exported function WriteJson should have comment or be unexported (golint)
    • Line 18: warning: exported function WriteJsonError should have comment or be unexported (golint)
    • clover/oauth2/token/grant_client.go
    • Line 9: warning: exported type ClientCredentialsGrantType should have comment or be unexported (golint)
    • Line 13: warning: exported method ClientCredentialsGrantType.GrantRequest should have comment or be unexported (golint)
    • Line 25: warning: exported method ClientCredentialsGrantType.Name should have comment or be unexported (golint)
    • Line 29: warning: exported method ClientCredentialsGrantType.CreateToken should have comment or be unexported (golint)
    • clover/oauth2/token/grant_code.go
    • Line 9: warning: exported type AuthorizeCodeGrantType should have comment or be unexported (golint)
    • Line 14: warning: exported method AuthorizeCodeGrantType.GrantRequest should have comment or be unexported (golint)
    • Line 56: warning: exported method AuthorizeCodeGrantType.Name should have comment or be unexported (golint)
    • Line 60: warning: exported method AuthorizeCodeGrantType.CreateToken should have comment or be unexported (golint)
    • clover/oauth2/token/grant_password.go
    • Line 9: warning: exported type PassowrdGrantType should have comment or be unexported (golint)
    • Line 15: warning: exported method PassowrdGrantType.GrantRequest should have comment or be unexported (golint)
    • Line 46: warning: exported method PassowrdGrantType.Name should have comment or be unexported (golint)
    • Line 50: warning: exported method PassowrdGrantType.CreateToken should have comment or be unexported (golint)
    • clover/oauth2/token/grant_refresh.go
    • Line 9: warning: exported type RefreshTokenGrantType should have comment or be unexported (golint)
    • Line 11: warning: exported method RefreshTokenGrantType.GrantRequest should have comment or be unexported (golint)
    • Line 44: warning: exported method RefreshTokenGrantType.Name should have comment or be unexported (golint)
    • Line 48: warning: exported method RefreshTokenGrantType.CreateToken should have comment or be unexported (golint)
    • clover/oauth2/user.go
    • Line 3: warning: exported type User should have comment or be unexported (golint)
    • Line 9: warning: comment on exported type UserService should be of the form "UserService ..." (with optional leading article) (golint)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


ineffassign97%

IneffAssign detects ineffectual assignments in Go code.


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!