This commit is contained in:
Jesper Hess 2018-10-13 20:49:35 +02:00
parent ca50385f87
commit 90b1a7943f
Signed by: graffen
GPG key ID: 351A89E40D763F0F
2 changed files with 6 additions and 8 deletions

View file

@ -4,10 +4,9 @@ template bgp dnpeers {
# metric is the number of hops between us and the peer # metric is the number of hops between us and the peer
path metric 1; path metric 1;
import keep filtered;
import where dnpeers_import_policy(); import where dnpeers_import_policy();
export filter { export filter {
# here we export the whole net
if is_valid_network() then { if is_valid_network() then {
accept; accept;
} }
@ -41,5 +40,4 @@ protocol pipe {
peer table T_BGP; peer table T_BGP;
import all; import all;
export all; export all;
}; }
};

View file

@ -24,7 +24,7 @@ function check_roa() {
print "[dn42] ROA check failed for ", net, " ASN ", bgp_path.last; print "[dn42] ROA check failed for ", net, " ASN ", bgp_path.last;
return false; return false;
} }
return true: return true;
} }
function import_filter_networks() { function import_filter_networks() {
@ -35,6 +35,6 @@ function import_filter_networks() {
} }
function dnpeers_import_policy() { function dnpeers_import_policy() {
if(!check_roa()) return false; if(!check_roa()) then return false;
if(!import_filter_networks()) return false: if(!import_filter_networks()) then return false:
} }