mirror of
https://github.com/espressif/openthread.git
synced 2026-07-26 13:59:05 +00:00
[dataset] do not allow Extended TLVs in Operational Dataset (#5966)
This commit is contained in:
@@ -173,7 +173,8 @@ bool Dataset::IsValid(void) const
|
||||
|
||||
for (const Tlv *cur = GetTlvsStart(); cur < end; cur = cur->GetNext())
|
||||
{
|
||||
VerifyOrExit((cur + 1) <= end && cur->GetNext() <= end && Tlv::IsValid(*cur), rval = false);
|
||||
VerifyOrExit(!cur->IsExtended() && (cur + 1) <= end && cur->GetNext() <= end && Tlv::IsValid(*cur),
|
||||
rval = false);
|
||||
}
|
||||
|
||||
exit:
|
||||
|
||||
Reference in New Issue
Block a user