/src/botan/src/fuzzer/cert.cpp
Line | Count | Source (jump to first uncovered line) |
1 | | /* |
2 | | * (C) 2015,2016 Jack Lloyd |
3 | | * |
4 | | * Botan is released under the Simplified BSD License (see license.txt) |
5 | | */ |
6 | | |
7 | | #include "fuzzers.h" |
8 | | #include <botan/x509cert.h> |
9 | | #include <botan/data_src.h> |
10 | | |
11 | | void fuzz(const uint8_t in[], size_t len) |
12 | 5.62k | { |
13 | 5.62k | if(len > max_fuzzer_input_size) |
14 | 0 | return; |
15 | | |
16 | 5.62k | try |
17 | 5.62k | { |
18 | 5.62k | Botan::DataSource_Memory input(in, len); |
19 | 5.62k | Botan::X509_Certificate cert(input); |
20 | 5.62k | } |
21 | 3.51k | catch(Botan::Exception& e) { } |
22 | 5.62k | } |