Preparing report...

Report for github.com/cossacklabs/acra

(v0.0.0-20220726074411-94e13a045573)

A+    Excellent!    Found 59 issues across 385 files

Tweet

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!


gofmt99%

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


ineffassign100%

IneffAssign detects ineffectual assignments in Go code.

No problems detected. Good job!


gocyclo84%

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.

    • encryptor/utils.go
    • Line 201: warning: cyclomatic complexity 33 of function findTableName() is high (> 15) (gocyclo)
    • Line 295: warning: cyclomatic complexity 24 of function mapColumnsToAliases() is high (> 15) (gocyclo)
    • acra-censor/common/matching_logic.go
    • Line 744: warning: cyclomatic complexity 94 of function areEqualExpr() is high (> 15) (gocyclo)
    • Line 33: warning: cyclomatic complexity 17 of function checkSinglePatternMatch() is high (> 15) (gocyclo)
    • Line 112: warning: cyclomatic complexity 17 of function handleSelectStatement() is high (> 15) (gocyclo)
    • acra-censor/acra-censor_test.go
    • Line 232: warning: cyclomatic complexity 31 of function TestAllowColumnsPattern() is high (> 15) (gocyclo)
    • Line 936: warning: cyclomatic complexity 31 of function TestDenyColumnsPattern() is high (> 15) (gocyclo)
    • Line 492: warning: cyclomatic complexity 26 of function TestAllowValuePattern() is high (> 15) (gocyclo)
    • Line 1201: warning: cyclomatic complexity 16 of function TestDenyValuePattern() is high (> 15) (gocyclo)
    • sqlparser/analyzer.go
    • Line 56: warning: cyclomatic complexity 20 of function Preview() is high (> 15) (gocyclo)
    • Line 291: warning: cyclomatic complexity 20 of function ExtractSetValues() is high (> 15) (gocyclo)
    • Line 119: warning: cyclomatic complexity 18 of function StmtType() is high (> 15) (gocyclo)
    • cmd/acra-translator/http_api/service_test.go
    • Line 167: warning: cyclomatic complexity 30 of function TestHTTPAPI() is high (> 15) (gocyclo)
    • Line 391: warning: cyclomatic complexity 17 of function testEncryptDecrypt() is high (> 15) (gocyclo)
    • Line 480: warning: cyclomatic complexity 16 of function testTokenizeDetokenize() is high (> 15) (gocyclo)
    • sqlparser/ast.go
    • Line 541: warning: cyclomatic complexity 44 of function (*ColumnType).SQLType() is high (> 15) (gocyclo)
    • crypto/registry_handler_test.go
    • Line 17: warning: cyclomatic complexity 20 of function TestWrappingContainer() is high (> 15) (gocyclo)
    • Line 131: warning: cyclomatic complexity 17 of function TestExtractSerializedContainer() is high (> 15) (gocyclo)
    • network/ocsp.go
    • Line 255: warning: cyclomatic complexity 23 of function (DefaultOCSPVerifier).verifyCertWithIssuer() is high (> 15) (gocyclo)
    • network/crl.go
    • Line 382: warning: cyclomatic complexity 21 of function checkCertWithCRL() is high (> 15) (gocyclo)
    • keystore/filesystem/server_keystore_test.go
    • Line 717: warning: cyclomatic complexity 46 of function testFilesystemKeyStoreWithOnlyCachedData() is high (> 15) (gocyclo)
    • Line 1339: warning: cyclomatic complexity 35 of function TestPoisonKeyGeneration() is high (> 15) (gocyclo)
    • Line 981: warning: cyclomatic complexity 33 of function TestFilesystemKeyStoreExport() is high (> 15) (gocyclo)
    • Line 1234: warning: cyclomatic complexity 20 of function TestKeyStore_GetPoisonKeyPair() is high (> 15) (gocyclo)
    • Line 548: warning: cyclomatic complexity 19 of function testFilesystemKeyStoreSymmetricWithCache() is high (> 15) (gocyclo)
    • decryptor/postgresql/pg_decryptor_test.go
    • Line 289: warning: cyclomatic complexity 25 of function TestMultiplePrepareAtOnceWithError() is high (> 15) (gocyclo)
    • Line 184: warning: cyclomatic complexity 23 of function TestMultiplePrepareAtOnce() is high (> 15) (gocyclo)
    • Line 108: warning: cyclomatic complexity 17 of function TestPreparedStatementRegistering() is high (> 15) (gocyclo)
    • sqlparser/token.go
    • Line 519: warning: cyclomatic complexity 52 of function (*Tokenizer).Scan() is high (> 15) (gocyclo)
    • Line 869: warning: cyclomatic complexity 17 of function (*Tokenizer).scanString() is high (> 15) (gocyclo)
    • decryptor/mysql/response_proxy.go
    • Line 270: warning: cyclomatic complexity 33 of function (*Handler).ProxyClientConnection() is high (> 15) (gocyclo)
    • Line 652: warning: cyclomatic complexity 24 of function (*Handler).QueryResponseHandler() is high (> 15) (gocyclo)
    • Line 806: warning: cyclomatic complexity 19 of function (*Handler).ProxyDatabaseConnection() is high (> 15) (gocyclo)

license100%

Checks whether your project has a LICENSE file.

No problems detected. Good job!


misspell100%

Misspell Finds commonly misspelled English words

No problems detected. Good job!