Add generic depacketizer fuzzer to WebRTC.
The generic video depacketizer was missed in the initial fuzzing pass. Bug: webrtc:10395 Change-Id: I166f27fc5897a2eafe38dad8e074834fefcc330e Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/127041 Reviewed-by: Qingsi Wang <qingsi@webrtc.org> Commit-Queue: Benjamin Wright <benwright@webrtc.org> Cr-Commit-Position: refs/heads/master@{#27088}
This commit is contained in:
parent
ade5cb8294
commit
6a5e976fbe
@ -65,6 +65,15 @@ webrtc_fuzzer_test("h264_depacketizer_fuzzer") {
|
||||
]
|
||||
}
|
||||
|
||||
webrtc_fuzzer_test("generic_depacketizer_fuzzer") {
|
||||
sources = [
|
||||
"generic_depacketizer_fuzzer.cc",
|
||||
]
|
||||
deps = [
|
||||
"../../modules/rtp_rtcp",
|
||||
]
|
||||
}
|
||||
|
||||
webrtc_fuzzer_test("vp8_depacketizer_fuzzer") {
|
||||
sources = [
|
||||
"vp8_depacketizer_fuzzer.cc",
|
||||
|
||||
22
test/fuzzers/generic_depacketizer_fuzzer.cc
Normal file
22
test/fuzzers/generic_depacketizer_fuzzer.cc
Normal file
@ -0,0 +1,22 @@
|
||||
/*
|
||||
* Copyright (c) 2019 The WebRTC project authors. All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by a BSD-style license
|
||||
* that can be found in the LICENSE file in the root of the source
|
||||
* tree. An additional intellectual property rights grant can be found
|
||||
* in the file PATENTS. All contributing project authors may
|
||||
* be found in the AUTHORS file in the root of the source tree.
|
||||
*/
|
||||
|
||||
#include "modules/rtp_rtcp/source/rtp_format.h"
|
||||
#include "modules/rtp_rtcp/source/rtp_format_video_generic.h"
|
||||
|
||||
namespace webrtc {
|
||||
|
||||
void FuzzOneInput(const uint8_t* data, size_t size) {
|
||||
RtpDepacketizerGeneric depacketizer;
|
||||
RtpDepacketizer::ParsedPayload parsed_payload;
|
||||
depacketizer.Parse(&parsed_payload, data, size);
|
||||
}
|
||||
|
||||
} // namespace webrtc
|
||||
Loading…
x
Reference in New Issue
Block a user