diff options
author | Mobashshera Rasool <mrasool@vmware.com> | 2022-02-18 07:03:07 +0100 |
---|---|---|
committer | Mobashshera Rasool <mrasool@vmware.com> | 2022-02-21 07:21:31 +0100 |
commit | fcfd479d99295f82ef5979fc74ca38c9787cac2d (patch) | |
tree | b1115f8654e0f2f79c9664b355a1cf9b0689bd67 /pimd/pim_nb_config.c | |
parent | Merge pull request #10604 from mjstapp/fix_staticd_nh_count (diff) | |
download | frr-fcfd479d99295f82ef5979fc74ca38c9787cac2d.tar.xz frr-fcfd479d99295f82ef5979fc74ca38c9787cac2d.zip |
pimd: Do not allow 224.0.0.0/24 range in igmp join
224.0.0.0/24 cannot be used by igmp since this is reserved
for routing protocols and other low-level topology discovery or
maintenance protocols.
Fixes: #10614
Signed-off-by: Mobashshera Rasool <mrasool@vmware.com>
Diffstat (limited to 'pimd/pim_nb_config.c')
-rw-r--r-- | pimd/pim_nb_config.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/pimd/pim_nb_config.c b/pimd/pim_nb_config.c index 376615729..8a78489ae 100644 --- a/pimd/pim_nb_config.c +++ b/pimd/pim_nb_config.c @@ -31,6 +31,7 @@ #include "pim_ssm.h" #include "pim_ssmpingd.h" #include "pim_vxlan.h" +#include "pim_util.h" #include "log.h" #include "lib_errors.h" @@ -2833,6 +2834,14 @@ int lib_interface_gmp_address_family_static_group_create( ifp_name); return NB_ERR_VALIDATION; } + + yang_dnode_get_ip(&group_addr, args->dnode, "./group-addr"); + if (pim_is_group_224_0_0_0_24(group_addr.ip._v4_addr)) { + snprintf( + args->errmsg, args->errmsg_len, + "Groups within 224.0.0.0/24 are reserved and cannot be joined"); + return NB_ERR_VALIDATION; + } break; case NB_EV_PREPARE: case NB_EV_ABORT: |