File tree Expand file tree Collapse file tree 2 files changed +26
-0
lines changed Expand file tree Collapse file tree 2 files changed +26
-0
lines changed Original file line number Diff line number Diff line change @@ -210,6 +210,7 @@ test_fuzz_fuzz_SOURCES = \
210
210
test/fuzz/crypto_hkdf_hmac_sha256_l32.cpp \
211
211
test/fuzz/crypto_poly1305.cpp \
212
212
test/fuzz/cuckoocache.cpp \
213
+ test/fuzz/data_stream.cpp \
213
214
test/fuzz/decode_tx.cpp \
214
215
test/fuzz/descriptor_parse.cpp \
215
216
test/fuzz/deserialize.cpp \
Original file line number Diff line number Diff line change
1
+ // Copyright (c) 2020 The Bitcoin Core developers
2
+ // Distributed under the MIT software license, see the accompanying
3
+ // file COPYING or http://www.opensource.org/licenses/mit-license.php.
4
+
5
+ #include < addrman.h>
6
+ #include < net.h>
7
+ #include < test/fuzz/FuzzedDataProvider.h>
8
+ #include < test/fuzz/fuzz.h>
9
+ #include < test/fuzz/util.h>
10
+
11
+ #include < cstdint>
12
+ #include < vector>
13
+
14
+ void initialize_data_stream_addr_man ()
15
+ {
16
+ InitializeFuzzingContext ();
17
+ }
18
+
19
+ FUZZ_TARGET_INIT (data_stream_addr_man, initialize_data_stream_addr_man)
20
+ {
21
+ FuzzedDataProvider fuzzed_data_provider{buffer.data (), buffer.size ()};
22
+ CDataStream data_stream = ConsumeDataStream (fuzzed_data_provider);
23
+ CAddrMan addr_man;
24
+ CAddrDB::Read (addr_man, data_stream);
25
+ }
You can’t perform that action at this time.
0 commit comments