Skip to content

Commit

Permalink
Introduce openssl backend for v1 and v3 API separation (#16918)
Browse files Browse the repository at this point in the history
The main purpose of this is to better handle the API difference and add
an inital work to separate PHP and OpenSSL logic. This is really just
the first step and further changes are coming after that.

Closes GH-16918
  • Loading branch information
bukka authored Feb 6, 2025
1 parent cd30666 commit d662ab5
Show file tree
Hide file tree
Showing 8 changed files with 4,242 additions and 3,983 deletions.
2 changes: 1 addition & 1 deletion ext/openssl/config.w32
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ if (PHP_OPENSSL != "no") {
var ret = SETUP_OPENSSL("openssl", PHP_OPENSSL);

if (ret >= 2) {
EXTENSION("openssl", "openssl.c openssl_pwhash.c xp_ssl.c");
EXTENSION("openssl", "openssl.c openssl_pwhash.c openssl_backend_common.c openssl_backend_v1.c openssl_backend_v3.c xp_ssl.c");
AC_DEFINE("HAVE_OPENSSL_EXT", 1, "Define to 1 if the PHP extension 'openssl' is available.");
if (PHP_OPENSSL_LEGACY_PROVIDER != "no") {
AC_DEFINE("LOAD_OPENSSL_LEGACY_PROVIDER", 1, "Define to 1 to load the OpenSSL legacy algorithm provider in addition to the default provider.");
Expand Down
2 changes: 1 addition & 1 deletion ext/openssl/config0.m4
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ PHP_ARG_WITH([openssl-argon2],

if test "$PHP_OPENSSL" != "no"; then
PHP_NEW_EXTENSION([openssl],
[openssl.c openssl_pwhash.c xp_ssl.c],
[openssl.c openssl_pwhash.c openssl_backend_common.c openssl_backend_v1.c openssl_backend_v3.c xp_ssl.c],
[$ext_shared])
PHP_SUBST([OPENSSL_SHARED_LIBADD])
PHP_SETUP_OPENSSL([OPENSSL_SHARED_LIBADD],
Expand Down
Loading

0 comments on commit d662ab5

Please sign in to comment.