summaryrefslogtreecommitdiff
path: root/roles/uvok_bird/templates
diff options
context:
space:
mode:
Diffstat (limited to 'roles/uvok_bird/templates')
-rw-r--r--roles/uvok_bird/templates/clearnet.conf.j212
1 files changed, 12 insertions, 0 deletions
diff --git a/roles/uvok_bird/templates/clearnet.conf.j2 b/roles/uvok_bird/templates/clearnet.conf.j2
index 2c99411..bb057d1 100644
--- a/roles/uvok_bird/templates/clearnet.conf.j2
+++ b/roles/uvok_bird/templates/clearnet.conf.j2
@@ -55,6 +55,18 @@ define BOGON_PREFIXES = [ ::/0, # Default route
ff00::/8+ # RFC 4291 multicast
];
+function is_default_route() -> bool {
+ case net.type {
+ NET_IP4: return net = 0.0.0.0/0;
+ NET_IP6: return net = ::/0;
+ else: return false;
+ }
+}
+
+function accept_default_route() {
+ if is_default_route() then accept;
+}
+
function reject_bogon_asns()
int set bogon_asns;
{