summaryrefslogtreecommitdiffstats
path: root/nest/proto.c
diff options
context:
space:
mode:
authorMartin Mares <mj@ucw.cz>1999-04-05 22:15:31 +0200
committerMartin Mares <mj@ucw.cz>1999-04-05 22:15:31 +0200
commit5056c559c4eb253a4eee10cf35b694faec5265eb (patch)
tree404a26d748f50a40514f0d0ed448034b7dfa396b /nest/proto.c
parent63a381dbf5e37c2740982d07988cea983c699816 (diff)
downloadbird-5056c559c4eb253a4eee10cf35b694faec5265eb.tar
bird-5056c559c4eb253a4eee10cf35b694faec5265eb.zip
Changed syntax of attaching filters to protocols to hopefully the final
version: EXPORT <filter-spec> for outbound routes (i.e., those announced by BIRD to the rest of the world). IMPORT <filter-spec> for inbound routes (i.e., those imported by BIRD from the rest of the world). where <filter-spec> is one of: ALL pass all routes NONE drop all routes FILTER <name> use named filter FILTER { <filter> } use explicitly defined filter For all protocols, the default is IMPORT ALL, EXPORT NONE. This includes the kernel protocol, so that you need to add EXPORT ALL to get the previous configuration of kernel syncer (as usually, see doc/bird.conf.example for a bird.conf example :)).
Diffstat (limited to 'nest/proto.c')
-rw-r--r--nest/proto.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/nest/proto.c b/nest/proto.c
index f230c8e..ad4aa11 100644
--- a/nest/proto.c
+++ b/nest/proto.c
@@ -111,6 +111,7 @@ proto_config_new(struct protocol *pr, unsigned size)
c->proto = pr;
c->debug = pr->debug;
c->name = pr->name;
+ c->out_filter = FILTER_REJECT;
return c;
}
@@ -247,9 +248,9 @@ protos_dump_all(void)
debug(" protocol %s (pri=%d): state %s/%s\n", p->name, p->proto->priority,
p_states[p->proto_state], c_states[p->core_state]);
if (p->in_filter)
- debug("\tInput filter: %s\n", p->in_filter->name);
- if (p->out_filter)
- debug("\tOutput filter: %s\n", p->out_filter->name);
+ debug("\tInput filter: %s\n", filter_name(p->in_filter));
+ if (p->out_filter != FILTER_REJECT)
+ debug("\tOutput filter: %s\n", filter_name(p->out_filter));
if (p->disabled)
debug("\tDISABLED\n");
else if (p->proto->dump)