Make WordPress Core

Changeset 52252


Ignore:
Timestamp:
11/26/2021 12:41:54 AM (3 years ago)
Author:
SergeyBiryukov
Message:

External Libraries: Upgrade PHPMailer to version 6.5.3.

The latest release includes official PHP 8.1 support, as well as some small bug fixes, including one for PHP 5.6 cross-version support.

Release notes:

For a full list of changes in this update, see the PHPMailer GitHub:
https://github.com/PHPMailer/PHPMailer/compare/v6.5.1...v6.5.3

Follow-up to [50628], [50799], [51169], [51634], [51635].

Props jrf, Synchro.
Fixes #54514.

Location:
trunk/src/wp-includes/PHPMailer
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/PHPMailer/PHPMailer.php

    r51635 r52252  
    751751     * @var string
    752752     */
    753     const VERSION = '6.5.1';
     753    const VERSION = '6.5.3';
    754754
    755755    /**
     
    14521452                if (defined('INTL_IDNA_VARIANT_UTS46')) {
    14531453                    //Use the current punycode standard (appeared in PHP 7.2)
    1454                     $punycode = idn_to_ascii($domain, $errorcode, \INTL_IDNA_VARIANT_UTS46);
     1454                    $punycode = idn_to_ascii(
     1455                        $domain,
     1456                        \IDNA_DEFAULT | \IDNA_USE_STD3_RULES | \IDNA_CHECK_BIDI |
     1457                            \IDNA_CHECK_CONTEXTJ | \IDNA_NONTRANSITIONAL_TO_ASCII,
     1458                        \INTL_IDNA_VARIANT_UTS46
     1459                    );
    14551460                } elseif (defined('INTL_IDNA_VARIANT_2003')) {
    14561461                    //Fall back to this old, deprecated/removed encoding
     
    17001705        //Qmail docs: http://www.qmail.org/man/man8/qmail-inject.html
    17011706        //Example problem: https://www.drupal.org/node/1057954
    1702         if (empty($this->Sender) && !empty(ini_get('sendmail_from'))) {
     1707
     1708        //PHP 5.6 workaround
     1709        $sendmail_from_value = ini_get('sendmail_from');
     1710        if (empty($this->Sender) && !empty($sendmail_from_value)) {
    17031711            //PHP config has a sender address we can use
    17041712            $this->Sender = ini_get('sendmail_from');
     
    18821890        //Example problem: https://www.drupal.org/node/1057954
    18831891        //CVE-2016-10033, CVE-2016-10045: Don't pass -f if characters will be escaped.
    1884         if (empty($this->Sender) && !empty(ini_get('sendmail_from'))) {
     1892
     1893        //PHP 5.6 workaround
     1894        $sendmail_from_value = ini_get('sendmail_from');
     1895        if (empty($this->Sender) && !empty($sendmail_from_value)) {
    18851896            //PHP config has a sender address we can use
    18861897            $this->Sender = ini_get('sendmail_from');
     
    21992210     *                          Optionally, the language code can be enhanced with a 4-character
    22002211     *                          script annotation and/or a 2-character country annotation.
    2201      * @param string $lang_path Path to the language file directory, with trailing separator (slash).D
     2212     * @param string $lang_path Path to the language file directory, with trailing separator (slash)
    22022213     *                          Do not set this from user input!
    22032214     *
  • trunk/src/wp-includes/PHPMailer/SMTP.php

    r51634 r52252  
    3636     * @var string
    3737     */
    38     const VERSION = '6.5.1';
     38    const VERSION = '6.5.3';
    3939
    4040    /**
     
    393393                $socket_context
    394394            );
    395             restore_error_handler();
    396395        } else {
    397396            //Fall back to fsockopen which should work in more places, but is missing some features
     
    408407                $timeout
    409408            );
    410             restore_error_handler();
    411         }
     409        }
     410        restore_error_handler();
    412411
    413412        //Verify we connected properly
     
    697696     * Send an SMTP DATA command.
    698697     * Issues a data command and sends the msg_data to the server,
    699      * finializing the mail transaction. $msg_data is the message
     698     * finalizing the mail transaction. $msg_data is the message
    700699     * that is to be send with the headers. Each header needs to be
    701700     * on a single line followed by a <CRLF> with the message headers
     
    11711170            $this->setError('No HELO/EHLO was sent');
    11721171
    1173             return;
     1172            return null;
    11741173        }
    11751174
     
    11831182            $this->setError('HELO handshake was used; No information about server extensions available');
    11841183
    1185             return;
     1184            return null;
    11861185        }
    11871186
Note: See TracChangeset for help on using the changeset viewer.