1
0
mirror of https://git.libssh.org/projects/libssh.git synced 2025-07-29 13:01:13 +03:00

fuzz: Provide host and ssh dir for the fuzzer

Signed-off-by: Jakub Jelen <jjelen@redhat.com>
Reviewed-by: Anderson Toshiyuki Sasaki <ansasaki@redhat.com>
This commit is contained in:
Jakub Jelen
2022-02-15 11:34:11 +01:00
parent 4975487c18
commit f97ff7c2e8

View File

@ -40,6 +40,10 @@ int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
session = ssh_new();
assert(session != NULL);
/* Make sure we have default options set */
ssh_options_set(session, SSH_OPTIONS_SSH_DIR, NULL);
ssh_options_set(session, SSH_OPTIONS_HOST, "example.com");
ssh_config_parse_string(session, input);
ssh_free(session);