xref: /freebsd/crypto/openssh/regress/misc/fuzz-harness/pubkey_fuzz.cc (revision 0fca6ea1d4eea4c934cfff25ac9ee8ad6fe95583)
1 #include <stddef.h>
2 #include <stdio.h>
3 #include <stdint.h>
4 
5 extern "C" {
6 
7 #include "sshkey.h"
8 
9 int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size)
10 {
11 	struct sshkey *k = NULL;
12 	int r = sshkey_from_blob(data, size, &k);
13 	if (r == 0) sshkey_free(k);
14 	return 0;
15 }
16 
17 } // extern
18 
19