Preparing report...

Report for github.com/foxcpp/maddy

A+    Excellent!    Found 143 issues across 246 files

Tweet

gofmt97%

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!


gocyclo91%

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.

    • maddy/framework/cfgparser/parse.go
    • Line 218: warning: cyclomatic complexity 21 of function (*parseContext).readNodes() is high (> 15) (gocyclo)
    • Line 106: warning: cyclomatic complexity 17 of function (*parseContext).readNode() is high (> 15) (gocyclo)
    • maddy/internal/msgpipeline/config.go
    • Line 49: warning: cyclomatic complexity 32 of function parseMsgPipelineRootCfg() is high (> 15) (gocyclo)
    • Line 160: warning: cyclomatic complexity 26 of function parseMsgPipelineSrcCfg() is high (> 15) (gocyclo)
    • Line 258: warning: cyclomatic complexity 17 of function parseMsgPipelineRcptCfg() is high (> 15) (gocyclo)

golint46%

Golint is a linter for Go source code.

    • maddy/internal/auth/pam/module.go
    • Line 33: warning: exported type Auth should have comment or be unexported (golint)
    • Line 41: warning: exported function New should have comment or be unexported (golint)
    • Line 51: warning: exported method Auth.Name should have comment or be unexported (golint)
    • Line 55: warning: exported method Auth.InstanceName should have comment or be unexported (golint)
    • Line 59: warning: exported method Auth.Init should have comment or be unexported (golint)
    • Line 79: warning: exported method Auth.AuthPlain should have comment or be unexported (golint)
    • maddy/framework/module/table.go
    • Line 21: warning: comment on exported type Table should be of the form "Table ..." (with optional leading article) (golint)
    • Line 30: warning: exported type MutableTable should have comment or be unexported (golint)
    • maddy/framework/module/dummy.go
    • Line 36: warning: exported method Dummy.AuthPlain should have comment or be unexported (golint)
    • Line 40: warning: exported method Dummy.Lookup should have comment or be unexported (golint)
    • Line 44: warning: exported method Dummy.Name should have comment or be unexported (golint)
    • Line 48: warning: exported method Dummy.InstanceName should have comment or be unexported (golint)
    • Line 52: warning: exported method Dummy.Init should have comment or be unexported (golint)
    • Line 56: warning: exported method Dummy.Start should have comment or be unexported (golint)
    • maddy/internal/testutils/modifier.go
    • Line 30: warning: exported type Modifier should have comment or be unexported (golint)
    • Line 45: warning: exported method Modifier.Init should have comment or be unexported (golint)
    • Line 49: warning: exported method Modifier.Name should have comment or be unexported (golint)
    • Line 53: warning: exported method Modifier.InstanceName should have comment or be unexported (golint)
    • Line 61: warning: exported method Modifier.ModStateForMsg should have comment or be unexported (golint)
    • maddy/internal/imap_filter/group.go
    • Line 19: warning: don't use an underscore in package name (golint)
    • Line 40: warning: exported function NewGroup should have comment or be unexported (golint)
    • Line 47: warning: exported method Group.IMAPFilter should have comment or be unexported (golint)
    • Line 69: warning: exported method Group.Init should have comment or be unexported (golint)
    • Line 82: warning: exported method Group.Name should have comment or be unexported (golint)
    • Line 86: warning: exported method Group.InstanceName should have comment or be unexported (golint)
    • maddy/internal/target/queue/queue.go
    • Line 122: warning: exported type Queue should have comment or be unexported (golint)
    • Line 159: warning: exported type QueueMetadata should have comment or be unexported (golint)
    • Line 192: warning: exported function NewQueue should have comment or be unexported (golint)
    • Line 211: warning: exported method Queue.Init should have comment or be unexported (golint)
    • Line 263: warning: exported method Queue.Close should have comment or be unexported (golint)
    • Line 609: warning: exported method Queue.Start should have comment or be unexported (golint)
    • Line 832: warning: exported type BufferedReadCloser should have comment or be unexported (golint)
    • Line 880: warning: exported method Queue.InstanceName should have comment or be unexported (golint)
    • Line 884: warning: exported method Queue.Name should have comment or be unexported (golint)
    • maddy/internal/limits/limiters/rate.go
    • Line 28: warning: exported var ErrClosed should have comment or be unexported (golint)
    • Line 46: warning: exported function NewRate should have comment or be unexported (golint)
    • Line 89: warning: exported method Rate.Take should have comment or be unexported (golint)
    • Line 98: warning: exported method Rate.TakeContext should have comment or be unexported (golint)
    • Line 114: warning: exported method Rate.Release should have comment or be unexported (golint)
    • Line 117: warning: exported method Rate.Close should have comment or be unexported (golint)
    • maddy/maddy.go
    • Line 72: warning: exported var Version should have comment or be unexported (golint)
    • Line 80: warning: exported function BuildInfo should have comment or be unexported (golint)
    • Line 186: warning: exported function InitDirs should have comment or be unexported (golint)
    • Line 241: warning: exported function ReadGlobals should have comment or be unexported (golint)
    • Line 293: warning: exported type ModInfo should have comment or be unexported (golint)
    • Line 298: warning: exported function RegisterModules should have comment or be unexported (golint)
    • maddy/internal/testutils/smtp_server.go
    • Line 36: warning: exported type SMTPMessage should have comment or be unexported (golint)
    • Line 46: warning: exported type SMTPBackend should have comment or be unexported (golint)
    • Line 59: warning: exported method SMTPBackend.Login should have comment or be unexported (golint)
    • Line 76: warning: exported method SMTPBackend.AnonymousLogin should have comment or be unexported (golint)
    • Line 85: warning: exported method SMTPBackend.CheckMsg should have comment or be unexported (golint)
    • Line 186: warning: exported type SMTPServerConfigureFunc should have comment or be unexported (golint)
    • Line 189: warning: exported var AuthDisabled should have comment or be unexported (golint)
    • Line 194: warning: exported function SMTPServer should have comment or be unexported (golint)
    • Line 379: warning: exported function CheckSMTPConnLeak should have comment or be unexported (golint)
    • Line 397: warning: exported function WaitForConnsClose should have comment or be unexported (golint)
    • Line 422: warning: exported function CheckSMTPErr should have comment or be unexported (golint)
    • maddy/framework/future/future.go
    • Line 42: warning: exported function New should have comment or be unexported (golint)
    • Line 70: warning: exported method Future.Get should have comment or be unexported (golint)
    • Line 78: warning: exported method Future.GetContext should have comment or be unexported (golint)
    • maddy/internal/check/milter/milter.go
    • Line 41: warning: exported type Check should have comment or be unexported (golint)
    • Line 49: warning: exported function New should have comment or be unexported (golint)
    • Line 64: warning: exported method Check.Name should have comment or be unexported (golint)
    • Line 68: warning: exported method Check.InstanceName should have comment or be unexported (golint)
    • Line 72: warning: exported method Check.Init should have comment or be unexported (golint)
    • Line 118: warning: exported method Check.CheckStateForMsg should have comment or be unexported (golint)
    • maddy/cmd/maddyctl/clitools/clitools.go
    • Line 30: warning: exported function Confirmation should have comment or be unexported (golint)
    • Line 89: warning: exported function ReadPassword should have comment or be unexported (golint)
    • Line 112: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • maddy/internal/testutils/target.go
    • Line 39: warning: exported type Msg should have comment or be unexported (golint)
    • Line 47: warning: exported type Target should have comment or be unexported (golint)
    • Line 65: warning: exported method Target.Init should have comment or be unexported (golint)
    • Line 69: warning: exported method Target.InstanceName should have comment or be unexported (golint)
    • Line 76: warning: exported method Target.Name should have comment or be unexported (golint)
    • Line 89: warning: exported method Target.Start should have comment or be unexported (golint)
    • Line 183: warning: exported function DoTestDelivery should have comment or be unexported (golint)
    • Line 190: warning: exported function DoTestDeliveryMeta should have comment or be unexported (golint)
    • Line 200: warning: exported function DoTestDeliveryNonAtomic should have comment or be unexported (golint)
    • Line 246: warning: exported const DeliveryData should have comment or be unexported (golint)
    • Line 251: warning: exported function DoTestDeliveryErr should have comment or be unexported (golint)
    • Line 255: warning: exported function DoTestDeliveryErrMeta should have comment or be unexported (golint)
    • Line 303: warning: exported function CheckTestMessage should have comment or be unexported (golint)
    • Line 315: warning: exported function CheckMsg should have comment or be unexported (golint)
    • Line 324: warning: exported function CheckMsgID should have comment or be unexported (golint)
    • maddy/internal/target/remote/policy_group.go
    • Line 42: warning: exported method PolicyGroup.Init should have comment or be unexported (golint)
    • Line 90: warning: exported method PolicyGroup.Name should have comment or be unexported (golint)
    • Line 94: warning: exported method PolicyGroup.InstanceName should have comment or be unexported (golint)
    • maddy/framework/logparser/parse.go
    • Line 31: warning: exported type Msg should have comment or be unexported (golint)
    • Line 39: warning: exported type MalformedMsg should have comment or be unexported (golint)
    • Line 46: warning: exported const ISO8601_UTC should have comment (or a comment on this block) or be unexported (golint)
    • maddy/framework/module/mxauth.go
    • Line 27: warning: exported const AuthDisabled should have comment (or a comment on this block) or be unexported (golint)
    • Line 34: warning: exported type TLSLevel should have comment or be unexported (golint)
    • Line 35: warning: exported type MXLevel should have comment or be unexported (golint)
    • Line 39: warning: exported const TLSNone should have comment (or a comment on this block) or be unexported (golint)
    • maddy/framework/buffer/file.go
    • Line 40: warning: exported method FileBuffer.Open should have comment or be unexported (golint)
    • Line 44: warning: exported method FileBuffer.Len should have comment or be unexported (golint)
    • Line 59: warning: exported method FileBuffer.Remove should have comment or be unexported (golint)
    • maddy/internal/imap_filter/command/command.go
    • Line 43: warning: exported type Check should have comment or be unexported (golint)
    • Line 51: warning: exported method Check.IMAPFilter should have comment or be unexported (golint)
    • Line 64: warning: exported function New should have comment or be unexported (golint)
    • Line 80: warning: exported method Check.Name should have comment or be unexported (golint)
    • Line 84: warning: exported method Check.InstanceName should have comment or be unexported (golint)
    • Line 88: warning: exported method Check.Init should have comment or be unexported (golint)
    • maddy/internal/tls/self_signed.go
    • Line 36: warning: exported type SelfSignedLoader should have comment or be unexported (golint)
    • Line 43: warning: exported function NewSelfSignedLoader should have comment or be unexported (golint)
    • Line 50: warning: exported method SelfSignedLoader.Init should have comment or be unexported (golint)
    • Line 96: warning: exported method SelfSignedLoader.Name should have comment or be unexported (golint)
    • Line 100: warning: exported method SelfSignedLoader.InstanceName should have comment or be unexported (golint)
    • Line 104: warning: exported method SelfSignedLoader.LoadCerts should have comment or be unexported (golint)
    • maddy/internal/limits/limiters/bucket.go
    • Line 60: warning: exported function NewBucketSet should have comment or be unexported (golint)
    • Line 60: warning: don't use underscores in Go names; func parameter new_ should be new (golint)
    • Line 72: warning: exported method BucketSet.Close should have comment or be unexported (golint)
    • Line 122: warning: exported method BucketSet.Take should have comment or be unexported (golint)
    • Line 131: warning: exported method BucketSet.Release should have comment or be unexported (golint)
    • Line 146: warning: exported method BucketSet.TakeContext should have comment or be unexported (golint)
    • maddy/internal/storage/imapsql/imapsql.go
    • Line 58: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 62: warning: exported type Storage should have comment or be unexported (golint)
    • Line 201: warning: exported method Storage.Start should have comment or be unexported (golint)
    • Line 213: warning: exported method Storage.Name should have comment or be unexported (golint)
    • Line 217: warning: exported method Storage.InstanceName should have comment or be unexported (golint)
    • Line 221: warning: exported function New should have comment or be unexported (golint)
    • Line 238: warning: exported method Storage.Init should have comment or be unexported (golint)
    • Line 348: warning: exported method Storage.EnableUpdatePipe should have comment or be unexported (golint)
    • Line 418: warning: exported method Storage.I18NLevel should have comment or be unexported (golint)
    • Line 422: warning: exported method Storage.IMAPExtensions should have comment or be unexported (golint)
    • Line 426: warning: exported method Storage.CreateMessageLimit should have comment or be unexported (golint)
    • Line 430: warning: exported method Storage.Updates should have comment or be unexported (golint)
    • Line 439: warning: exported method Storage.EnableChildrenExt should have comment or be unexported (golint)
    • Line 469: warning: exported method Storage.GetOrCreateIMAPAcct should have comment or be unexported (golint)
    • Line 478: warning: exported method Storage.Lookup should have comment or be unexported (golint)
    • Line 498: warning: exported method Storage.Close should have comment or be unexported (golint)
    • Line 515: warning: exported method Storage.Login should have comment or be unexported (golint)
    • Line 519: warning: exported method Storage.SupportedThreadAlgorithms should have comment or be unexported (golint)
    • maddy/internal/modify/dkim/dkim.go
    • Line 45: warning: exported const Day should have comment or be unexported (golint)
    • Line 96: warning: exported type Modifier should have comment or be unexported (golint)
    • Line 115: warning: exported function New should have comment or be unexported (golint)
    • Line 135: warning: exported method Modifier.Name should have comment or be unexported (golint)
    • Line 139: warning: exported method Modifier.InstanceName should have comment or be unexported (golint)
    • Line 143: warning: exported method Modifier.Init should have comment or be unexported (golint)
    • Line 273: warning: exported method Modifier.ModStateForMsg should have comment or be unexported (golint)
    • maddy/internal/auth/shadow/read.go
    • Line 30: warning: exported var ErrNoSuchUser should have comment or be unexported (golint)
    • Line 31: warning: exported var ErrWrongPassword should have comment or be unexported (golint)
    • Line 85: warning: exported function Lookup should have comment or be unexported (golint)
    • maddy/framework/log/log.go
    • Line 54: warning: exported method Logger.Debugf should have comment or be unexported (golint)
    • Line 61: warning: exported method Logger.Debugln should have comment or be unexported (golint)
    • Line 68: warning: exported method Logger.Printf should have comment or be unexported (golint)
    • Line 72: warning: exported method Logger.Println should have comment or be unexported (golint)
    • Line 128: warning: exported method Logger.DebugMsg should have comment or be unexported (golint)
    • Line 179: warning: exported type LogFormatter should have comment or be unexported (golint)
    • Line 226: warning: exported function Debugf should have comment or be unexported (golint)
    • Line 227: warning: exported function Debugln should have comment or be unexported (golint)
    • Line 228: warning: exported function Printf should have comment or be unexported (golint)
    • Line 229: warning: exported function Println should have comment or be unexported (golint)
    • maddy/internal/table/sql_query.go
    • Line 28: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 31: warning: exported type SQL should have comment or be unexported (golint)
    • Line 43: warning: exported function NewSQL should have comment or be unexported (golint)
    • Line 50: warning: exported method SQL.Name should have comment or be unexported (golint)
    • Line 54: warning: exported method SQL.InstanceName should have comment or be unexported (golint)
    • Line 58: warning: exported method SQL.Init should have comment or be unexported (golint)
    • Line 128: warning: exported method SQL.Close should have comment or be unexported (golint)
    • Line 133: warning: exported method SQL.Lookup should have comment or be unexported (golint)
    • Line 145: warning: exported method SQL.Keys should have comment or be unexported (golint)
    • Line 166: warning: exported method SQL.RemoveKey should have comment or be unexported (golint)
    • Line 178: warning: exported method SQL.SetKey should have comment or be unexported (golint)
    • maddy/internal/table/static.go
    • Line 26: warning: exported type Static should have comment or be unexported (golint)
    • Line 33: warning: exported function NewStatic should have comment or be unexported (golint)
    • Line 41: warning: exported method Static.Init should have comment or be unexported (golint)
    • Line 53: warning: exported method Static.Name should have comment or be unexported (golint)
    • Line 57: warning: exported method Static.InstanceName should have comment or be unexported (golint)
    • Line 61: warning: exported method Static.Lookup should have comment or be unexported (golint)
    • maddy/internal/table/file.go
    • Line 36: warning: exported const FileModName should have comment or be unexported (golint)
    • Line 38: warning: exported type File should have comment or be unexported (golint)
    • Line 52: warning: exported function NewFile should have comment or be unexported (golint)
    • Line 71: warning: exported method File.Name should have comment or be unexported (golint)
    • Line 75: warning: exported method File.InstanceName should have comment or be unexported (golint)
    • Line 79: warning: exported method File.Init should have comment or be unexported (golint)
    • Line 165: warning: exported method File.Close should have comment or be unexported (golint)
    • Line 215: warning: exported method File.Lookup should have comment or be unexported (golint)
    • maddy/internal/target/smtp/smtp_downstream.go
    • Line 27: warning: don't use an underscore in package name (golint)
    • Line 50: warning: exported type Downstream should have comment or be unexported (golint)
    • Line 76: warning: exported function NewDownstream should have comment or be unexported (golint)
    • Line 86: warning: exported method Downstream.Init should have comment or be unexported (golint)
    • Line 128: warning: exported method Downstream.Name should have comment or be unexported (golint)
    • Line 132: warning: exported method Downstream.InstanceName should have comment or be unexported (golint)
    • Line 152: warning: exported method Downstream.Start should have comment or be unexported (golint)
    • maddy/internal/msgpipeline/module.go
    • Line 27: warning: exported type Module should have comment or be unexported (golint)
    • Line 33: warning: exported function NewModule should have comment or be unexported (golint)
    • Line 40: warning: exported method Module.Init should have comment or be unexported (golint)
    • Line 60: warning: exported method Module.Name should have comment or be unexported (golint)
    • Line 64: warning: exported method Module.InstanceName should have comment or be unexported (golint)
    • maddy/framework/config/endpoint.go
    • Line 70: warning: exported method Endpoint.Network should have comment or be unexported (golint)
    • Line 73: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 78: warning: exported method Endpoint.Address should have comment or be unexported (golint)
    • Line 81: warning: if block ends with a return statement, so drop this else and outdent its block (golint)
    • Line 86: warning: exported method Endpoint.IsTLS should have comment or be unexported (golint)
    • maddy/internal/check/spf/spf.go
    • Line 48: warning: exported type Check should have comment or be unexported (golint)
    • Line 63: warning: exported function New should have comment or be unexported (golint)
    • Line 71: warning: exported method Check.Name should have comment or be unexported (golint)
    • Line 75: warning: exported method Check.InstanceName should have comment or be unexported (golint)
    • Line 79: warning: exported method Check.Init should have comment or be unexported (golint)
    • Line 128: warning: exported method Check.CheckStateForMsg should have comment or be unexported (golint)
    • maddy/internal/limits/limiters/multilimit.go
    • Line 31: warning: exported method MultiLimit.Take should have comment or be unexported (golint)
    • Line 45: warning: exported method MultiLimit.TakeContext should have comment or be unexported (golint)
    • Line 59: warning: exported method MultiLimit.Release should have comment or be unexported (golint)
    • Line 65: warning: exported method MultiLimit.Close should have comment or be unexported (golint)
    • maddy/framework/cfgparser/parse.go
    • Line 19: warning: package comment should be of the form "Package parser ..." (golint)
    • Line 177: warning: exported function NodeErr should have comment or be unexported (golint)
    • Line 386: warning: exported function Read should have comment or be unexported (golint)
    • maddy/framework/config/module/interfaces.go
    • Line 26: warning: exported function MessageCheck should have comment or be unexported (golint)
    • Line 34: warning: comment on exported function DeliveryDirective should be of the form "DeliveryDirective ..." (golint)
    • Line 48: warning: exported function DeliveryTarget should have comment or be unexported (golint)
    • Line 56: warning: exported function MsgModifier should have comment or be unexported (golint)
    • Line 64: warning: exported function IMAPFilter should have comment or be unexported (golint)
    • Line 72: warning: exported function StorageDirective should have comment or be unexported (golint)
    • Line 80: warning: exported function TableDirective should have comment or be unexported (golint)
    • maddy/framework/config/map.go
    • Line 67: warning: exported function NewMap should have comment or be unexported (golint)
    • Line 173: warning: exported function ParseDataSize should have comment or be unexported (golint)
    • Line 590: warning: comment on exported method Map.ProcessWith should be of the form "ProcessWith ..." (golint)
    • maddy/internal/testutils/buffer.go
    • Line 33: warning: exported function BodyFromStr should have comment or be unexported (golint)
    • Line 62: warning: exported type FailingBuffer should have comment or be unexported (golint)
    • Line 69: warning: exported method FailingBuffer.Open should have comment or be unexported (golint)
    • Line 79: warning: exported method FailingBuffer.Len should have comment or be unexported (golint)
    • Line 83: warning: exported method FailingBuffer.Remove should have comment or be unexported (golint)
    • maddy/framework/buffer/memory.go
    • Line 31: warning: exported method MemoryBuffer.Open should have comment or be unexported (golint)
    • Line 35: warning: exported method MemoryBuffer.Len should have comment or be unexported (golint)
    • Line 39: warning: exported method MemoryBuffer.Remove should have comment or be unexported (golint)
    • maddy/internal/storage/imapsql/maddyctl.go
    • Line 28: warning: exported method Storage.ListIMAPAccts should have comment or be unexported (golint)
    • Line 32: warning: exported method Storage.CreateIMAPAcct should have comment or be unexported (golint)
    • Line 41: warning: exported method Storage.DeleteIMAPAcct should have comment or be unexported (golint)
    • Line 50: warning: exported method Storage.GetIMAPAcct should have comment or be unexported (golint)
    • maddy/internal/endpoint/imap/imap.go
    • Line 40: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 54: warning: exported type Endpoint should have comment or be unexported (golint)
    • Line 69: warning: exported function New should have comment or be unexported (golint)
    • Line 81: warning: exported method Endpoint.Init should have comment or be unexported (golint)
    • Line 201: warning: exported method Endpoint.Updates should have comment or be unexported (golint)
    • Line 205: warning: exported method Endpoint.Name should have comment or be unexported (golint)
    • Line 209: warning: exported method Endpoint.InstanceName should have comment or be unexported (golint)
    • Line 213: warning: exported method Endpoint.Close should have comment or be unexported (golint)
    • Line 235: warning: exported method Endpoint.Login should have comment or be unexported (golint)
    • Line 245: warning: exported method Endpoint.EnableChildrenExt should have comment or be unexported (golint)
    • Line 249: warning: exported method Endpoint.I18NLevel should have comment or be unexported (golint)
    • Line 287: warning: exported method Endpoint.SupportedThreadAlgorithms should have comment or be unexported (golint)
    • maddy/internal/msgpipeline/check_group.go
    • Line 40: warning: exported method CheckGroup.Init should have comment or be unexported (golint)
    • Line 53: warning: exported method CheckGroup.Name should have comment or be unexported (golint)
    • Line 57: warning: exported method CheckGroup.InstanceName should have comment or be unexported (golint)
    • maddy/internal/auth/external/helperauth.go
    • Line 29: warning: exported function AuthUsingHelper should have comment or be unexported (golint)
    • Line 51: 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)
    • maddy/internal/check/dnsbl/dnsbl.go
    • Line 42: warning: exported type List should have comment or be unexported (golint)
    • Line 59: warning: exported type DNSBL should have comment or be unexported (golint)
    • Line 72: warning: exported function NewDNSBL should have comment or be unexported (golint)
    • Line 82: warning: exported method DNSBL.Name should have comment or be unexported (golint)
    • Line 86: warning: exported method DNSBL.InstanceName should have comment or be unexported (golint)
    • Line 90: warning: exported method DNSBL.Init should have comment or be unexported (golint)
    • Line 397: warning: exported method DNSBL.CheckStateForMsg should have comment or be unexported (golint)
    • maddy/config.go
    • Line 54: warning: exported function LogOutputOption should have comment or be unexported (golint)
    • maddy/internal/check/rspamd/rspamd.go
    • Line 46: warning: exported type Check should have comment or be unexported (golint)
    • Line 64: warning: exported function New should have comment or be unexported (golint)
    • Line 83: warning: exported method Check.Name should have comment or be unexported (golint)
    • Line 87: warning: exported method Check.InstanceName should have comment or be unexported (golint)
    • Line 91: warning: exported method Check.Init should have comment or be unexported (golint)
    • Line 144: warning: exported method Check.CheckStateForMsg should have comment or be unexported (golint)
    • maddy/internal/msgpipeline/msgpipeline.go
    • Line 88: warning: exported function New should have comment or be unexported (golint)
    • Line 96: warning: exported method MsgPipeline.RunEarlyChecks should have comment or be unexported (golint)
    • Line 611: warning: don't use underscores in Go names; var delivery_ should be delivery (golint)
    • maddy/internal/auth/sasl.go
    • Line 34: warning: exported var ErrUnsupportedMech should have comment or be unexported (golint)
    • Line 49: warning: exported method SASLAuth.SASLMechanisms should have comment or be unexported (golint)
    • Line 59: warning: exported method SASLAuth.AuthPlain should have comment or be unexported (golint)
    • Line 130: warning: exported type FailingSASLServ should have comment or be unexported (golint)
    • Line 132: warning: exported method FailingSASLServ.Next should have comment or be unexported (golint)
    • maddy/internal/check/command/command.go
    • Line 48: warning: exported type Stage should have comment or be unexported (golint)
    • Line 51: warning: exported const StageConnection should have comment (or a comment on this block) or be unexported (golint)
    • Line 59: warning: exported type Check should have comment or be unexported (golint)
    • Line 69: warning: exported function New should have comment or be unexported (golint)
    • Line 92: warning: exported method Check.Name should have comment or be unexported (golint)
    • Line 96: warning: exported method Check.InstanceName should have comment or be unexported (golint)
    • Line 100: warning: exported method Check.Init should have comment or be unexported (golint)
    • Line 149: warning: exported method Check.CheckStateForMsg should have comment or be unexported (golint)
    • maddy/internal/modify/group.go
    • Line 46: warning: exported method Group.Init should have comment or be unexported (golint)
    • Line 59: warning: exported method Group.Name should have comment or be unexported (golint)
    • Line 63: warning: exported method Group.InstanceName should have comment or be unexported (golint)
    • Line 67: warning: exported method Group.ModStateForMsg should have comment or be unexported (golint)
    • maddy/internal/table/identity.go
    • Line 26: warning: exported type Identity should have comment or be unexported (golint)
    • Line 31: warning: exported function NewIdentity should have comment or be unexported (golint)
    • Line 38: warning: exported method Identity.Init should have comment or be unexported (golint)
    • Line 42: warning: exported method Identity.Name should have comment or be unexported (golint)
    • Line 46: warning: exported method Identity.InstanceName should have comment or be unexported (golint)
    • Line 50: warning: exported method Identity.Lookup should have comment or be unexported (golint)
    • maddy/internal/endpoint/dovecot_sasld/dovecot_sasl.go
    • Line 38: warning: exported type Endpoint should have comment or be unexported (golint)
    • Line 48: warning: exported function New should have comment or be unexported (golint)
    • Line 58: warning: exported method Endpoint.Name should have comment or be unexported (golint)
    • Line 62: warning: exported method Endpoint.InstanceName should have comment or be unexported (golint)
    • Line 66: warning: exported method Endpoint.Init should have comment or be unexported (golint)
    • Line 115: warning: exported method Endpoint.Close should have comment or be unexported (golint)
    • maddy/internal/endpoint/smtp/session.go
    • Line 43: warning: exported type Session should have comment or be unexported (golint)
    • Line 71: warning: exported method Session.Reset should have comment or be unexported (golint)
    • Line 206: warning: exported method Session.Mail should have comment or be unexported (golint)
    • Line 261: warning: exported method Session.Rcpt should have comment or be unexported (golint)
    • Line 325: warning: exported method Session.Logout should have comment or be unexported (golint)
    • Line 364: warning: exported method Session.Data should have comment or be unexported (golint)
    • Line 419: warning: exported method Session.LMTPData should have comment or be unexported (golint)
    • maddy/internal/testutils/check.go
    • Line 31: warning: exported type Check should have comment or be unexported (golint)
    • Line 49: warning: exported method Check.CheckStateForMsg should have comment or be unexported (golint)
    • Line 58: warning: exported method Check.Init should have comment or be unexported (golint)
    • Line 62: warning: exported method Check.Name should have comment or be unexported (golint)
    • Line 66: warning: exported method Check.InstanceName should have comment or be unexported (golint)
    • Line 73: warning: exported method Check.CheckConnection should have comment or be unexported (golint)
    • maddy/cmd/maddyctl/clitools/termios.go
    • Line 33: warning: exported type Termios should have comment or be unexported (golint)
    • Line 66: warning: exported function TcSetAttr should have comment or be unexported (golint)
    • Line 74: warning: exported function TcGetAttr should have comment or be unexported (golint)
    • maddy/internal/tls/file.go
    • Line 35: warning: exported type FileLoader should have comment or be unexported (golint)
    • Line 49: warning: exported function NewFileLoader should have comment or be unexported (golint)
    • Line 58: warning: exported method FileLoader.Init should have comment or be unexported (golint)
    • Line 99: warning: exported method FileLoader.Close should have comment or be unexported (golint)
    • Line 105: warning: exported method FileLoader.Name should have comment or be unexported (golint)
    • Line 109: warning: exported method FileLoader.InstanceName should have comment or be unexported (golint)
    • Line 156: warning: exported method FileLoader.LoadCerts should have comment or be unexported (golint)
    • maddy/internal/smtpconn/pool/pool.go
    • Line 27: warning: exported type Conn should have comment or be unexported (golint)
    • Line 32: warning: exported type Config should have comment or be unexported (golint)
    • Line 46: warning: exported type P should have comment or be unexported (golint)
    • Line 52: warning: exported function New should have comment or be unexported (golint)
    • Line 65: warning: exported method P.Get should have comment or be unexported (golint)
    • Line 105: warning: exported method P.Return should have comment or be unexported (golint)
    • Line 146: warning: exported method P.Close should have comment or be unexported (golint)
    • maddy/internal/table/sql_table.go
    • Line 26: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 29: warning: exported type SQLTable should have comment or be unexported (golint)
    • Line 36: warning: exported function NewSQLTable should have comment or be unexported (golint)
    • Line 48: warning: exported method SQLTable.Name should have comment or be unexported (golint)
    • Line 52: warning: exported method SQLTable.InstanceName should have comment or be unexported (golint)
    • Line 56: warning: exported method SQLTable.Init should have comment or be unexported (golint)
    • Line 117: warning: exported method SQLTable.Close should have comment or be unexported (golint)
    • Line 121: warning: exported method SQLTable.Lookup should have comment or be unexported (golint)
    • Line 125: warning: exported method SQLTable.Keys should have comment or be unexported (golint)
    • Line 129: warning: exported method SQLTable.RemoveKey should have comment or be unexported (golint)
    • Line 133: warning: exported method SQLTable.SetKey should have comment or be unexported (golint)
    • maddy/framework/config/module/check_action.go
    • Line 59: warning: exported function FailActionDirective should have comment or be unexported (golint)
    • Line 71: warning: exported function ParseActionDirective should have comment or be unexported (golint)
    • Line 119: warning: exported function ParseRejectDirective should have comment or be unexported (golint)
    • maddy/internal/auth/external/externalauth.go
    • Line 33: warning: exported type ExternalAuth should have comment or be unexported (golint)
    • Line 44: warning: exported function NewExternalAuth should have comment or be unexported (golint)
    • Line 58: warning: exported method ExternalAuth.Name should have comment or be unexported (golint)
    • Line 62: warning: exported method ExternalAuth.InstanceName should have comment or be unexported (golint)
    • Line 66: warning: exported method ExternalAuth.Init should have comment or be unexported (golint)
    • Line 92: warning: exported method ExternalAuth.AuthPlain should have comment or be unexported (golint)
    • maddy/internal/auth/dovecot_sasl/dovecot_sasl.go
    • Line 34: warning: exported type Auth should have comment or be unexported (golint)
    • Line 47: warning: exported function New should have comment or be unexported (golint)
    • Line 64: warning: exported method Auth.Name should have comment or be unexported (golint)
    • Line 68: warning: exported method Auth.InstanceName should have comment or be unexported (golint)
    • Line 91: warning: exported method Auth.Init should have comment or be unexported (golint)
    • Line 134: warning: exported method Auth.AuthPlain should have comment or be unexported (golint)
    • maddy/tests/conn.go
    • Line 75: warning: exported method Conn.Writeln should have comment or be unexported (golint)
    • Line 81: warning: exported method Conn.Readln should have comment or be unexported (golint)
    • Line 113: warning: exported method Conn.Expect should have comment or be unexported (golint)
    • Line 189: warning: exported method Conn.TLS should have comment or be unexported (golint)
    • Line 204: warning: exported method Conn.SMTPNegotation should have comment or be unexported (golint)
    • Line 267: warning: exported method Conn.Close should have comment or be unexported (golint)
    • Line 271: warning: exported method Conn.Rebind should have comment or be unexported (golint)
    • maddy/internal/dsn/dsn.go
    • Line 38: warning: exported type ReportingMTAInfo should have comment or be unexported (golint)
    • Line 55: warning: exported method ReportingMTAInfo.WriteTo should have comment or be unexported (golint)
    • Line 106: warning: exported type Action should have comment or be unexported (golint)
    • Line 109: warning: exported const ActionFailed should have comment (or a comment on this block) or be unexported (golint)
    • Line 116: warning: exported type RecipientInfo should have comment or be unexported (golint)
    • Line 127: warning: exported method RecipientInfo.WriteTo should have comment or be unexported (golint)
    • Line 182: warning: exported type Envelope should have comment or be unexported (golint)
    • maddy/internal/updatepipe/unix_pipe.go
    • Line 77: warning: exported method UnixSockPipe.Wrap should have comment or be unexported (golint)
    • Line 83: warning: exported method UnixSockPipe.Listen should have comment or be unexported (golint)
    • Line 101: warning: exported method UnixSockPipe.InitPush should have comment or be unexported (golint)
    • Line 111: warning: exported method UnixSockPipe.Push should have comment or be unexported (golint)
    • Line 127: warning: exported method UnixSockPipe.Close should have comment or be unexported (golint)
    • maddy/internal/target/queue/timewheel.go
    • Line 28: warning: exported type TimeSlot should have comment or be unexported (golint)
    • Line 33: warning: exported type TimeWheel should have comment or be unexported (golint)
    • Line 45: warning: exported function NewTimeWheel should have comment or be unexported (golint)
    • Line 56: warning: exported method TimeWheel.Add should have comment or be unexported (golint)
    • Line 73: warning: exported method TimeWheel.Close should have comment or be unexported (golint)
    • maddy/internal/limits/limiters/concurrency.go
    • Line 32: warning: exported function NewSemaphore should have comment or be unexported (golint)
    • Line 36: warning: exported method Semaphore.Take should have comment or be unexported (golint)
    • Line 44: warning: exported method Semaphore.TakeContext should have comment or be unexported (golint)
    • Line 56: warning: exported method Semaphore.Release should have comment or be unexported (golint)
    • Line 67: warning: exported method Semaphore.Close should have comment or be unexported (golint)
    • maddy/internal/auth/pass_table/hash.go
    • Line 19: warning: don't use an underscore in package name (golint)
    • Line 36: warning: exported const HashSHA256 should have comment (or a comment on this block) or be unexported (golint)
    • Line 61: warning: exported type FuncHashCompute should have comment or be unexported (golint)
    • Line 62: warning: exported type FuncHashVerify should have comment or be unexported (golint)
    • Line 66: warning: exported var HashCompute should have comment or be unexported (golint)
    • maddy/internal/auth/pass_table/table.go
    • Line 19: warning: don't use an underscore in package name (golint)
    • Line 32: warning: exported type Auth should have comment or be unexported (golint)
    • Line 40: warning: exported function New should have comment or be unexported (golint)
    • Line 48: warning: exported method Auth.Init should have comment or be unexported (golint)
    • Line 58: warning: exported method Auth.Name should have comment or be unexported (golint)
    • Line 62: warning: exported method Auth.InstanceName should have comment or be unexported (golint)
    • Line 66: warning: exported method Auth.Lookup should have comment or be unexported (golint)
    • Line 75: warning: exported method Auth.AuthPlain should have comment or be unexported (golint)
    • Line 100: warning: exported method Auth.ListUsers should have comment or be unexported (golint)
    • Line 113: warning: exported method Auth.CreateUser should have comment or be unexported (golint)
    • Line 146: warning: exported method Auth.SetUserPassword should have comment or be unexported (golint)
    • Line 171: warning: exported method Auth.DeleteUser should have comment or be unexported (golint)
    • maddy/internal/limits/limits.go
    • Line 19: warning: package comment should be of the form "Package limits ..." (golint)
    • Line 40: warning: exported type Group should have comment or be unexported (golint)
    • Line 49: warning: exported function New should have comment or be unexported (golint)
    • Line 55: warning: exported method Group.Init should have comment or be unexported (golint)
    • Line 174: warning: exported method Group.TakeMsg should have comment or be unexported (golint)
    • Line 198: warning: exported method Group.TakeDest should have comment or be unexported (golint)
    • Line 207: warning: exported method Group.ReleaseMsg should have comment or be unexported (golint)
    • Line 217: warning: exported method Group.ReleaseDest should have comment or be unexported (golint)
    • Line 224: warning: exported method Group.Name should have comment or be unexported (golint)
    • Line 228: warning: exported method Group.InstanceName should have comment or be unexported (golint)
    • maddy/internal/endpoint/smtp/smtp.go
    • Line 52: warning: exported type Endpoint should have comment or be unexported (golint)
    • Line 76: warning: exported method Endpoint.Name should have comment or be unexported (golint)
    • Line 80: warning: exported method Endpoint.InstanceName should have comment or be unexported (golint)
    • Line 84: warning: exported function New should have comment or be unexported (golint)
    • Line 100: warning: exported method Endpoint.Init should have comment or be unexported (golint)
    • Line 363: warning: exported method Endpoint.Login should have comment or be unexported (golint)
    • Line 397: warning: exported method Endpoint.AnonymousLogin should have comment or be unexported (golint)
    • Line 444: warning: exported method Endpoint.Close should have comment or be unexported (golint)
    • maddy/internal/target/remote/security.go
    • Line 54: warning: exported function NewMTASTSPolicy should have comment or be unexported (golint)
    • Line 230: warning: exported function NewSTSPreload should have comment or be unexported (golint)
    • Line 269: warning: receiver name p should be consistent with previous receiver name c for stsPreloadPolicy (golint)
    • Line 284: warning: receiver name p should be consistent with previous receiver name c for stsPreloadPolicy (golint)
    • Line 292: warning: exported function NewDNSSECPolicy should have comment or be unexported (golint)
    • Line 350: warning: exported function NewDANEPolicy should have comment or be unexported (golint)
    • Line 522: warning: exported function NewLocalPolicy should have comment or be unexported (golint)
    • Line 575: warning: receiver name l should be consistent with previous receiver name c for localPolicy (golint)
    • Line 579: warning: receiver name l should be consistent with previous receiver name c for localPolicy (golint)
    • Line 583: warning: receiver name l should be consistent with previous receiver name c for localPolicy (golint)
    • Line 584: warning: receiver name l should be consistent with previous receiver name c for localPolicy (golint)
    • Line 585: warning: receiver name l should be consistent with previous receiver name c for localPolicy (golint)
    • Line 587: warning: receiver name l should be consistent with previous receiver name c for localPolicy (golint)
    • Line 603: warning: receiver name l should be consistent with previous receiver name c for localPolicy (golint)
    • maddy/internal/dmarc/dmarc.go
    • Line 28: warning: exported type Resolver should have comment or be unexported (golint)
    • Line 32: warning: exported type Record should have comment or be unexported (golint)
    • Line 33: warning: exported type Policy should have comment or be unexported (golint)
    • Line 34: warning: exported type AlignmentMode should have comment or be unexported (golint)
    • Line 35: warning: exported type FailureOptions should have comment or be unexported (golint)
    • Line 39: warning: exported const PolicyNone should have comment (or a comment on this block) or be unexported (golint)
    • maddy/tests/t.go
    • Line 45: warning: exported var TestBinary should have comment or be unexported (golint)
    • Line 50: warning: exported type T should have comment or be unexported (golint)
    • Line 64: warning: exported function NewT should have comment or be unexported (golint)
    • Line 122: warning: exported method T.Env should have comment or be unexported (golint)
    • Line 263: warning: exported method T.StateDir should have comment or be unexported (golint)
    • Line 267: warning: exported method T.RuntimeDir should have comment or be unexported (golint)
    • Line 271: warning: exported method T.Close should have comment or be unexported (golint)
    • Line 367: warning: exported method T.ConnUnnamed should have comment or be unexported (golint)
    • Line 382: warning: exported method T.Conn should have comment or be unexported (golint)
    • Line 391: warning: exported method T.Subtest should have comment or be unexported (golint)
    • maddy/internal/auth/plain_separate/plain_separate.go
    • Line 19: warning: don't use an underscore in package name (golint)
    • Line 31: warning: exported type Auth should have comment or be unexported (golint)
    • Line 43: warning: exported function NewAuth should have comment or be unexported (golint)
    • Line 58: warning: exported method Auth.Name should have comment or be unexported (golint)
    • Line 62: warning: exported method Auth.InstanceName should have comment or be unexported (golint)
    • Line 66: warning: exported method Auth.Init should have comment or be unexported (golint)
    • Line 96: warning: exported method Auth.Lookup should have comment or be unexported (golint)
    • Line 114: warning: exported method Auth.AuthPlain should have comment or be unexported (golint)
    • maddy/internal/auth/shadow/verify.go
    • Line 27: warning: a blank import should be only in a main or test package, or have a comment justifying it (golint)
    • Line 35: warning: exported method Entry.IsAccountValid should have comment or be unexported (golint)
    • Line 44: warning: exported method Entry.IsPasswordValid should have comment or be unexported (golint)
    • Line 53: warning: exported method Entry.VerifyPassword should have comment or be unexported (golint)
    • maddy/framework/dns/dnssec.go
    • Line 32: warning: exported type TLSA should have comment or be unexported (golint)
    • Line 49: warning: exported method RCodeError.Temporary should have comment or be unexported (golint)
    • Line 69: warning: exported function IsNotFound should have comment or be unexported (golint)
    • Line 113: warning: exported method ExtResolver.AuthLookupAddr should have comment or be unexported (golint)
    • Line 142: warning: exported method ExtResolver.AuthLookupHost should have comment or be unexported (golint)
    • Line 155: warning: exported method ExtResolver.AuthLookupMX should have comment or be unexported (golint)
    • Line 182: warning: exported method ExtResolver.AuthLookupTXT should have comment or be unexported (golint)
    • Line 250: warning: exported method ExtResolver.AuthLookupCNAME should have comment or be unexported (golint)
    • Line 271: warning: exported method ExtResolver.AuthLookupIPAddr should have comment or be unexported (golint)
    • Line 347: warning: exported method ExtResolver.AuthLookupTLSA should have comment or be unexported (golint)
    • Line 376: warning: exported function NewExtResolver should have comment or be unexported (golint)
    • maddy/cmd/maddyctl/imap.go
    • Line 37: warning: exported function FormatAddress should have comment or be unexported (golint)
    • Line 41: warning: exported function FormatAddressList should have comment or be unexported (golint)
    • maddy/framework/exterrors/smtp.go
    • Line 27: warning: exported type EnhancedCode should have comment or be unexported (golint)
    • Line 29: warning: exported method EnhancedCode.FormatLog should have comment or be unexported (golint)
    • Line 90: warning: exported method SMTPError.Fields should have comment or be unexported (golint)
    • maddy/internal/target/remote/remote.go
    • Line 60: warning: exported type Target should have comment or be unexported (golint)
    • Line 83: warning: exported function New should have comment or be unexported (golint)
    • Line 96: warning: exported method Target.Init should have comment or be unexported (golint)
    • Line 167: warning: exported method Target.Close should have comment or be unexported (golint)
    • Line 173: warning: exported method Target.Name should have comment or be unexported (golint)
    • Line 177: warning: exported method Target.InstanceName should have comment or be unexported (golint)
    • Line 193: warning: exported method Target.Start should have comment or be unexported (golint)
    • maddy/internal/endpoint/openmetrics/om.go
    • Line 35: warning: exported type Endpoint should have comment or be unexported (golint)
    • Line 44: warning: exported function New should have comment or be unexported (golint)
    • Line 51: warning: exported method Endpoint.Init should have comment or be unexported (golint)
    • Line 88: warning: exported method Endpoint.Name should have comment or be unexported (golint)
    • Line 92: warning: exported method Endpoint.InstanceName should have comment or be unexported (golint)
    • Line 96: warning: exported method Endpoint.Close should have comment or be unexported (golint)
    • maddy/systemd.go
    • Line 35: warning: exported type SDStatus should have comment or be unexported (golint)
    • Line 38: warning: exported const SDReady should have comment (or a comment on this block) or be unexported (golint)
    • Line 44: warning: exported var ErrNoNotifySock should have comment or be unexported (golint)
    • maddy/internal/smtpconn/smtpconn.go
    • Line 19: warning: package comment should be of the form "Package smtpconn ..." (golint)
    • Line 298: warning: exported method C.ServerName should have comment or be unexported (golint)
    • Line 302: warning: exported method C.Client should have comment or be unexported (golint)
    • Line 367: warning: exported method C.LMTPData should have comment or be unexported (golint)
    • Line 390: warning: exported method C.Noop should have comment or be unexported (golint)
    • maddy/internal/check/stateless_check.go
    • Line 37: warning: exported type StatelessCheckContext should have comment or be unexported (golint)
    • Line 52: warning: exported type FuncConnCheck should have comment or be unexported (golint)
    • Line 53: warning: exported type FuncSenderCheck should have comment or be unexported (golint)
    • Line 54: warning: exported type FuncRcptCheck should have comment or be unexported (golint)
    • Line 55: warning: exported type FuncBodyCheck should have comment or be unexported (golint)
    • maddy/internal/auth/shadow/module.go
    • Line 35: warning: exported type Auth should have comment or be unexported (golint)
    • Line 43: warning: exported function New should have comment or be unexported (golint)
    • Line 53: warning: exported method Auth.Name should have comment or be unexported (golint)
    • Line 57: warning: exported method Auth.InstanceName should have comment or be unexported (golint)
    • Line 61: warning: exported method Auth.Init should have comment or be unexported (golint)
    • Line 87: warning: exported method Auth.Lookup should have comment or be unexported (golint)
    • Line 104: warning: exported method Auth.AuthPlain should have comment or be unexported (golint)
    • maddy/framework/log/output.go
    • Line 25: warning: exported type Output should have comment or be unexported (golint)
    • Line 49: warning: exported function MultiOutput should have comment or be unexported (golint)
    • Line 66: warning: exported function FuncOutput should have comment or be unexported (golint)
    • Line 70: warning: exported type NopOutput should have comment or be unexported (golint)
    • Line 74: warning: exported method NopOutput.Close should have comment or be unexported (golint)
    • maddy/internal/check/dkim/dkim.go
    • Line 43: warning: exported type Check should have comment or be unexported (golint)
    • Line 55: warning: exported function New should have comment or be unexported (golint)
    • Line 66: warning: exported method Check.Init should have comment or be unexported (golint)
    • Line 93: warning: exported method Check.Name should have comment or be unexported (golint)
    • Line 97: warning: exported method Check.InstanceName should have comment or be unexported (golint)
    • Line 262: warning: exported method Check.CheckStateForMsg should have comment or be unexported (golint)
    • maddy/internal/table/regexp.go
    • Line 30: warning: exported type Regexp should have comment or be unexported (golint)
    • Line 41: warning: exported function NewRegexp should have comment or be unexported (golint)
    • Line 49: warning: exported method Regexp.Init should have comment or be unexported (golint)
    • Line 90: warning: exported method Regexp.Name should have comment or be unexported (golint)
    • Line 94: warning: exported method Regexp.InstanceName should have comment or be unexported (golint)
    • Line 98: warning: exported method Regexp.Lookup 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