fipsoracle: Combine all test oracles into a single binary.
Change-Id: If53f88135976e5f8f113c0e68bd880e378c98fd9
Reviewed-on: https://boringssl-review.googlesource.com/15885
Reviewed-by: Martin Kreichgauer <martinkr@google.com>
Reviewed-by: Adam Langley <agl@google.com>
diff --git a/fipsoracle/cavp_aes_gcm_test.cc b/fipsoracle/cavp_aes_gcm_test.cc
index a476e62..30e1e7b 100644
--- a/fipsoracle/cavp_aes_gcm_test.cc
+++ b/fipsoracle/cavp_aes_gcm_test.cc
@@ -27,11 +27,15 @@
#include "cavp_test_util.h"
+namespace {
+
struct TestCtx {
const EVP_AEAD *aead;
std::unique_ptr<FileTest> response_sample;
};
+}
+
static const EVP_AEAD *GetAEAD(const std::string &name, const bool enc) {
if (name == "aes-128-gcm") {
return EVP_aead_aes_128_gcm_fips_testonly();
@@ -168,9 +172,7 @@
return 1;
}
-int main(int argc, char **argv) {
- CRYPTO_library_init();
-
+int cavp_aes_gcm_test_main(int argc, char **argv) {
if (argc < 4 || argc > 5) {
return usage(argv[0]);
}