{"record":{"id":"4ae2f421f78e9a54","repo":"slackhq/nebula","slug":"no-connection-manager","errorCode":null,"errorMessage":"no connection manager","messagePattern":"no connection manager","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"critical","filePath":"interface.go","lineNumber":198,"sourceCode":"\t\treturn fmt.Sprintf(\"invalid(%d)\", s)\n\t}\n}\n\nfunc NewInterface(ctx context.Context, c *InterfaceConfig) (*Interface, error) {\n\tif c.Outside == nil {\n\t\treturn nil, errors.New(\"no outside connection\")\n\t}\n\tif c.Inside == nil {\n\t\treturn nil, errors.New(\"no inside interface (tun)\")\n\t}\n\tif c.pki == nil {\n\t\treturn nil, errors.New(\"no certificate state\")\n\t}\n\tif c.Firewall == nil {\n\t\treturn nil, errors.New(\"no firewall rules\")\n\t}\n\tif c.connectionManager == nil {\n\t\treturn nil, errors.New(\"no connection manager\")\n\t}\n\n\tif c.routines <= 1 {\n\t\tc.PinThreads = false //pinning is not useful unless there's more than one tun reader\n\t}\n\n\tcs := c.pki.getCertState()\n\tifce := &Interface{\n\t\tctx:                   ctx,\n\t\tpki:                   c.pki,\n\t\thostMap:               c.HostMap,\n\t\toutside:               c.Outside,\n\t\tinside:                c.Inside,\n\t\tfirewall:              c.Firewall,\n\t\tdnsServer:             c.DnsServer,\n\t\thandshakeManager:      c.HandshakeManager,\n\t\tcreateTime:            time.Now(),\n\t\tlightHouse:            c.lightHouse,","sourceCodeStart":180,"sourceCodeEnd":216,"githubUrl":"https://github.com/slackhq/nebula/blob/dd8f660c0ac37903ec4080ca4d3c861ba9342ceb/interface.go#L180-L216","documentation":"Sentinel validation error raised in NewInterface when the InterfaceConfig passed in has a nil connectionManager. It is one of five required-component checks (outside connection, tun device, PKI state, firewall rules, connection manager) that guard construction of a Interface; it fires when the caller (Main) built the config without wiring up a connection manager implementation before calling NewInterface. The interface cannot manage peer handshakes/lighthouse traffic without one, so construction is aborted rather than returning a half-initialized Interface.","triggerScenarios":"InterfaceConfig.connectionManager is nil because NewConnectionManager was not called or its result was not assigned before NewInterface.","commonSituations":"Wiring bug when embedding nebula as a library; earlier initialization failure that left the manager nil; partial refactor dropping the field assignment.","solutions":["Ensure connectionManager := NewConnectionManager(...) is called and assigned to InterfaceConfig before NewInterface","Check startup logs for earlier initialization errors that skipped manager creation","Update library usage to match current nebula Main() wiring"],"exampleFix":null,"handlingStrategy":"validation","validationCode":"if cfg.InterfaceConfig.ConnectionManager == nil {\n    return errors.New(\"connection manager missing; call NewConnectionManager before NewInterface\")\n}","typeGuard":null,"tryCatchPattern":"i, err := NewInterface(ctx, c)\nif err != nil {\n    if err.Error() == \"no connection manager\" { /* wire NewConnectionManager into the config */ }\n    return err\n}","preventionTips":["Mirror the field-initialization order of nebula's Main() when embedding","Add a startup self-check that all InterfaceConfig fields are non-nil","Re-diff your wiring against upstream Main() after upgrading nebula"],"tags":["config","nebula","startup","wiring"],"backgroundTag":"missing-required-config","analyzedSha":"dd8f660c0ac37903ec4080ca4d3c861ba9342ceb","analyzedAt":"2026-09-03T11:13:55.444Z","contentChangedAt":"2026-09-03T11:13:55.444Z","schemaVersion":2},"datasetVersion":"2026-09-10T17:17:09.494Z"}