diff options
author | tb <> | 2018-09-22 15:53:38 +0000 |
---|---|---|
committer | tb <> | 2018-09-22 15:53:38 +0000 |
commit | 600833095896521d52bd3527e8780d6971e8786b (patch) | |
tree | 41b9a179e5969dcc6576a7a6cbbd1b27db6004fd /src | |
parent | ba3259c803eaeebf4240133bda37bb7be518fdd9 (diff) | |
download | openbsd-600833095896521d52bd3527e8780d6971e8786b.tar.gz openbsd-600833095896521d52bd3527e8780d6971e8786b.tar.bz2 openbsd-600833095896521d52bd3527e8780d6971e8786b.zip |
Add a comment on the acceptable RSASSA cases.
Diffstat (limited to 'src')
-rw-r--r-- | src/regress/lib/libcrypto/wycheproof/wycheproof.go | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/regress/lib/libcrypto/wycheproof/wycheproof.go b/src/regress/lib/libcrypto/wycheproof/wycheproof.go index c7b23b21fc..fcd806f29e 100644 --- a/src/regress/lib/libcrypto/wycheproof/wycheproof.go +++ b/src/regress/lib/libcrypto/wycheproof/wycheproof.go | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: wycheproof.go,v 1.65 2018/09/22 14:12:47 tb Exp $ */ | 1 | /* $OpenBSD: wycheproof.go,v 1.66 2018/09/22 15:53:38 tb Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 2018 Joel Sing <jsing@openbsd.org> | 3 | * Copyright (c) 2018 Joel Sing <jsing@openbsd.org> |
4 | * Copyright (c) 2018 Theo Buehler <tb@openbsd.org> | 4 | * Copyright (c) 2018 Theo Buehler <tb@openbsd.org> |
@@ -1385,9 +1385,10 @@ func runRSASSATest(rsa *C.RSA, h hash.Hash, sha *C.EVP_MD, mgfSha *C.EVP_MD, sLe | |||
1385 | 1385 | ||
1386 | ret = C.RSA_verify_PKCS1_PSS_mgf1(rsa, (*C.uchar)(unsafe.Pointer(&msg[0])), sha, mgfSha, (*C.uchar)(unsafe.Pointer(&sigOut[0])), C.int(sLen)) | 1386 | ret = C.RSA_verify_PKCS1_PSS_mgf1(rsa, (*C.uchar)(unsafe.Pointer(&msg[0])), sha, mgfSha, (*C.uchar)(unsafe.Pointer(&sigOut[0])), C.int(sLen)) |
1387 | 1387 | ||
1388 | // XXX: audit acceptable cases... | ||
1389 | success := false | 1388 | success := false |
1390 | if ret == 1 && (wt.Result == "valid" || wt.Result == "acceptable") { | 1389 | if ret == 1 && (wt.Result == "valid" || wt.Result == "acceptable") { |
1390 | // All acceptable cases that pass use SHA-1 and are flagged: | ||
1391 | // "WeakHash" : "The key for this test vector uses a weak hash function." | ||
1391 | if acceptableAudit && wt.Result == "acceptable" { | 1392 | if acceptableAudit && wt.Result == "acceptable" { |
1392 | gatherAcceptableStatistics(wt.TCID, wt.Comment, wt.Flags) | 1393 | gatherAcceptableStatistics(wt.TCID, wt.Comment, wt.Flags) |
1393 | } | 1394 | } |