]> git.ipfire.org Git - thirdparty/bird.git/commitdiff
Make rip use newly defined password lists.
authorPavel Machek <pavel@ucw.cz>
Wed, 26 May 1999 14:37:47 +0000 (14:37 +0000)
committerPavel Machek <pavel@ucw.cz>
Wed, 26 May 1999 14:37:47 +0000 (14:37 +0000)
proto/rip/config.Y
proto/rip/rip.c
proto/rip/rip.h

index f7839f26becec3569db63defe3f42b49f8dab7ff..a3e877dac6955e8ba106d08eb2312b7c018ca2d5 100644 (file)
@@ -24,7 +24,7 @@ struct rip_patt *rip_get_iface(void);
 
 CF_DECLS
 
-CF_KEYWORDS(RIP, INFINITY, METRIC, PORT, PERIOD, GARBAGETIME, PASSWORD,
+CF_KEYWORDS(RIP, INFINITY, METRIC, PORT, PERIOD, GARBAGETIME, PASSWORDS,
            MODE, BROADCAST, QUIET, NOLISTEN, VERSION1, 
            AUTHENTICATION, NONE, PLAINTEXT, MD5)
 
@@ -47,8 +47,8 @@ RIP_CFG:
  | RIP_CFG PORT expr ';'       { RIP_CFG->port = $3; }
  | RIP_CFG PERIOD expr ';'     { RIP_CFG->period = $3; }
  | RIP_CFG GARBAGETIME expr ';' { RIP_CFG->garbage_time = $3; }
- | RIP_CFG PASSWORD TEXT ';'   { RIP_CFG->password = $3; }
  | RIP_CFG AUTHENTICATION rip_auth ';' {RIP_CFG->authtype = $3; }
+ | RIP_CFG PASSWORDS '{' password_list '}' {RIP_CFG->passwords = $4; }
  | RIP_CFG rip_iface_list ';'
  ;
 
index 16c63aec834610a7572bb863a9bc20e9b3ded064..8d81486170c02ff097f9c5c7fce52bb00b0d1a28 100644 (file)
@@ -603,7 +603,7 @@ rip_init_config(struct rip_proto_config *c)
   c->port      = 520;
   c->period    = 30;
   c->garbage_time = 120+180;
-  c->password  = "PASSWORD";
+  c->passwords = NULL;
   c->authtype  = AT_NONE;
 }
 
index a413f7198ba5f5b93f58d0640e1b9039e5acd5a9..efad4a6de2821a53f22deff4b55b4ee2bdb97d74 100644 (file)
@@ -3,6 +3,7 @@
  */
 
 #include "nest/route.h"
+#include "nest/password.h"
 
 struct rip_connection {
   node n;
@@ -92,7 +93,7 @@ struct rip_proto_config {
   int period;
   int garbage_time;
 
-  char *password;
+  struct password_item *passwords;
   int authtype;
 #define AT_NONE 0
 #define AT_PLAINTEXT 2