Preparing report...

Report for github.com/sumup-oss/vaulted

A+    Excellent!    Found 59 issues across 94 files

Tweet

gofmt98%

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


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!


golint39%

Golint is a linter for Go source code.

    • vaulted/pkg/pkcs7/service.go
    • Line 33: warning: exported type Service should have comment or be unexported (golint)
    • Line 35: warning: exported function NewPkcs7Service should have comment or be unexported (golint)
    • Line 66: warning: exported method Service.Unpad should have comment or be unexported (golint)
    • vaulted/pkg/terraform_encryption_migration/service.go
    • Line 15: warning: don't use an underscore in package name (golint)
    • Line 43: warning: exported type Service should have comment or be unexported (golint)
    • Line 47: warning: exported function NewTerraformEncryptionMigrationService should have comment or be unexported (golint)
    • Line 342: warning: exported method Service.ConvertIniContentToV1ResourceHCL should have comment or be unexported (golint)
    • vaulted/pkg/vaulted/content/test/testing.go
    • Line 24: warning: exported type MockEncryptedContentService should have comment or be unexported (golint)
    • Line 28: warning: exported method MockEncryptedContentService.Decrypt should have comment or be unexported (golint)
    • Line 43: warning: exported method MockEncryptedContentService.Deserialize should have comment or be unexported (golint)
    • Line 55: warning: exported method MockEncryptedContentService.Encrypt should have comment or be unexported (golint)
    • Line 70: warning: exported method MockEncryptedContentService.Serialize should have comment or be unexported (golint)
    • vaulted/pkg/vaulted/content/v1_encrypted_content_service.go
    • Line 23: warning: exported type V1EncryptedContentService should have comment or be unexported (golint)
    • Line 28: warning: exported function NewV1EncryptedContentService should have comment or be unexported (golint)
    • Line 37: warning: exported method V1EncryptedContentService.Encrypt should have comment or be unexported (golint)
    • Line 54: warning: exported method V1EncryptedContentService.Decrypt should have comment or be unexported (golint)
    • vaulted/pkg/vaulted/passphrase/encrypted_passphrase_service.go
    • Line 24: warning: exported type EncryptedPassphraseService should have comment or be unexported (golint)
    • Line 29: warning: exported function NewEncryptedPassphraseService should have comment or be unexported (golint)
    • Line 39: warning: exported method EncryptedPassphraseService.Serialize should have comment or be unexported (golint)
    • Line 43: warning: exported method EncryptedPassphraseService.Deserialize should have comment or be unexported (golint)
    • Line 57: warning: exported method EncryptedPassphraseService.Encrypt should have comment or be unexported (golint)
    • Line 75: warning: exported method EncryptedPassphraseService.Decrypt should have comment or be unexported (golint)
    • Line 91: warning: exported method EncryptedPassphraseService.GeneratePassphrase should have comment or be unexported (golint)
    • vaulted/cmd/external_interfaces/external_interfaces.go
    • Line 15: warning: don't use an underscore in package name (golint)
    • Line 32: warning: exported type HclService should have comment or be unexported (golint)
    • Line 36: warning: exported type Base64Service should have comment or be unexported (golint)
    • Line 41: warning: exported type EncryptedPassphraseService should have comment or be unexported (golint)
    • Line 52: warning: exported type EncryptedPayloadService should have comment or be unexported (golint)
    • Line 59: warning: exported type EncryptedContentService should have comment or be unexported (golint)
    • Line 72: warning: exported type TerraformEncryptionMigrationService should have comment or be unexported (golint)
    • Line 99: warning: exported type RsaService should have comment or be unexported (golint)
    • Line 106: warning: exported type AesService should have comment or be unexported (golint)
    • Line 113: warning: exported type IniService should have comment or be unexported (golint)
    • vaulted/pkg/rsa/test/testing.go
    • Line 24: warning: exported type MockRsaService should have comment or be unexported (golint)
    • Line 28: warning: exported method MockRsaService.ReadPublicKeyFromPath should have comment or be unexported (golint)
    • Line 40: warning: exported method MockRsaService.ReadPrivateKeyFromPath should have comment or be unexported (golint)
    • Line 52: warning: exported method MockRsaService.EncryptPKCS1v15 should have comment or be unexported (golint)
    • Line 65: warning: exported method MockRsaService.DecryptPKCS1v15 should have comment or be unexported (golint)
    • vaulted/pkg/vaulted/utils.go
    • Line 25: warning: exported function Contains should have comment or be unexported (golint)
    • Line 35: warning: exported function SanitizeFilename should have comment or be unexported (golint)
    • vaulted/pkg/aes/test/testing.go
    • Line 21: warning: exported type MockAesService should have comment or be unexported (golint)
    • Line 25: warning: exported method MockAesService.EncryptCBC should have comment or be unexported (golint)
    • Line 37: warning: exported method MockAesService.DecryptCBC should have comment or be unexported (golint)
    • Line 49: warning: exported method MockAesService.EncryptGCM should have comment or be unexported (golint)
    • Line 61: warning: exported method MockAesService.DecryptGCM should have comment or be unexported (golint)
    • vaulted/pkg/hcl/err.go
    • Line 23: warning: exported type ParseErr should have comment or be unexported (golint)
    • Line 27: warning: exported function NewParseErr should have comment or be unexported (golint)
    • Line 41: warning: exported type Err should have comment or be unexported (golint)
    • Line 45: warning: exported function NewErr should have comment or be unexported (golint)
    • vaulted/pkg/ini/service.go
    • Line 27: warning: exported type Service should have comment or be unexported (golint)
    • Line 29: warning: exported function NewIniService should have comment or be unexported (golint)
    • Line 33: warning: exported method Service.ReadIniAtPath should have comment or be unexported (golint)
    • Line 48: warning: exported method Service.ParseIniFileContents should have comment or be unexported (golint)
    • vaulted/internal/e2e/e2e.go
    • Line 35: warning: exported type Build should have comment or be unexported (golint)
    • Line 40: warning: exported function NewBuild should have comment or be unexported (golint)
    • Line 59: warning: exported method Build.Run should have comment or be unexported (golint)
    • Line 74: warning: exported function GoBuild should have comment or be unexported (golint)
    • vaulted/pkg/aes/service.go
    • Line 55: warning: exported type Service should have comment or be unexported (golint)
    • Line 59: warning: exported function NewAesService should have comment or be unexported (golint)
    • Line 65: warning: exported method Service.EncryptCBC should have comment or be unexported (golint)
    • Line 99: warning: exported method Service.DecryptCBC should have comment or be unexported (golint)
    • Line 133: warning: exported method Service.EncryptGCM should have comment or be unexported (golint)
    • Line 168: warning: exported method Service.DecryptGCM should have comment or be unexported (golint)
    • vaulted/pkg/terraform_encryption_migration/test/testing.go
    • Line 27: warning: exported type MockTerraformEncryptionMigrationService should have comment or be unexported (golint)
    • Line 31: warning: exported method MockTerraformEncryptionMigrationService.MigrateEncryptedTerraformResourceHcl should have comment or be unexported (golint)
    • Line 59: warning: exported method MockTerraformEncryptionMigrationService.RotateOrRekeyEncryptedTerraformResourceHcl should have comment or be unexported (golint)
    • vaulted/pkg/vaulted/payload/encrypted_payload_service.go
    • Line 26: warning: exported const EncryptionPayloadSeparator should have comment (or a comment on this block) or be unexported (golint)
    • Line 39: warning: exported type EncryptedPayloadService should have comment or be unexported (golint)
    • Line 45: warning: exported function NewEncryptedPayloadService should have comment or be unexported (golint)
    • Line 57: warning: exported method EncryptedPayloadService.Serialize should have comment or be unexported (golint)
    • Line 104: warning: exported method EncryptedPayloadService.Deserialize should have comment or be unexported (golint)
    • Line 160: warning: exported method EncryptedPayloadService.Encrypt should have comment or be unexported (golint)
    • Line 180: warning: exported method EncryptedPayloadService.Decrypt should have comment or be unexported (golint)
    • vaulted/pkg/vaulted/passphrase/test/testing.go
    • Line 25: warning: exported type MockEncryptedPassphraseService should have comment or be unexported (golint)
    • Line 29: warning: exported method MockEncryptedPassphraseService.Decrypt should have comment or be unexported (golint)
    • Line 44: warning: exported method MockEncryptedPassphraseService.Deserialize should have comment or be unexported (golint)
    • Line 56: warning: exported method MockEncryptedPassphraseService.Encrypt should have comment or be unexported (golint)
    • Line 71: warning: exported method MockEncryptedPassphraseService.GeneratePassphrase should have comment or be unexported (golint)
    • Line 83: warning: exported method MockEncryptedPassphraseService.Serialize should have comment or be unexported (golint)
    • vaulted/pkg/pkcs7/test/testing.go
    • Line 21: warning: exported type MockPkcs7Service should have comment or be unexported (golint)
    • Line 25: warning: exported method MockPkcs7Service.Pad should have comment or be unexported (golint)
    • Line 37: warning: exported method MockPkcs7Service.Unpad should have comment or be unexported (golint)
    • vaulted/pkg/ini/section.go
    • Line 17: warning: exported type Section should have comment or be unexported (golint)
    • Line 22: warning: exported function NewIniSection should have comment or be unexported (golint)
    • vaulted/pkg/vaulted/content/legacy_encrypted_content_service.go
    • Line 23: warning: exported type LegacyEncryptedContentService should have comment or be unexported (golint)
    • Line 28: warning: exported function NewLegacyEncryptedContentService should have comment or be unexported (golint)
    • Line 40: warning: exported method LegacyEncryptedContentService.Encrypt should have comment or be unexported (golint)
    • Line 57: warning: exported method LegacyEncryptedContentService.Decrypt should have comment or be unexported (golint)
    • vaulted/pkg/vaulted/header/header_service.go
    • Line 50: warning: exported type HeaderService should have comment or be unexported (golint)
    • Line 52: warning: exported function NewHeaderService should have comment or be unexported (golint)
    • Line 56: warning: exported method HeaderService.Serialize should have comment or be unexported (golint)
    • Line 75: warning: exported method HeaderService.Deserialize should have comment or be unexported (golint)
    • vaulted/pkg/ini/content.go
    • Line 17: warning: exported type Content should have comment or be unexported (golint)
    • Line 21: warning: exported function NewIniContent should have comment or be unexported (golint)
    • Line 25: warning: exported method Content.AddSection should have comment or be unexported (golint)
    • vaulted/pkg/base64/service.go
    • Line 23: warning: exported type Service should have comment or be unexported (golint)
    • Line 25: warning: exported function NewBase64Service should have comment or be unexported (golint)
    • Line 29: warning: exported method Service.Serialize should have comment or be unexported (golint)
    • Line 42: warning: exported method Service.Deserialize should have comment or be unexported (golint)
    • vaulted/pkg/vaulted/header/test/testing.go
    • Line 23: warning: exported type MockHeaderService should have comment or be unexported (golint)
    • Line 27: warning: exported method MockHeaderService.Serialize should have comment or be unexported (golint)
    • Line 40: warning: exported method MockHeaderService.Deserialize should have comment or be unexported (golint)
    • vaulted/internal/cli/cli.go
    • Line 26: warning: exported var ErrEmptyValue should have comment or be unexported (golint)
    • Line 28: warning: exported function ReadFromStdin should have comment or be unexported (golint)
    • vaulted/pkg/hcl/test/testing.go
    • Line 22: warning: exported type MockHclParser should have comment or be unexported (golint)
    • Line 26: warning: exported method MockHclParser.Parse should have comment or be unexported (golint)
    • vaulted/pkg/terraform/service.go
    • Line 24: warning: exported type Service should have comment or be unexported (golint)
    • Line 26: warning: exported function NewTerraformService should have comment or be unexported (golint)
    • Line 30: warning: exported method Service.ModifyInPlaceHclAst should have comment or be unexported (golint)
    • vaulted/pkg/base64/test/testing.go
    • Line 21: warning: exported type MockBase64Service should have comment or be unexported (golint)
    • Line 25: warning: exported method MockBase64Service.Serialize should have comment or be unexported (golint)
    • Line 37: warning: exported method MockBase64Service.Deserialize should have comment or be unexported (golint)
    • vaulted/pkg/vaulted/payload/test/testing.go
    • Line 25: warning: exported type MockEncryptedPayloadService should have comment or be unexported (golint)
    • Line 29: warning: exported method MockEncryptedPayloadService.Serialize should have comment or be unexported (golint)
    • Line 43: warning: exported method MockEncryptedPayloadService.Deserialize should have comment or be unexported (golint)
    • Line 57: warning: exported method MockEncryptedPayloadService.Encrypt should have comment or be unexported (golint)
    • Line 72: warning: exported method MockEncryptedPayloadService.Decrypt should have comment or be unexported (golint)
    • vaulted/pkg/rsa/service.go
    • Line 46: warning: exported type Service should have comment or be unexported (golint)
    • Line 50: warning: exported function NewRsaService should have comment or be unexported (golint)
    • Line 56: warning: exported method Service.ReadPublicKeyFromPath should have comment or be unexported (golint)
    • Line 68: warning: exported method Service.ReadPublicKeyFromBytes should have comment or be unexported (golint)
    • Line 90: warning: exported method Service.ReadPrivateKeyFromPath should have comment or be unexported (golint)
    • Line 102: warning: exported method Service.ReadPrivateKeyFromBytes should have comment or be unexported (golint)
    • Line 119: warning: exported method Service.EncryptPKCS1v15 should have comment or be unexported (golint)
    • Line 123: warning: exported method Service.DecryptPKCS1v15 should have comment or be unexported (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!