From nobody Thu Jun 23 19:52:47 2022 X-Original-To: bugs@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 42D9686DBB3 for ; Thu, 23 Jun 2022 19:52:48 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4LTWBS0D3wz4bc8 for ; Thu, 23 Jun 2022 19:52:48 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id DC7DB21B08 for ; Thu, 23 Jun 2022 19:52:47 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 25NJqlgQ026054 for ; Thu, 23 Jun 2022 19:52:47 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 25NJqlVs026053 for bugs@FreeBSD.org; Thu, 23 Jun 2022 19:52:47 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: bugs@FreeBSD.org Subject: [Bug 264858] IPv6: 'route add' sets wrong netif in fib when iface has different fib Date: Thu, 23 Jun 2022 19:52:47 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: bin X-Bugzilla-Version: 13.1-RELEASE X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: pmc@citylink.dinoex.sub.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Bug reports List-Archive: https://lists.freebsd.org/archives/freebsd-bugs List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-bugs@freebsd.org MIME-Version: 1.0 ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1656013968; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=CwzwbBWDcLCkbTssvbDnJPaAQjWQbPZLNZTUOBPk1uM=; b=ov/ZuIk2AruJ06ur8d00/5tYSSe8eDfqGeq+RK8p7JEYTanMJPqOYYUcmqGyvPpABpL8eY 6HOgc/KTpUwWdygQ4pgGKCFXTKYrSNIOcZAi29WYLzNWQmkk3SiGFVuHBL4Dfq0FOb9RfF A3HUnnaL6HyRudIRdHT5iTcs5OuK9Hv9MmkxNsUHL+088rqtuFr1351VMKyrS2hWJscGl6 8GNWp5Cc3EpH+NjAOCm18KqGKmsKW9pJLtS/VPMgxcChfG8R6HdDTdeXs4WpIw8mTQGA6O TKUDHo0vaGj5+WgKXu/se3Iph84prr76iDjIALCVczHBAC0Spn3/dnuLAtfgkQ== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1656013968; a=rsa-sha256; cv=none; b=aff6Rymp3SddBfhuJEKA+20kf6QLCutJ3OdsF3gklOuttyek+8y4UHAPgmm8cd8BZfW6v6 Mdsp2TzOsLTUuO4LjeqleRfcbrlHmGNEXEeQr7Zh5HRp5D3ti3IKzF4oMuZksPoEYGSxlX 6ahlIR2YU57CGb/90q18TMr+kwK3T3OcJ8HCH9dIp1n5vz+8Ivk0BtSAhs3AqGOcl23Npo +5bzyTbamGXgPT79j3CoYVrwQ2Dm/yRX58D/jSAWpMsuFVWIHsgoaIUU6/X40ZBnXDlJgW ycyysqy3mLpanm40V28CZZzEb3RxF30jvnPoN5fNw+hExinQKm9THv9Xt9ervw== ARC-Authentication-Results: i=1; mx1.freebsd.org; none X-ThisMailContainsUnwantedMimeParts: N https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D264858 Bug ID: 264858 Summary: IPv6: 'route add' sets wrong netif in fib when iface has different fib Product: Base System Version: 13.1-RELEASE Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: bin Assignee: bugs@FreeBSD.org Reporter: pmc@citylink.dinoex.sub.org When adding a route into a fib, it may get connected to lo0 instead of the desired interface, and traffic does not work. Example: -------- # ifconfig tun6 tun6: flags=3D8010 metric 0 mtu 1371 options=3D80000 groups: tun nd6 options=3D1 # setfib 4 netstat -rn6 Routing tables (fib: 4) Internet6: Destination Gateway Flags N= etif Expire ::/96 ::1 UGRS = lo0 ::1 link#1 UHS = lo0 ::ffff:0.0.0.0/96 ::1 UGRS = lo0 fe80::/10 ::1 UGRS = lo0 ff02::/16 ::1 UGRS = lo0 # ifconfig tun6 inet6 fe80::1%tun6 prefixlen 124 # route -6 add -net fe80::1%tun6/124 -iface tun6 -fib 4 add net fe80::1%tun6/124: gateway tun6 fib 4 # route -6 add -net default fe80::2%tun6 -fib 4 add net default: gateway fe80::2%tun6 fib 4 # setfib 4 netstat -rn6 Routing tables (fib: 4) Internet6: Destination Gateway Flags N= etif Expire ::/96 ::1 UGRS = lo0 default fe80::2%tun6 UGS = lo0 << ::1 link#1 UHS = lo0 ::ffff:0.0.0.0/96 ::1 UGRS = lo0 fe80::/10 ::1 UGRS = lo0 fe80::%tun6/124 link#4 US = tun6 ff02::/16 ::1 UGRS = lo0 But then, when changing the interface itself to the fib, it suddenly works = as desired: # route -6 delete -net default fe80::2%tun6 -fib 4 delete net default: gateway fe80::2%tun6 fib 4 # ifconfig tun6 inet fib 4 # route -6 add -net default fe80::2%tun6 -fib 4 add net default: gateway fe80::2%tun6 fib 4 # setfib 4 netstat -rn6 Routing tables (fib: 4) Internet6: Destination Gateway Flags N= etif Expire ::/96 ::1 UGRS = lo0 default fe80::2%tun6 UGS = tun6 << ::1 link#1 UHS = lo0 ::ffff:0.0.0.0/96 ::1 UGRS = lo0 fe80::/10 ::1 UGRS = lo0 fe80::%tun6/124 link#4 US = tun6 ff02::/16 ::1 UGRS = lo0 I don't think this is the correct behaviour, because the fib on the interfa= ce should concern incoming traffic, while the route table concerns outgoing traffic, and one might want this to be separate concerns. --=20 You are receiving this mail because: You are the assignee for the bug.=