From 6bf6be9d8ea6c5fbac7c34a78eb5850f86c096ef Mon Sep 17 00:00:00 2001 From: gaoyuheng Date: Tue, 5 May 2026 16:16:25 +0800 Subject: [PATCH] =?UTF-8?q?=E8=A7=A3=E5=86=B3=E6=89=BE=E4=B8=8D=E5=88=B0IP?= =?UTF-8?q?=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- bird/net/unet.conf | 31 ++++++------------------------- 1 file changed, 6 insertions(+), 25 deletions(-) diff --git a/bird/net/unet.conf b/bird/net/unet.conf index 1980d7b..42ffe89 100644 --- a/bird/net/unet.conf +++ b/bird/net/unet.conf @@ -1,15 +1,11 @@ # 公网处理 => inet4/6 protocol pipe unet4_inet4_sync { table unet4; - peer table t102v4; + peer table inet4; export filter { if bgp_large_community ~ [(UNET_ASN, 3,*)] then reject; if is_bogon_prefix() then reject; bgp_path.empty; - bgp_community.empty; - bgp_large_community.empty; - bgp_large_community.add((UNET_ASN,10,10204)); - krt_prefsrc = LOCAL_V4_kernel; accept; }; import none; @@ -17,15 +13,11 @@ protocol pipe unet4_inet4_sync { protocol pipe unet6_inet6_sync { table unet6; - peer table t102v6; + peer table inet6; export filter { if bgp_large_community ~ [(UNET_ASN, 3,*)] then reject; if is_bogon_prefix() then reject; bgp_path.empty; - bgp_community.empty; - bgp_large_community.empty; - bgp_large_community.add((UNET_ASN,10,10206)); - krt_prefsrc = LOCAL_V6_kernel; accept; }; import none; @@ -35,15 +27,11 @@ protocol pipe unet6_inet6_sync { # DN42处理 => dn42v4/6 protocol pipe unet4_dn42v4_sync { table unet4; - peer table t102v4; + peer table dn42v4; export filter { if bgp_large_community ~ [(UNET_ASN, 3,*)] then reject; if !is_dn42_prefix() then reject; bgp_path.empty; - bgp_community.empty; - bgp_large_community.empty; - bgp_large_community.add((UNET_ASN,10,10204)); - krt_prefsrc = DN42_V4_kernel; accept; }; import none; @@ -51,15 +39,11 @@ protocol pipe unet4_dn42v4_sync { protocol pipe unet6_dn42v6_sync { table unet6; - peer table t102v6; + peer table dn42v6; export filter { if bgp_large_community ~ [(UNET_ASN, 3,*)] then reject; if !is_dn42_prefix() then reject; bgp_path.empty; - bgp_community.empty; - bgp_large_community.empty; - bgp_large_community.add((UNET_ASN,10,10206)); - krt_prefsrc = DN42_V6_kernel; accept; }; import none; @@ -84,13 +68,10 @@ protocol pipe unet4_sync { protocol pipe unet4_syncto_inet4 { table unet4; - peer table t102v4; + peer table inet4; export filter { if bgp_large_community ~ [(UNET_ASN, 3,*)] then reject; - bgp_community.empty; - bgp_large_community.empty; - bgp_large_community.add((UNET_ASN,10,10204)); - krt_prefsrc = UNET_V4_kernel; + if net!~[10.188.0.0/16+] then reject; accept; }; import none;