summaryrefslogtreecommitdiffstats
path: root/src/config.y
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2014-01-26 03:37:36 +0100
committerMatthias Schiffer <mschiffer@universe-factory.net>2014-01-26 03:37:36 +0100
commit53d331406d6b1cbe934528f87023b87887993e0e (patch)
tree7d8406c0bfc3ec9521c49d60ad977765280d8ceb /src/config.y
parentcc498848b36b347aa9b710ab55c1fcc8643a4633 (diff)
downloadfastd-53d331406d6b1cbe934528f87023b87887993e0e.tar
fastd-53d331406d6b1cbe934528f87023b87887993e0e.zip
Add support for setting packet marks
Diffstat (limited to 'src/config.y')
-rw-r--r--src/config.y7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/config.y b/src/config.y
index 94d8320..a14794f 100644
--- a/src/config.y
+++ b/src/config.y
@@ -95,11 +95,13 @@
%token TOK_LIMIT
%token TOK_LOG
%token TOK_MAC
+%token TOK_MARK
%token TOK_METHOD
%token TOK_MODE
%token TOK_MTU
%token TOK_NO
%token TOK_ON
+%token TOK_PACKET
%token TOK_PEER
%token TOK_PEERS
%token TOK_PMTU
@@ -175,6 +177,7 @@ statement: peer_group_statement
| TOK_HIDE hide ';'
| TOK_INTERFACE interface ';'
| TOK_BIND bind ';'
+ | TOK_PACKET TOK_MARK packet_mark ';'
| TOK_MTU mtu ';'
| TOK_PMTU pmtu ';'
| TOK_MODE mode ';'
@@ -328,6 +331,10 @@ bind_default:
}
;
+packet_mark: TOK_UINT {
+ conf->packet_mark = $1;
+ }
+
mtu: TOK_UINT {
if ($1 < 576 || $1 > 65535) {
fastd_config_error(&@$, ctx, conf, filename, depth, "invalid MTU");