]> git.puffer.fish Git - matthieu/frr.git/commitdiff
* vtysh_config.c: Move password commands to the AAA_NODE. It
authorhasso <hasso>
Wed, 9 Mar 2005 12:41:14 +0000 (12:41 +0000)
committerhasso <hasso>
Wed, 9 Mar 2005 12:41:14 +0000 (12:41 +0000)
  quarantees that they will appear after SERVICE_NODE to make sure
  that encrypted passwords will work ("service password-encryption"
  command).

[backport candidate]

vtysh/ChangeLog
vtysh/vtysh_config.c

index 6822126ea99d4d73f4e888cf8eb83924d49eb951..9d6d3c09a6f04cab49108433f149d0c839830ba0 100644 (file)
@@ -1,3 +1,10 @@
+2005-03-09 Hasso Tepper <hasso at quagga.net>
+
+       * vtysh_config.c: Move password commands to the AAA_NODE. It
+         quarantees that they will appear after SERVICE_NODE to make sure
+         that encrypted passwords will work ("service password-encryption"
+         command).
+
 2005-01-28 Andrew J. Schorr <ajschorr@alumni.princeton.edu>
 
        * vtysh.h: Remove obsolete VTYSH_INDEX_* defines.  Fix many prototypes
index c7be8d2696b3747a8fc7be2107a4271619d3dc93..14efa4861c786d70985b043d4514cfaf836e7aca 100644 (file)
@@ -240,14 +240,14 @@ vtysh_config_parse_line (const char *line)
        config = config_get (SERVICE_NODE, line);
       else if (strncmp (line, "debug", strlen ("debug")) == 0)
        config = config_get (DEBUG_NODE, line);
+      else if (strncmp (line, "password", strlen ("password")) == 0
+              || strncmp (line, "enable password",
+                          strlen ("enable password")) == 0)
+       config = config_get (AAA_NODE, line);
       else
        {
          if (strncmp (line, "log", strlen ("log")) == 0
              || strncmp (line, "hostname", strlen ("hostname")) == 0
-             || strncmp (line, "password", strlen ("password")) == 0
-             || strncmp (line, "enable password",
-                         strlen ("enable password")) == 0
-             || strncmp (line, "service", strlen ("service")) == 0
             )
            config_add_line_uniq (config_top, line);
          else
@@ -287,7 +287,8 @@ vtysh_config_parse (char *line)
   ((I) == ACCESS_NODE || (I) == PREFIX_NODE || (I) == IP_NODE \
    || (I) == AS_LIST_NODE || (I) == COMMUNITY_LIST_NODE || \
    (I) == ACCESS_IPV6_NODE || (I) == PREFIX_IPV6_NODE \
-   || (I) == SERVICE_NODE || (I) == FORWARDING_NODE || (I) == DEBUG_NODE)
+   || (I) == SERVICE_NODE || (I) == FORWARDING_NODE || (I) == DEBUG_NODE \
+   || (I) == AAA_NODE)
 
 /* Display configuration to file pointer. */
 void