webrtc_m130/test/fuzzers/dtls_utils_fuzzer.cc
Philipp Hancke adacadb678 fuzzers: add DTLS fuzzer
to fuzz the code parsing DTLS packets for DTLS-STUN piggybacking

BUG=webrtc:367395350

Change-Id: Ifa1a52ef56b322e465604e8d49ae18e5dc27613f
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/371360
Reviewed-by: Jonas Oreland <jonaso@webrtc.org>
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Commit-Queue: Philipp Hancke <phancke@meta.com>
Cr-Commit-Position: refs/heads/main@{#43562}
2024-12-13 09:24:55 -08:00

22 lines
678 B
C++

/*
* Copyright (c) 2024 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 <cstddef>
#include <cstdint>
#include "api/array_view.h"
#include "p2p/dtls/dtls_utils.h"
namespace webrtc {
void FuzzOneInput(const uint8_t* data, size_t size) {
cricket::GetDtlsHandshakeAcks(rtc::MakeArrayView(data, size));
}
} // namespace webrtc