diff --git a/mod_php_install.sh b/mod_php_install.sh index 73215a5..ecce569 100755 --- a/mod_php_install.sh +++ b/mod_php_install.sh @@ -6380,9 +6380,16 @@ fi # - # - Security fix: if it fails, abort - never build PHP 5.6 without it. # - +# - NOT for 5.6.40: there 'php-5.6.40-sury-105.patch' (omega8cc/boa, see +# - below) brings its own backport of the CVE-2026-109618/109619 fix - the +# - same fix boa uses for 7.4/8.x (session upload progress disabled, +# - array_init_singleton, zend_mm_safe_error_ex, MIME header filter, +# - max_multipart_body_parts, ...). Both patches change the same code and +# - exclude each other: with this patch applied, sury-105 and xlts-2 fail. +# - _patch_file="php-5.6-enhanced-universal.patch" echononl "\tApply ${_patch_file} (php2shell)" -if [[ "$PHP_MAIN_VERSION" = "5.6" ]]; then +if [[ "$PHP_MAIN_VERSION" = "5.6" ]] && [[ "$VERSION" != "5.6.40" ]]; then if [[ -f "${_srcdir}/${_patch_file}" ]] ; then patch -d $_builddir -p1 < ${_srcdir}/${_patch_file} > $tmp_err_msg 2>&1 if [[ $? -eq 0 ]]; then @@ -6399,9 +6406,20 @@ else echo_skipped fi -# - Security patches for PHP 7.4.33, 8.0.30 and 8.1.34 +# - Security patches for PHP 5.6.40, 7.4.33, 8.0.30 and 8.1.34 # - (source: omega8cc/boa, aegir/patches/php-sec) # - +# - PHP 5.6.40 (boa order = glob order, applied with --fuzz=0 by boa): +# - php-5.6.40-openssl3-pkey-export.patch +# - php-5.6.40-round-places-overflow.patch +# - php-5.6.40-sury-105.patch (backports, Debian/sury; contains +# - the CVE-2026-109618/109619 fix) +# - php-5.6.40-xlts-1.patch +# - php-5.6.40-xlts-2.patch (needs sury-105 and xlts-1) +# - On top of 'PHP-5.6.31-OpenSSL-1.1.0-compatibility-20170801.patch' and +# - the php-5.6-*.patch files above all apply without fuzz (offsets only). +# - They change no generated files (Zend VM, re2c). +# - # - PHP 7.4.33: # - php-7.4.33-cve-2026-109618-109619.patch # - php-7.4.33-sury-31.patch (backports from 8.x, Debian/sury) @@ -6445,6 +6463,14 @@ fi # - Security fixes: if one fails, abort - never build PHP without them. # - case "$VERSION" in + 5.6.40) + _sec_patches=" + php-5.6.40-openssl3-pkey-export.patch + php-5.6.40-round-places-overflow.patch + php-5.6.40-sury-105.patch + php-5.6.40-xlts-1.patch + php-5.6.40-xlts-2.patch" + ;; 7.4.33) _sec_patches=" php-7.4.33-cve-2026-109618-109619.patch