summaryrefslogtreecommitdiff
path: root/sysdep/unix/krt.Y
diff options
context:
space:
mode:
authorOndrej Zajicek <santiago@crfreenet.org>2010-04-04 15:41:31 +0200
committerOndrej Zajicek <santiago@crfreenet.org>2010-04-04 15:41:31 +0200
commitc429d4a4ba2cc8778634461e8adea33e0f0ae022 (patch)
tree5cc8102345bf3ce872da92aca84fa63cf67c4e20 /sysdep/unix/krt.Y
parentd2d2b5d2ae43f608d03304d280367b658650138b (diff)
Restrict export of device routes to the kernel protocol.
In usual configuration, such export is already restricted with the aid of the direct protocol but there are some races that can circumvent it. This makes it harder to break kernel device routes. Also adds an option to disable this restriction.
Diffstat (limited to 'sysdep/unix/krt.Y')
-rw-r--r--sysdep/unix/krt.Y3
1 files changed, 2 insertions, 1 deletions
diff --git a/sysdep/unix/krt.Y b/sysdep/unix/krt.Y
index 40f1af9f..0375a13b 100644
--- a/sysdep/unix/krt.Y
+++ b/sysdep/unix/krt.Y
@@ -17,7 +17,7 @@ CF_DEFINES
CF_DECLS
-CF_KEYWORDS(KERNEL, PERSIST, SCAN, TIME, LEARN, DEVICE)
+CF_KEYWORDS(KERNEL, PERSIST, SCAN, TIME, LEARN, DEVICE, ROUTES)
CF_GRAMMAR
@@ -56,6 +56,7 @@ kern_item:
cf_error("Learning of kernel routes not supported in this configuration");
#endif
}
+ | DEVICE ROUTES bool { THIS_KRT->devroutes = $3; }
;
/* Kernel interface protocol */