Add some more no-op OPENSSL_INIT_* options for compatibility
Defining the constants for the individual random engines is somewhat
odd, but it looks like OpenSSL will itself silently ignore the option
when built without a particular engine, so silently ignoring it on our
end seems defensible.
Change-Id: I45f955038e5325702d1e32ba7932ada0b4fc1ab6
Reviewed-on: https://boringssl-review.googlesource.com/c/boringssl/+/71387
Commit-Queue: Bob Beck <bbe@google.com>
Reviewed-by: Bob Beck <bbe@google.com>
Auto-Submit: David Benjamin <davidben@google.com>
diff --git a/include/openssl/crypto.h b/include/openssl/crypto.h
index 63dbcb2..384b94c 100644
--- a/include/openssl/crypto.h
+++ b/include/openssl/crypto.h
@@ -145,6 +145,8 @@
// OPENSSL_load_builtin_modules does nothing.
OPENSSL_EXPORT void OPENSSL_load_builtin_modules(void);
+// OPENSSL_INIT_* are options in OpenSSL to configure the library. In BoringSSL,
+// they do nothing.
#define OPENSSL_INIT_NO_LOAD_CRYPTO_STRINGS 0
#define OPENSSL_INIT_LOAD_CRYPTO_STRINGS 0
#define OPENSSL_INIT_ADD_ALL_CIPHERS 0
@@ -154,6 +156,15 @@
#define OPENSSL_INIT_LOAD_CONFIG 0
#define OPENSSL_INIT_NO_LOAD_CONFIG 0
#define OPENSSL_INIT_NO_ATEXIT 0
+#define OPENSSL_INIT_ATFORK 0
+#define OPENSSL_INIT_ENGINE_RDRAND 0
+#define OPENSSL_INIT_ENGINE_DYNAMIC 0
+#define OPENSSL_INIT_ENGINE_OPENSSL 0
+#define OPENSSL_INIT_ENGINE_CRYPTODEV 0
+#define OPENSSL_INIT_ENGINE_CAPI 0
+#define OPENSSL_INIT_ENGINE_PADLOCK 0
+#define OPENSSL_INIT_ENGINE_AFALG 0
+#define OPENSSL_INIT_ENGINE_ALL_BUILTIN 0
// OPENSSL_init_crypto returns one.
OPENSSL_EXPORT int OPENSSL_init_crypto(uint64_t opts,