diff options
author | djm@openbsd.org <djm@openbsd.org> | 2020-01-26 00:09:50 +0000 |
---|---|---|
committer | Darren Tucker <dtucker@dtucker.net> | 2020-01-26 14:19:43 +1100 |
commit | f73ab8a811bc874c2fb403012aa8e4bfdcaf5ec7 (patch) | |
tree | 08f8e73a6124476b890a50dd5661cd2d3a02baf6 /regress/misc | |
parent | 0373f9eba2b63455dceedbd3ac3d5dca306789ff (diff) |
upstream: unbreak unittests for recent API / source file changes
OpenBSD-Regress-ID: 075a899a01bbf7781d38bf0b33d8366faaf6d3c0
Diffstat (limited to 'regress/misc')
-rw-r--r-- | regress/misc/kexfuzz/Makefile | 4 | ||||
-rw-r--r-- | regress/misc/kexfuzz/kexfuzz.c | 8 |
2 files changed, 4 insertions, 8 deletions
diff --git a/regress/misc/kexfuzz/Makefile b/regress/misc/kexfuzz/Makefile index 9cac412dc..9eb86931c 100644 --- a/regress/misc/kexfuzz/Makefile +++ b/regress/misc/kexfuzz/Makefile | |||
@@ -1,4 +1,4 @@ | |||
1 | # $OpenBSD: Makefile,v 1.6 2019/12/15 18:58:33 djm Exp $ | 1 | # $OpenBSD: Makefile,v 1.7 2020/01/26 00:09:50 djm Exp $ |
2 | 2 | ||
3 | .include <bsd.own.mk> | 3 | .include <bsd.own.mk> |
4 | .include <bsd.obj.mk> | 4 | .include <bsd.obj.mk> |
@@ -20,7 +20,7 @@ SRCS+=ssherr.c uidswap.c cleanup.c xmalloc.c match.c krl.c fatal.c | |||
20 | SRCS+=addrmatch.c bitmap.c packet.c dispatch.c canohost.c ssh_api.c | 20 | SRCS+=addrmatch.c bitmap.c packet.c dispatch.c canohost.c ssh_api.c |
21 | SRCS+=compat.c ed25519.c hash.c ge25519.c fe25519.c sc25519.c verify.c | 21 | SRCS+=compat.c ed25519.c hash.c ge25519.c fe25519.c sc25519.c verify.c |
22 | SRCS+=cipher-chachapoly.c chacha.c poly1305.c | 22 | SRCS+=cipher-chachapoly.c chacha.c poly1305.c |
23 | SRCS+=ssh-ecdsa-sk.c ssh-ed25519-sk.c msg.c ssh-sk-client.c | 23 | SRCS+=sshbuf-io.c ssh-ecdsa-sk.c ssh-ed25519-sk.c msg.c ssh-sk-client.c |
24 | 24 | ||
25 | SRCS+= kex.c | 25 | SRCS+= kex.c |
26 | SRCS+= dh.c | 26 | SRCS+= dh.c |
diff --git a/regress/misc/kexfuzz/kexfuzz.c b/regress/misc/kexfuzz/kexfuzz.c index 7051e87b1..56697c918 100644 --- a/regress/misc/kexfuzz/kexfuzz.c +++ b/regress/misc/kexfuzz/kexfuzz.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: kexfuzz.c,v 1.5 2019/01/21 12:50:12 djm Exp $ */ | 1 | /* $OpenBSD: kexfuzz.c,v 1.6 2020/01/26 00:09:50 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Fuzz harness for KEX code | 3 | * Fuzz harness for KEX code |
4 | * | 4 | * |
@@ -424,12 +424,8 @@ main(int argc, char **argv) | |||
424 | if (packet_index == -1 || direction == -1 || data_path == NULL) | 424 | if (packet_index == -1 || direction == -1 || data_path == NULL) |
425 | badusage("Replace (-r) mode must specify direction " | 425 | badusage("Replace (-r) mode must specify direction " |
426 | "(-D) packet index (-i) and data path (-f)"); | 426 | "(-D) packet index (-i) and data path (-f)"); |
427 | if ((fd = open(data_path, O_RDONLY)) == -1) | 427 | if ((r = sshbuf_load_file(data_path, &replace_data)) != 0) |
428 | err(1, "open %s", data_path); | ||
429 | replace_data = sshbuf_new(); | ||
430 | if ((r = sshkey_load_file(fd, replace_data)) != 0) | ||
431 | errx(1, "read %s: %s", data_path, ssh_err(r)); | 428 | errx(1, "read %s: %s", data_path, ssh_err(r)); |
432 | close(fd); | ||
433 | } | 429 | } |
434 | 430 | ||
435 | /* Dump mode */ | 431 | /* Dump mode */ |