diff options
author | Igor Ryzhov <iryzhov@nfware.com> | 2021-04-07 14:16:47 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-04-07 14:16:47 +0200 |
commit | c53b1ff1980084507452026fc9b1bfe27cc66de6 (patch) | |
tree | 8658ff2262f9d8d60bfd9d4cb6e384f4522f257e | |
parent | Merge pull request #8413 from mjstapp/zebra_doc_debugs (diff) | |
parent | ospfd: permit over-write of message-digest-key (diff) | |
download | frr-c53b1ff1980084507452026fc9b1bfe27cc66de6.tar.xz frr-c53b1ff1980084507452026fc9b1bfe27cc66de6.zip |
Merge pull request #8415 from mjstapp/fix_ospf_keyid_config
ospfd: permit over-write of message-digest-key
-rw-r--r-- | ospfd/ospf_vty.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/ospfd/ospf_vty.c b/ospfd/ospf_vty.c index a1dac641d..92d13e616 100644 --- a/ospfd/ospf_vty.c +++ b/ospfd/ospf_vty.c @@ -7865,10 +7865,9 @@ DEFUN (ip_ospf_message_digest_key, } key_id = strtol(keyid, NULL, 10); - if (ospf_crypt_key_lookup(params->auth_crypt, key_id) != NULL) { - vty_out(vty, "OSPF: Key %d already exists\n", key_id); - return CMD_WARNING; - } + + /* Remove existing key, if any */ + ospf_crypt_key_delete(params->auth_crypt, key_id); ck = ospf_crypt_key_new(); ck->key_id = (uint8_t)key_id; |