Ensure not only Packet is valid, but also it's Parents are valid
This bug was found by fuzzer, that used *View::FromBytes(...) method on packet to create instance of WriteCurrentIacLapView which content was longer than what it's parent packet, Command can contain. Generated IsValid() method on WriteCurrentIacLapView was not calling parent packet IsValid() method to check if size is proper. IsValid() method in Builders doesn't have that issue, therefore when View was converted to Builder, crash on assert occured. This patch adds the missing call to parent IsValid() method. This never occured in production code, because we always construct partents, check theri validity, and then construct child views. Test: run bluetooth_gd_fuzz_test Bug: 177047996 Change-Id: Ife65b865acd745d67048c6d571ad555216098935
Loading
Please register or sign in to comment