Merge pull request #4834 from anhu/guard_wc_PKCS7_SetPassword

Fix tests to properly gate on ! NO_PWDBASED && ! NO_SHA
This commit is contained in:
David Garske 2022-02-07 15:12:22 -08:00 committed by GitHub
commit d0246a280d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -31419,7 +31419,7 @@ static int pkcs7enveloped_run_vectors(byte* rsaCert, word32 rsaCertSz,
}
} else if (testVectors[i].password != NULL) {
#ifndef NO_PWDBASED
#if !defined(NO_PWDBASED) && !defined(NO_SHA)
/* PWRI recipient type */
ret = wc_PKCS7_Init(pkcs7, pkcs7->heap, pkcs7->devId);
@ -31454,7 +31454,7 @@ static int pkcs7enveloped_run_vectors(byte* rsaCert, word32 rsaCertSz,
wc_PKCS7_Free(pkcs7);
ERROR_OUT(-12178, out);
}
#endif /* NO_PWDBASED */
#endif /* ! NO_PWDBASED && ! NO_SHA */
} else if (testVectors[i].isOri == 1) {
/* ORI recipient type */
@ -32113,7 +32113,7 @@ static int pkcs7authenveloped_run_vectors(byte* rsaCert, word32 rsaCertSz,
}
} else if (testVectors[i].password != NULL) {
#ifndef NO_PWDBASED
#if !defined(NO_PWDBASED) && !defined(NO_SHA)
/* PWRI recipient type */
ret = wc_PKCS7_Init(pkcs7, pkcs7->heap, pkcs7->devId);
@ -32153,7 +32153,7 @@ static int pkcs7authenveloped_run_vectors(byte* rsaCert, word32 rsaCertSz,
ERROR_OUT(-12219, out);
}
#endif /* NO_PWDBASED */
#endif /* ! NO_PWDBASED && ! NO_SHA */
} else if (testVectors[i].isOri == 1) {
/* ORI recipient type */