]> git.bitcoin.ninja Git - rust-lightning/blobdiff - fuzz/fuzz_targets/channel_target.rs
Update NodeAnnouncement addr deserialization to check addr len.
[rust-lightning] / fuzz / fuzz_targets / channel_target.rs
index 73ea2c1d89f827f197818f96324786c0ed10b020..843c95ab76e6a7a01cf44529581f33c4a282b6b9 100644 (file)
@@ -120,6 +120,7 @@ pub fn do_test(data: &[u8]) {
                                        msgs::DecodeError::BadSignature => return,
                                        msgs::DecodeError::BadText => return,
                                        msgs::DecodeError::ExtraAddressesPerType => return,
+                                       msgs::DecodeError::BadLengthDescriptor => return,
                                        msgs::DecodeError::ShortRead => panic!("We picked the length..."),
                                }
                        }
@@ -141,6 +142,7 @@ pub fn do_test(data: &[u8]) {
                                                msgs::DecodeError::BadSignature => return,
                                                msgs::DecodeError::BadText => return,
                                                msgs::DecodeError::ExtraAddressesPerType => return,
+                                               msgs::DecodeError::BadLengthDescriptor => return,
                                                msgs::DecodeError::ShortRead => panic!("We picked the length..."),
                                        }
                                }