mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-16 04:50:29 +00:00
isisd: Prevent direct copy of different size prefix'es
Memory is allocated for a `struct prefix_ipv6` but it was directly copied into a `struct prefix` via direct pointer copy, which leads to a read past end of memory. Fix by using prefix_copy Signed-off-by: Donald Sharp <sharpd@nvidia.com>
This commit is contained in:
parent
ae6ca0e643
commit
14678bfa0d
@ -909,7 +909,7 @@ static int lsp_to_subnet_cb(const struct prefix *prefix, uint32_t metric,
|
|||||||
p.u.prefix6 = std->local6;
|
p.u.prefix6 = std->local6;
|
||||||
}
|
}
|
||||||
if (!std)
|
if (!std)
|
||||||
p = *prefix;
|
prefix_copy(&p, prefix);
|
||||||
else
|
else
|
||||||
te_debug(" |- Adjust prefix %pFX with local address to: %pFX",
|
te_debug(" |- Adjust prefix %pFX with local address to: %pFX",
|
||||||
prefix, &p);
|
prefix, &p);
|
||||||
|
Loading…
Reference in New Issue
Block a user