{"record":{"id":"f08e7c4d41285e53","repo":"netbirdio/netbird","slug":"create-v6-default-allow-rules-w","errorCode":null,"errorMessage":"create v6 default allow rules: %w","messagePattern":"create v6 default allow rules: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"client/firewall/nftables/manager_linux.go","lineNumber":453,"sourceCode":"// This is called when USPFilter wraps the native firewall, adding blanket accept\n// rules so that packet filtering is handled in userspace instead of by netfilter.\n//\n// TODO: In USP mode this only adds ACCEPT to the netbird table's own chains,\n// which doesn't override DROP rules in external tables (e.g. firewalld).\n// Should add passthrough rules to external chains (like the native mode router's\n// addExternalChainsRules does) for both the netbird table family and inet tables.\n// The netbird table itself is fine (routing chains already exist there), but\n// non-netbird tables with INPUT/FORWARD hooks can still DROP our WG traffic.\nfunc (m *Manager) AllowNetbird() error {\n\tm.mutex.Lock()\n\tdefer m.mutex.Unlock()\n\n\tif err := m.aclManager.createDefaultAllowRules(); err != nil {\n\t\treturn fmt.Errorf(\"create default allow rules: %w\", err)\n\t}\n\tif m.hasIPv6() {\n\t\tif err := m.aclManager6.createDefaultAllowRules(); err != nil {\n\t\t\treturn fmt.Errorf(\"create v6 default allow rules: %w\", err)\n\t\t}\n\t}\n\tif err := m.rConn.Flush(); err != nil {\n\t\treturn fmt.Errorf(\"flush allow input netbird rules: %w\", err)\n\t}\n\n\tif err := firewalld.TrustInterface(m.wgIface.Name()); err != nil {\n\t\tlog.Warnf(\"failed to trust interface in firewalld: %v\", err)\n\t}\n\n\treturn nil\n}\n\n// SetLegacyManagement sets the route manager to use legacy management\nfunc (m *Manager) SetLegacyManagement(isLegacy bool) error {\n\tif err := firewall.SetLegacyManagement(m.router, isLegacy); err != nil {\n\t\treturn err\n\t}","sourceCodeStart":435,"sourceCodeEnd":471,"githubUrl":"https://github.com/netbirdio/netbird/blob/93e97f4bf1ad715072dcb3fb6cdb1763431b5a9c/client/firewall/nftables/manager_linux.go#L435-L471","documentation":"The IPv6 aclManager failed to create its default allow rules during AllowNetbird. It only runs when the manager has v6 initialized, and fires when the v6 netlink insert of blanket accept rules is rejected by the kernel or the v6 table state is inconsistent.","triggerScenarios":"Thrown at client/firewall/nftables/manager_linux.go:453 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Confirm IPv6 nftables support is enabled on the host","Recreate the firewall manager to rebuild the v6 work table","Check dmesg for netlink/nftables rejection reasons"],"exampleFix":null,"handlingStrategy":"retry","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"93e97f4bf1ad715072dcb3fb6cdb1763431b5a9c","analyzedAt":"2026-08-16T03:09:19.136Z","contentChangedAt":"2026-08-16T03:09:19.136Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}