Preparing report...

Report for github.com/refraction-networking/gotapdance

(v0.0.0-20220119224326-7831ceda04f9)

A+    Excellent!    Found 22 issues across 39 files

Tweet

gofmt92%

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!


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.


golint53%

Golint is a linter for Go source code.

    • tools/clientconf/clientconf.go
    • Line 76: warning: don't use underscores in Go names; var pubkey_bin should be pubkeyBin (golint)
    • Line 165: warning: don't use underscores in Go names; var out_fname should be outFname (golint)
    • Line 180: warning: don't use underscores in Go names; var add_subnets should be addSubnets (golint)
    • Line 181: warning: don't use underscores in Go names; var delete_subnet should be deleteSubnet (golint)
    • Line 183: warning: don't use underscores in Go names; var subnet_file should be subnetFile (golint)
    • Line 236: warning: don't use underscores in Go names; var key_type should be keyType (golint)
    • Line 253: warning: don't use underscores in Go names; var key_type should be keyType (golint)
    • Line 294: warning: don't use underscores in Go names; var tls_spec should be tlsSpec (golint)
    • tapdance/phantoms/phantoms.go
    • Line 77: warning: exported function V4Only should have comment or be unexported (golint)
    • Line 172: warning: don't use underscores in Go names; var addresses_total should be addressesTotal (golint)
    • ed25519/edwards25519/edwards25519.go
    • Line 21: warning: exported function FeZero should have comment or be unexported (golint)
    • Line 25: warning: exported function FeOne should have comment or be unexported (golint)
    • Line 30: warning: exported function FeAdd should have comment or be unexported (golint)
    • Line 43: warning: exported function FeSub should have comment or be unexported (golint)
    • Line 56: warning: exported function FeCopy should have comment or be unexported (golint)
    • Line 60: warning: comment on exported function FeCMove should be of the form "FeCMove ..." (golint)
    • Line 95: warning: exported function FeFromBytes should have comment or be unexported (golint)
    • Line 222: warning: exported function FeIsNegative should have comment or be unexported (golint)
    • Line 228: warning: exported function FeIsNonZero should have comment or be unexported (golint)
    • Line 261: warning: exported function FeCombine should have comment or be unexported (golint)
    • Line 508: warning: exported function FeInvert should have comment or be unexported (golint)
    • Line 633: warning: exported type ProjectiveGroupElement should have comment or be unexported (golint)
    • Line 637: warning: exported type ExtendedGroupElement should have comment or be unexported (golint)
    • Line 641: warning: exported type CompletedGroupElement should have comment or be unexported (golint)
    • Line 645: warning: exported type PreComputedGroupElement should have comment or be unexported (golint)
    • Line 649: warning: exported type CachedGroupElement should have comment or be unexported (golint)
    • Line 653: warning: exported method ProjectiveGroupElement.Zero should have comment or be unexported (golint)
    • Line 659: warning: exported method ProjectiveGroupElement.Double should have comment or be unexported (golint)
    • Line 673: warning: exported method ProjectiveGroupElement.ToBytes should have comment or be unexported (golint)
    • Line 683: warning: exported method ExtendedGroupElement.Zero should have comment or be unexported (golint)
    • Line 690: warning: exported method ExtendedGroupElement.Double should have comment or be unexported (golint)
    • Line 696: warning: exported method ExtendedGroupElement.ToCached should have comment or be unexported (golint)
    • Line 703: warning: exported method ExtendedGroupElement.ToProjective should have comment or be unexported (golint)
    • Line 709: warning: exported method ExtendedGroupElement.ToBytes should have comment or be unexported (golint)
    • Line 719: warning: exported method ExtendedGroupElement.FromBytes should have comment or be unexported (golint)
    • Line 765: warning: exported method CompletedGroupElement.ToProjective should have comment or be unexported (golint)
    • Line 771: warning: exported method CompletedGroupElement.ToExtended should have comment or be unexported (golint)
    • Line 778: warning: exported method PreComputedGroupElement.Zero should have comment or be unexported (golint)
    • Line 943: warning: exported function PreComputedGroupElementCMove should have comment or be unexported (golint)
    • Line 1018: warning: comment on exported function ScMulAdd should be of the form "ScMulAdd ..." (golint)
    • Line 1451: warning: comment on exported function ScReduce should be of the form "ScReduce ..." (golint)
    • tapdance/conjure.go
    • Line 42: warning: exported type DecoyRegistrar should have comment or be unexported (golint)
    • Line 49: warning: context.Context should be the first parameter of a function (golint)
    • Line 49: warning: exported method DecoyRegistrar.Register should have comment or be unexported (golint)
    • Line 145: warning: comment on exported type APIRegistrar should be of the form "APIRegistrar ..." (with optional leading article) (golint)
    • Line 177: warning: context.Context should be the first parameter of a function (golint)
    • Line 177: warning: exported method APIRegistrar.Register should have comment or be unexported (golint)
    • Line 990: warning: exported type Obfs4Keys should have comment or be unexported (golint)
    • Line 1111: warning: comment on exported const TLSError should be of the form "TLSError ..." (golint)
    • tools/v6lookup/main.go
    • Line 22: warning: don't use underscores in Go names; var assets_file should be assetsFile (golint)
    • Line 23: warning: don't use underscores in Go names; var out_fname should be outFname (golint)
    • Line 152: warning: exported function ConnectToAll should have comment or be unexported (golint)
    • Line 198: warning: exported function ConnectSpecial should have comment or be unexported (golint)
    • Line 224: warning: if block ends with a return statement, so drop this else and outdent its block (move short variable declaration to its own line if necessary) (golint)
    • getifaddr/getifaddr.go
    • Line 17: warning: comment on exported function SupportsIpv6 should be of the form "SupportsIpv6 ..." (golint)
    • Line 33: warning: don't use underscores in Go names; var sa_in should be saIn (golint)
    • tapdance/common.go
    • Line 16: warning: exported const AES_GCM_TAG_SIZE should have comment or be unexported (golint)
    • Line 125: warning: don't use underscores in Go names; var default_flags should be defaultFlags (golint)
    • Line 127: warning: comment on exported function EnableProxyProtocol should be of the form "EnableProxyProtocol ..." (golint)
    • Line 137: warning: don't use underscores in Go names; var default_flags should be defaultFlags (golint)
    • Line 143: warning: exported function SetTlsLogFilename should have comment or be unexported (golint)
    • Line 153: warning: exported function WriteTlsLog should have comment or be unexported (golint)
    • tapdance/conn_flow.go
    • Line 77: warning: comment on exported method TapdanceFlowConn.DialContext should be of the form "DialContext ..." (golint)
    • tapdance/dialer.go
    • Line 90: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • gobind/gobind.go
    • Line 13: warning: don't use underscores in Go names; var td_proxy should be tdProxy (golint)
    • Line 17: warning: exported function NewDecoyProxy should have comment or be unexported (golint)
    • Line 29: warning: exported function GetLog should have comment or be unexported (golint)
    • Line 41: warning: exported function Listen should have comment or be unexported (golint)
    • Line 50: warning: exported function Stop should have comment or be unexported (golint)
    • Line 59: warning: exported function GetStats should have comment or be unexported (golint)
    • Line 68: warning: exported function IsListening should have comment or be unexported (golint)
    • ed25519/ed25519.go
    • Line 21: warning: exported const PublicKeySize should have comment (or a comment on this block) or be unexported (golint)
    • tdproxy/tapdance.go
    • Line 13: warning: exported var Logger should have comment or be unexported (golint)
    • Line 16: warning: exported const ProxyStateInitialized should have comment (or a comment on this block) or be unexported (golint)
    • Line 22: warning: comment on exported type TapDanceProxy should be of the form "TapDanceProxy ..." (with optional leading article) (golint)
    • Line 48: warning: exported function NewTapDanceProxy should have comment or be unexported (golint)
    • Line 70: warning: exported method TapDanceProxy.ListenAndServe should have comment or be unexported (golint)
    • Line 100: warning: exported method TapDanceProxy.Stop should have comment or be unexported (golint)
    • Line 132: warning: exported method TapDanceProxy.GetStatistics should have comment or be unexported (golint)
    • Line 146: warning: exported method TapDanceProxy.GetStats should have comment or be unexported (golint)
    • tapdance/registrar_bidirectional.go
    • Line 17: warning: comment on exported type APIRegistrarBidirectional should be of the form "APIRegistrarBidirectional ..." (with optional leading article) (golint)
    • Line 49: warning: context.Context should be the first parameter of a function (golint)
    • Line 49: warning: exported method APIRegistrarBidirectional.Register should have comment or be unexported (golint)
    • cli/main.go
    • Line 31: warning: don't use underscores in Go names; var assets_location should be assetsLocation (golint)
    • Line 36: warning: don't use underscores in Go names; var connect_target should be connectTarget (golint)
    • Line 105: warning: don't use underscores in Go names; func parameter connect_target should be connectTarget (golint)
    • Line 144: warning: don't use underscores in Go names; func parameter connect_target should be connectTarget (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!


misspell94%

Misspell Finds commonly misspelled English words