diff options
author | Colin Watson <cjwatson@debian.org> | 2018-04-03 08:20:28 +0100 |
---|---|---|
committer | Colin Watson <cjwatson@debian.org> | 2018-04-03 08:20:28 +0100 |
commit | ed6ae9c1a014a08ff5db3d768f01f2e427eeb476 (patch) | |
tree | 601025e307745d351946c01ab13f419ddb6dae29 /regress/unittests/sshkey/test_sshkey.c | |
parent | 62f54f20bf351468e0124f63cc2902ee40d9b0e9 (diff) | |
parent | a0349a1cc4a18967ad1dbff5389bcdf9da098814 (diff) |
Import openssh_7.7p1.orig.tar.gz
Diffstat (limited to 'regress/unittests/sshkey/test_sshkey.c')
-rw-r--r-- | regress/unittests/sshkey/test_sshkey.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/regress/unittests/sshkey/test_sshkey.c b/regress/unittests/sshkey/test_sshkey.c index 0a73322a3..1aa608f92 100644 --- a/regress/unittests/sshkey/test_sshkey.c +++ b/regress/unittests/sshkey/test_sshkey.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: test_sshkey.c,v 1.12 2017/05/08 06:08:42 djm Exp $ */ | 1 | /* $OpenBSD: test_sshkey.c,v 1.13 2017/12/21 00:41:22 djm Exp $ */ |
2 | /* | 2 | /* |
3 | * Regress test for sshkey.h key management API | 3 | * Regress test for sshkey.h key management API |
4 | * | 4 | * |
@@ -121,11 +121,11 @@ signature_test(struct sshkey *k, struct sshkey *bad, const char *sig_alg, | |||
121 | ASSERT_INT_EQ(sshkey_sign(k, &sig, &len, d, l, sig_alg, 0), 0); | 121 | ASSERT_INT_EQ(sshkey_sign(k, &sig, &len, d, l, sig_alg, 0), 0); |
122 | ASSERT_SIZE_T_GT(len, 8); | 122 | ASSERT_SIZE_T_GT(len, 8); |
123 | ASSERT_PTR_NE(sig, NULL); | 123 | ASSERT_PTR_NE(sig, NULL); |
124 | ASSERT_INT_EQ(sshkey_verify(k, sig, len, d, l, 0), 0); | 124 | ASSERT_INT_EQ(sshkey_verify(k, sig, len, d, l, NULL, 0), 0); |
125 | ASSERT_INT_NE(sshkey_verify(bad, sig, len, d, l, 0), 0); | 125 | ASSERT_INT_NE(sshkey_verify(bad, sig, len, d, l, NULL, 0), 0); |
126 | /* Fuzz test is more comprehensive, this is just a smoke test */ | 126 | /* Fuzz test is more comprehensive, this is just a smoke test */ |
127 | sig[len - 5] ^= 0x10; | 127 | sig[len - 5] ^= 0x10; |
128 | ASSERT_INT_NE(sshkey_verify(k, sig, len, d, l, 0), 0); | 128 | ASSERT_INT_NE(sshkey_verify(k, sig, len, d, l, NULL, 0), 0); |
129 | free(sig); | 129 | free(sig); |
130 | } | 130 | } |
131 | 131 | ||