xref: /freebsd/crypto/openssh/regress/misc/fuzz-harness/pubkey_fuzz.cc (revision fe75646a0234a261c0013bf1840fdac4acaf0cec)
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