1// vim:ft=javascript 2 3ARG_WITH("openssl", "OpenSSL support", "no,shared"); 4 5ARG_WITH("openssl-legacy-provider", "OPENSSL: Load legacy algorithm provider in addition to default provider", "no"); 6 7ARG_WITH("openssl-argon2", "OPENSSL: Enable argon2 password hashing (requires OpenSSL >= 3.2)", "no"); 8 9if (PHP_OPENSSL != "no") { 10 var ret = SETUP_OPENSSL("openssl", PHP_OPENSSL); 11 12 if (ret >= 2) { 13 EXTENSION("openssl", "openssl.c openssl_pwhash.c xp_ssl.c"); 14 AC_DEFINE("HAVE_OPENSSL_EXT", 1, "Define to 1 if the PHP extension 'openssl' is available."); 15 if (PHP_OPENSSL_LEGACY_PROVIDER != "no") { 16 AC_DEFINE("LOAD_OPENSSL_LEGACY_PROVIDER", 1, "Define to 1 to load the OpenSSL legacy algorithm provider in addition to the default provider."); 17 } 18 if (PHP_OPENSSL_ARGON2 != "no") { 19 if (PHP_ZTS != "no") { 20 WARNING("OpenSSL argon2 hashing not supported in ZTS mode for now"); 21 } else if (!CHECK_FUNC_IN_HEADER("openssl/thread.h", "OSSL_set_max_threads", PHP_PHP_BUILD + "\\include")) { 22 WARNING("OpenSSL argon2 hashing requires OpenSSL >= 3.2"); 23 } else { 24 AC_DEFINE("HAVE_OPENSSL_ARGON2", 1, "Define to 1 to enable OpenSSL argon2 password hashing."); 25 } 26 } 27 } 28} 29