mirror of
https://git.friendi.ca/friendica/friendica-addons.git
synced 2025-07-13 03:48:49 +00:00
update PHPMailer
This commit is contained in:
parent
715f700323
commit
9387db358c
34 changed files with 1151 additions and 296 deletions
20
phpmailer/composer.lock
generated
20
phpmailer/composer.lock
generated
|
@ -8,16 +8,16 @@
|
||||||
"packages": [
|
"packages": [
|
||||||
{
|
{
|
||||||
"name": "phpmailer/phpmailer",
|
"name": "phpmailer/phpmailer",
|
||||||
"version": "v6.9.1",
|
"version": "v6.10.0",
|
||||||
"source": {
|
"source": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/PHPMailer/PHPMailer.git",
|
"url": "https://github.com/PHPMailer/PHPMailer.git",
|
||||||
"reference": "039de174cd9c17a8389754d3b877a2ed22743e18"
|
"reference": "bf74d75a1fde6beaa34a0ddae2ec5fce0f72a144"
|
||||||
},
|
},
|
||||||
"dist": {
|
"dist": {
|
||||||
"type": "zip",
|
"type": "zip",
|
||||||
"url": "https://api.github.com/repos/PHPMailer/PHPMailer/zipball/039de174cd9c17a8389754d3b877a2ed22743e18",
|
"url": "https://api.github.com/repos/PHPMailer/PHPMailer/zipball/bf74d75a1fde6beaa34a0ddae2ec5fce0f72a144",
|
||||||
"reference": "039de174cd9c17a8389754d3b877a2ed22743e18",
|
"reference": "bf74d75a1fde6beaa34a0ddae2ec5fce0f72a144",
|
||||||
"shasum": ""
|
"shasum": ""
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
|
@ -75,24 +75,28 @@
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"description": "PHPMailer is a full-featured email creation and transfer class for PHP",
|
"description": "PHPMailer is a full-featured email creation and transfer class for PHP",
|
||||||
|
"support": {
|
||||||
|
"issues": "https://github.com/PHPMailer/PHPMailer/issues",
|
||||||
|
"source": "https://github.com/PHPMailer/PHPMailer/tree/v6.10.0"
|
||||||
|
},
|
||||||
"funding": [
|
"funding": [
|
||||||
{
|
{
|
||||||
"url": "https://github.com/Synchro",
|
"url": "https://github.com/Synchro",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"time": "2023-11-25T22:23:28+00:00"
|
"time": "2025-04-24T15:19:31+00:00"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"packages-dev": [],
|
"packages-dev": [],
|
||||||
"aliases": [],
|
"aliases": [],
|
||||||
"minimum-stability": "stable",
|
"minimum-stability": "stable",
|
||||||
"stability-flags": [],
|
"stability-flags": {},
|
||||||
"prefer-stable": false,
|
"prefer-stable": false,
|
||||||
"prefer-lowest": false,
|
"prefer-lowest": false,
|
||||||
"platform": {
|
"platform": {
|
||||||
"php": ">=7.0"
|
"php": ">=7.0"
|
||||||
},
|
},
|
||||||
"platform-dev": [],
|
"platform-dev": {},
|
||||||
"plugin-api-version": "1.1.0"
|
"plugin-api-version": "2.6.0"
|
||||||
}
|
}
|
||||||
|
|
18
phpmailer/vendor/autoload.php
vendored
18
phpmailer/vendor/autoload.php
vendored
|
@ -2,6 +2,24 @@
|
||||||
|
|
||||||
// autoload.php @generated by Composer
|
// autoload.php @generated by Composer
|
||||||
|
|
||||||
|
if (PHP_VERSION_ID < 50600) {
|
||||||
|
if (!headers_sent()) {
|
||||||
|
header('HTTP/1.1 500 Internal Server Error');
|
||||||
|
}
|
||||||
|
$err = 'Composer 2.3.0 dropped support for autoloading on PHP <5.6 and you are running '.PHP_VERSION.', please upgrade PHP or use Composer 2.2 LTS via "composer self-update --2.2". Aborting.'.PHP_EOL;
|
||||||
|
if (!ini_get('display_errors')) {
|
||||||
|
if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') {
|
||||||
|
fwrite(STDERR, $err);
|
||||||
|
} elseif (!headers_sent()) {
|
||||||
|
echo $err;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
trigger_error(
|
||||||
|
$err,
|
||||||
|
E_USER_ERROR
|
||||||
|
);
|
||||||
|
}
|
||||||
|
|
||||||
require_once __DIR__ . '/composer/autoload_real.php';
|
require_once __DIR__ . '/composer/autoload_real.php';
|
||||||
|
|
||||||
return ComposerAutoloaderInitPhpMailerAddon::getLoader();
|
return ComposerAutoloaderInitPhpMailerAddon::getLoader();
|
||||||
|
|
202
phpmailer/vendor/composer/ClassLoader.php
vendored
202
phpmailer/vendor/composer/ClassLoader.php
vendored
|
@ -37,26 +37,81 @@ namespace Composer\Autoload;
|
||||||
*
|
*
|
||||||
* @author Fabien Potencier <fabien@symfony.com>
|
* @author Fabien Potencier <fabien@symfony.com>
|
||||||
* @author Jordi Boggiano <j.boggiano@seld.be>
|
* @author Jordi Boggiano <j.boggiano@seld.be>
|
||||||
* @see http://www.php-fig.org/psr/psr-0/
|
* @see https://www.php-fig.org/psr/psr-0/
|
||||||
* @see http://www.php-fig.org/psr/psr-4/
|
* @see https://www.php-fig.org/psr/psr-4/
|
||||||
*/
|
*/
|
||||||
class ClassLoader
|
class ClassLoader
|
||||||
{
|
{
|
||||||
|
/** @var \Closure(string):void */
|
||||||
|
private static $includeFile;
|
||||||
|
|
||||||
|
/** @var string|null */
|
||||||
|
private $vendorDir;
|
||||||
|
|
||||||
// PSR-4
|
// PSR-4
|
||||||
|
/**
|
||||||
|
* @var array<string, array<string, int>>
|
||||||
|
*/
|
||||||
private $prefixLengthsPsr4 = array();
|
private $prefixLengthsPsr4 = array();
|
||||||
|
/**
|
||||||
|
* @var array<string, list<string>>
|
||||||
|
*/
|
||||||
private $prefixDirsPsr4 = array();
|
private $prefixDirsPsr4 = array();
|
||||||
|
/**
|
||||||
|
* @var list<string>
|
||||||
|
*/
|
||||||
private $fallbackDirsPsr4 = array();
|
private $fallbackDirsPsr4 = array();
|
||||||
|
|
||||||
// PSR-0
|
// PSR-0
|
||||||
|
/**
|
||||||
|
* List of PSR-0 prefixes
|
||||||
|
*
|
||||||
|
* Structured as array('F (first letter)' => array('Foo\Bar (full prefix)' => array('path', 'path2')))
|
||||||
|
*
|
||||||
|
* @var array<string, array<string, list<string>>>
|
||||||
|
*/
|
||||||
private $prefixesPsr0 = array();
|
private $prefixesPsr0 = array();
|
||||||
|
/**
|
||||||
|
* @var list<string>
|
||||||
|
*/
|
||||||
private $fallbackDirsPsr0 = array();
|
private $fallbackDirsPsr0 = array();
|
||||||
|
|
||||||
|
/** @var bool */
|
||||||
private $useIncludePath = false;
|
private $useIncludePath = false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @var array<string, string>
|
||||||
|
*/
|
||||||
private $classMap = array();
|
private $classMap = array();
|
||||||
|
|
||||||
|
/** @var bool */
|
||||||
private $classMapAuthoritative = false;
|
private $classMapAuthoritative = false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @var array<string, bool>
|
||||||
|
*/
|
||||||
private $missingClasses = array();
|
private $missingClasses = array();
|
||||||
|
|
||||||
|
/** @var string|null */
|
||||||
private $apcuPrefix;
|
private $apcuPrefix;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @var array<string, self>
|
||||||
|
*/
|
||||||
|
private static $registeredLoaders = array();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param string|null $vendorDir
|
||||||
|
*/
|
||||||
|
public function __construct($vendorDir = null)
|
||||||
|
{
|
||||||
|
$this->vendorDir = $vendorDir;
|
||||||
|
self::initializeIncludeClosure();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return array<string, list<string>>
|
||||||
|
*/
|
||||||
public function getPrefixes()
|
public function getPrefixes()
|
||||||
{
|
{
|
||||||
if (!empty($this->prefixesPsr0)) {
|
if (!empty($this->prefixesPsr0)) {
|
||||||
|
@ -66,28 +121,42 @@ class ClassLoader
|
||||||
return array();
|
return array();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return array<string, list<string>>
|
||||||
|
*/
|
||||||
public function getPrefixesPsr4()
|
public function getPrefixesPsr4()
|
||||||
{
|
{
|
||||||
return $this->prefixDirsPsr4;
|
return $this->prefixDirsPsr4;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return list<string>
|
||||||
|
*/
|
||||||
public function getFallbackDirs()
|
public function getFallbackDirs()
|
||||||
{
|
{
|
||||||
return $this->fallbackDirsPsr0;
|
return $this->fallbackDirsPsr0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return list<string>
|
||||||
|
*/
|
||||||
public function getFallbackDirsPsr4()
|
public function getFallbackDirsPsr4()
|
||||||
{
|
{
|
||||||
return $this->fallbackDirsPsr4;
|
return $this->fallbackDirsPsr4;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return array<string, string> Array of classname => path
|
||||||
|
*/
|
||||||
public function getClassMap()
|
public function getClassMap()
|
||||||
{
|
{
|
||||||
return $this->classMap;
|
return $this->classMap;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param array $classMap Class to filename map
|
* @param array<string, string> $classMap Class to filename map
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function addClassMap(array $classMap)
|
public function addClassMap(array $classMap)
|
||||||
{
|
{
|
||||||
|
@ -102,22 +171,25 @@ class ClassLoader
|
||||||
* Registers a set of PSR-0 directories for a given prefix, either
|
* Registers a set of PSR-0 directories for a given prefix, either
|
||||||
* appending or prepending to the ones previously set for this prefix.
|
* appending or prepending to the ones previously set for this prefix.
|
||||||
*
|
*
|
||||||
* @param string $prefix The prefix
|
* @param string $prefix The prefix
|
||||||
* @param array|string $paths The PSR-0 root directories
|
* @param list<string>|string $paths The PSR-0 root directories
|
||||||
* @param bool $prepend Whether to prepend the directories
|
* @param bool $prepend Whether to prepend the directories
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function add($prefix, $paths, $prepend = false)
|
public function add($prefix, $paths, $prepend = false)
|
||||||
{
|
{
|
||||||
|
$paths = (array) $paths;
|
||||||
if (!$prefix) {
|
if (!$prefix) {
|
||||||
if ($prepend) {
|
if ($prepend) {
|
||||||
$this->fallbackDirsPsr0 = array_merge(
|
$this->fallbackDirsPsr0 = array_merge(
|
||||||
(array) $paths,
|
$paths,
|
||||||
$this->fallbackDirsPsr0
|
$this->fallbackDirsPsr0
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
$this->fallbackDirsPsr0 = array_merge(
|
$this->fallbackDirsPsr0 = array_merge(
|
||||||
$this->fallbackDirsPsr0,
|
$this->fallbackDirsPsr0,
|
||||||
(array) $paths
|
$paths
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -126,19 +198,19 @@ class ClassLoader
|
||||||
|
|
||||||
$first = $prefix[0];
|
$first = $prefix[0];
|
||||||
if (!isset($this->prefixesPsr0[$first][$prefix])) {
|
if (!isset($this->prefixesPsr0[$first][$prefix])) {
|
||||||
$this->prefixesPsr0[$first][$prefix] = (array) $paths;
|
$this->prefixesPsr0[$first][$prefix] = $paths;
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if ($prepend) {
|
if ($prepend) {
|
||||||
$this->prefixesPsr0[$first][$prefix] = array_merge(
|
$this->prefixesPsr0[$first][$prefix] = array_merge(
|
||||||
(array) $paths,
|
$paths,
|
||||||
$this->prefixesPsr0[$first][$prefix]
|
$this->prefixesPsr0[$first][$prefix]
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
$this->prefixesPsr0[$first][$prefix] = array_merge(
|
$this->prefixesPsr0[$first][$prefix] = array_merge(
|
||||||
$this->prefixesPsr0[$first][$prefix],
|
$this->prefixesPsr0[$first][$prefix],
|
||||||
(array) $paths
|
$paths
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -147,25 +219,28 @@ class ClassLoader
|
||||||
* Registers a set of PSR-4 directories for a given namespace, either
|
* Registers a set of PSR-4 directories for a given namespace, either
|
||||||
* appending or prepending to the ones previously set for this namespace.
|
* appending or prepending to the ones previously set for this namespace.
|
||||||
*
|
*
|
||||||
* @param string $prefix The prefix/namespace, with trailing '\\'
|
* @param string $prefix The prefix/namespace, with trailing '\\'
|
||||||
* @param array|string $paths The PSR-4 base directories
|
* @param list<string>|string $paths The PSR-4 base directories
|
||||||
* @param bool $prepend Whether to prepend the directories
|
* @param bool $prepend Whether to prepend the directories
|
||||||
*
|
*
|
||||||
* @throws \InvalidArgumentException
|
* @throws \InvalidArgumentException
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function addPsr4($prefix, $paths, $prepend = false)
|
public function addPsr4($prefix, $paths, $prepend = false)
|
||||||
{
|
{
|
||||||
|
$paths = (array) $paths;
|
||||||
if (!$prefix) {
|
if (!$prefix) {
|
||||||
// Register directories for the root namespace.
|
// Register directories for the root namespace.
|
||||||
if ($prepend) {
|
if ($prepend) {
|
||||||
$this->fallbackDirsPsr4 = array_merge(
|
$this->fallbackDirsPsr4 = array_merge(
|
||||||
(array) $paths,
|
$paths,
|
||||||
$this->fallbackDirsPsr4
|
$this->fallbackDirsPsr4
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
$this->fallbackDirsPsr4 = array_merge(
|
$this->fallbackDirsPsr4 = array_merge(
|
||||||
$this->fallbackDirsPsr4,
|
$this->fallbackDirsPsr4,
|
||||||
(array) $paths
|
$paths
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
} elseif (!isset($this->prefixDirsPsr4[$prefix])) {
|
} elseif (!isset($this->prefixDirsPsr4[$prefix])) {
|
||||||
|
@ -175,18 +250,18 @@ class ClassLoader
|
||||||
throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator.");
|
throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator.");
|
||||||
}
|
}
|
||||||
$this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length;
|
$this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length;
|
||||||
$this->prefixDirsPsr4[$prefix] = (array) $paths;
|
$this->prefixDirsPsr4[$prefix] = $paths;
|
||||||
} elseif ($prepend) {
|
} elseif ($prepend) {
|
||||||
// Prepend directories for an already registered namespace.
|
// Prepend directories for an already registered namespace.
|
||||||
$this->prefixDirsPsr4[$prefix] = array_merge(
|
$this->prefixDirsPsr4[$prefix] = array_merge(
|
||||||
(array) $paths,
|
$paths,
|
||||||
$this->prefixDirsPsr4[$prefix]
|
$this->prefixDirsPsr4[$prefix]
|
||||||
);
|
);
|
||||||
} else {
|
} else {
|
||||||
// Append directories for an already registered namespace.
|
// Append directories for an already registered namespace.
|
||||||
$this->prefixDirsPsr4[$prefix] = array_merge(
|
$this->prefixDirsPsr4[$prefix] = array_merge(
|
||||||
$this->prefixDirsPsr4[$prefix],
|
$this->prefixDirsPsr4[$prefix],
|
||||||
(array) $paths
|
$paths
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -195,8 +270,10 @@ class ClassLoader
|
||||||
* Registers a set of PSR-0 directories for a given prefix,
|
* Registers a set of PSR-0 directories for a given prefix,
|
||||||
* replacing any others previously set for this prefix.
|
* replacing any others previously set for this prefix.
|
||||||
*
|
*
|
||||||
* @param string $prefix The prefix
|
* @param string $prefix The prefix
|
||||||
* @param array|string $paths The PSR-0 base directories
|
* @param list<string>|string $paths The PSR-0 base directories
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function set($prefix, $paths)
|
public function set($prefix, $paths)
|
||||||
{
|
{
|
||||||
|
@ -211,10 +288,12 @@ class ClassLoader
|
||||||
* Registers a set of PSR-4 directories for a given namespace,
|
* Registers a set of PSR-4 directories for a given namespace,
|
||||||
* replacing any others previously set for this namespace.
|
* replacing any others previously set for this namespace.
|
||||||
*
|
*
|
||||||
* @param string $prefix The prefix/namespace, with trailing '\\'
|
* @param string $prefix The prefix/namespace, with trailing '\\'
|
||||||
* @param array|string $paths The PSR-4 base directories
|
* @param list<string>|string $paths The PSR-4 base directories
|
||||||
*
|
*
|
||||||
* @throws \InvalidArgumentException
|
* @throws \InvalidArgumentException
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function setPsr4($prefix, $paths)
|
public function setPsr4($prefix, $paths)
|
||||||
{
|
{
|
||||||
|
@ -234,6 +313,8 @@ class ClassLoader
|
||||||
* Turns on searching the include path for class files.
|
* Turns on searching the include path for class files.
|
||||||
*
|
*
|
||||||
* @param bool $useIncludePath
|
* @param bool $useIncludePath
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function setUseIncludePath($useIncludePath)
|
public function setUseIncludePath($useIncludePath)
|
||||||
{
|
{
|
||||||
|
@ -256,6 +337,8 @@ class ClassLoader
|
||||||
* that have not been registered with the class map.
|
* that have not been registered with the class map.
|
||||||
*
|
*
|
||||||
* @param bool $classMapAuthoritative
|
* @param bool $classMapAuthoritative
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function setClassMapAuthoritative($classMapAuthoritative)
|
public function setClassMapAuthoritative($classMapAuthoritative)
|
||||||
{
|
{
|
||||||
|
@ -276,6 +359,8 @@ class ClassLoader
|
||||||
* APCu prefix to use to cache found/not-found classes, if the extension is enabled.
|
* APCu prefix to use to cache found/not-found classes, if the extension is enabled.
|
||||||
*
|
*
|
||||||
* @param string|null $apcuPrefix
|
* @param string|null $apcuPrefix
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function setApcuPrefix($apcuPrefix)
|
public function setApcuPrefix($apcuPrefix)
|
||||||
{
|
{
|
||||||
|
@ -296,33 +381,55 @@ class ClassLoader
|
||||||
* Registers this instance as an autoloader.
|
* Registers this instance as an autoloader.
|
||||||
*
|
*
|
||||||
* @param bool $prepend Whether to prepend the autoloader or not
|
* @param bool $prepend Whether to prepend the autoloader or not
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function register($prepend = false)
|
public function register($prepend = false)
|
||||||
{
|
{
|
||||||
spl_autoload_register(array($this, 'loadClass'), true, $prepend);
|
spl_autoload_register(array($this, 'loadClass'), true, $prepend);
|
||||||
|
|
||||||
|
if (null === $this->vendorDir) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($prepend) {
|
||||||
|
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
|
||||||
|
} else {
|
||||||
|
unset(self::$registeredLoaders[$this->vendorDir]);
|
||||||
|
self::$registeredLoaders[$this->vendorDir] = $this;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Unregisters this instance as an autoloader.
|
* Unregisters this instance as an autoloader.
|
||||||
|
*
|
||||||
|
* @return void
|
||||||
*/
|
*/
|
||||||
public function unregister()
|
public function unregister()
|
||||||
{
|
{
|
||||||
spl_autoload_unregister(array($this, 'loadClass'));
|
spl_autoload_unregister(array($this, 'loadClass'));
|
||||||
|
|
||||||
|
if (null !== $this->vendorDir) {
|
||||||
|
unset(self::$registeredLoaders[$this->vendorDir]);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Loads the given class or interface.
|
* Loads the given class or interface.
|
||||||
*
|
*
|
||||||
* @param string $class The name of the class
|
* @param string $class The name of the class
|
||||||
* @return bool|null True if loaded, null otherwise
|
* @return true|null True if loaded, null otherwise
|
||||||
*/
|
*/
|
||||||
public function loadClass($class)
|
public function loadClass($class)
|
||||||
{
|
{
|
||||||
if ($file = $this->findFile($class)) {
|
if ($file = $this->findFile($class)) {
|
||||||
includeFile($file);
|
$includeFile = self::$includeFile;
|
||||||
|
$includeFile($file);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -367,6 +474,21 @@ class ClassLoader
|
||||||
return $file;
|
return $file;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns the currently registered loaders keyed by their corresponding vendor directories.
|
||||||
|
*
|
||||||
|
* @return array<string, self>
|
||||||
|
*/
|
||||||
|
public static function getRegisteredLoaders()
|
||||||
|
{
|
||||||
|
return self::$registeredLoaders;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param string $class
|
||||||
|
* @param string $ext
|
||||||
|
* @return string|false
|
||||||
|
*/
|
||||||
private function findFileWithExtension($class, $ext)
|
private function findFileWithExtension($class, $ext)
|
||||||
{
|
{
|
||||||
// PSR-4 lookup
|
// PSR-4 lookup
|
||||||
|
@ -432,14 +554,26 @@ class ClassLoader
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Scope isolated include.
|
* @return void
|
||||||
*
|
*/
|
||||||
* Prevents access to $this/self from included files.
|
private static function initializeIncludeClosure()
|
||||||
*/
|
{
|
||||||
function includeFile($file)
|
if (self::$includeFile !== null) {
|
||||||
{
|
return;
|
||||||
include $file;
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Scope isolated include.
|
||||||
|
*
|
||||||
|
* Prevents access to $this/self from included files.
|
||||||
|
*
|
||||||
|
* @param string $file
|
||||||
|
* @return void
|
||||||
|
*/
|
||||||
|
self::$includeFile = \Closure::bind(static function($file) {
|
||||||
|
include $file;
|
||||||
|
}, null, null);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
359
phpmailer/vendor/composer/InstalledVersions.php
vendored
Normal file
359
phpmailer/vendor/composer/InstalledVersions.php
vendored
Normal file
|
@ -0,0 +1,359 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
/*
|
||||||
|
* This file is part of Composer.
|
||||||
|
*
|
||||||
|
* (c) Nils Adermann <naderman@naderman.de>
|
||||||
|
* Jordi Boggiano <j.boggiano@seld.be>
|
||||||
|
*
|
||||||
|
* For the full copyright and license information, please view the LICENSE
|
||||||
|
* file that was distributed with this source code.
|
||||||
|
*/
|
||||||
|
|
||||||
|
namespace Composer;
|
||||||
|
|
||||||
|
use Composer\Autoload\ClassLoader;
|
||||||
|
use Composer\Semver\VersionParser;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* This class is copied in every Composer installed project and available to all
|
||||||
|
*
|
||||||
|
* See also https://getcomposer.org/doc/07-runtime.md#installed-versions
|
||||||
|
*
|
||||||
|
* To require its presence, you can require `composer-runtime-api ^2.0`
|
||||||
|
*
|
||||||
|
* @final
|
||||||
|
*/
|
||||||
|
class InstalledVersions
|
||||||
|
{
|
||||||
|
/**
|
||||||
|
* @var mixed[]|null
|
||||||
|
* @psalm-var array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}|array{}|null
|
||||||
|
*/
|
||||||
|
private static $installed;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @var bool|null
|
||||||
|
*/
|
||||||
|
private static $canGetVendors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @var array[]
|
||||||
|
* @psalm-var array<string, array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}>
|
||||||
|
*/
|
||||||
|
private static $installedByVendor = array();
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns a list of all package names which are present, either by being installed, replaced or provided
|
||||||
|
*
|
||||||
|
* @return string[]
|
||||||
|
* @psalm-return list<string>
|
||||||
|
*/
|
||||||
|
public static function getInstalledPackages()
|
||||||
|
{
|
||||||
|
$packages = array();
|
||||||
|
foreach (self::getInstalled() as $installed) {
|
||||||
|
$packages[] = array_keys($installed['versions']);
|
||||||
|
}
|
||||||
|
|
||||||
|
if (1 === \count($packages)) {
|
||||||
|
return $packages[0];
|
||||||
|
}
|
||||||
|
|
||||||
|
return array_keys(array_flip(\call_user_func_array('array_merge', $packages)));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns a list of all package names with a specific type e.g. 'library'
|
||||||
|
*
|
||||||
|
* @param string $type
|
||||||
|
* @return string[]
|
||||||
|
* @psalm-return list<string>
|
||||||
|
*/
|
||||||
|
public static function getInstalledPackagesByType($type)
|
||||||
|
{
|
||||||
|
$packagesByType = array();
|
||||||
|
|
||||||
|
foreach (self::getInstalled() as $installed) {
|
||||||
|
foreach ($installed['versions'] as $name => $package) {
|
||||||
|
if (isset($package['type']) && $package['type'] === $type) {
|
||||||
|
$packagesByType[] = $name;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return $packagesByType;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Checks whether the given package is installed
|
||||||
|
*
|
||||||
|
* This also returns true if the package name is provided or replaced by another package
|
||||||
|
*
|
||||||
|
* @param string $packageName
|
||||||
|
* @param bool $includeDevRequirements
|
||||||
|
* @return bool
|
||||||
|
*/
|
||||||
|
public static function isInstalled($packageName, $includeDevRequirements = true)
|
||||||
|
{
|
||||||
|
foreach (self::getInstalled() as $installed) {
|
||||||
|
if (isset($installed['versions'][$packageName])) {
|
||||||
|
return $includeDevRequirements || !isset($installed['versions'][$packageName]['dev_requirement']) || $installed['versions'][$packageName]['dev_requirement'] === false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Checks whether the given package satisfies a version constraint
|
||||||
|
*
|
||||||
|
* e.g. If you want to know whether version 2.3+ of package foo/bar is installed, you would call:
|
||||||
|
*
|
||||||
|
* Composer\InstalledVersions::satisfies(new VersionParser, 'foo/bar', '^2.3')
|
||||||
|
*
|
||||||
|
* @param VersionParser $parser Install composer/semver to have access to this class and functionality
|
||||||
|
* @param string $packageName
|
||||||
|
* @param string|null $constraint A version constraint to check for, if you pass one you have to make sure composer/semver is required by your package
|
||||||
|
* @return bool
|
||||||
|
*/
|
||||||
|
public static function satisfies(VersionParser $parser, $packageName, $constraint)
|
||||||
|
{
|
||||||
|
$constraint = $parser->parseConstraints((string) $constraint);
|
||||||
|
$provided = $parser->parseConstraints(self::getVersionRanges($packageName));
|
||||||
|
|
||||||
|
return $provided->matches($constraint);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns a version constraint representing all the range(s) which are installed for a given package
|
||||||
|
*
|
||||||
|
* It is easier to use this via isInstalled() with the $constraint argument if you need to check
|
||||||
|
* whether a given version of a package is installed, and not just whether it exists
|
||||||
|
*
|
||||||
|
* @param string $packageName
|
||||||
|
* @return string Version constraint usable with composer/semver
|
||||||
|
*/
|
||||||
|
public static function getVersionRanges($packageName)
|
||||||
|
{
|
||||||
|
foreach (self::getInstalled() as $installed) {
|
||||||
|
if (!isset($installed['versions'][$packageName])) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
$ranges = array();
|
||||||
|
if (isset($installed['versions'][$packageName]['pretty_version'])) {
|
||||||
|
$ranges[] = $installed['versions'][$packageName]['pretty_version'];
|
||||||
|
}
|
||||||
|
if (array_key_exists('aliases', $installed['versions'][$packageName])) {
|
||||||
|
$ranges = array_merge($ranges, $installed['versions'][$packageName]['aliases']);
|
||||||
|
}
|
||||||
|
if (array_key_exists('replaced', $installed['versions'][$packageName])) {
|
||||||
|
$ranges = array_merge($ranges, $installed['versions'][$packageName]['replaced']);
|
||||||
|
}
|
||||||
|
if (array_key_exists('provided', $installed['versions'][$packageName])) {
|
||||||
|
$ranges = array_merge($ranges, $installed['versions'][$packageName]['provided']);
|
||||||
|
}
|
||||||
|
|
||||||
|
return implode(' || ', $ranges);
|
||||||
|
}
|
||||||
|
|
||||||
|
throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param string $packageName
|
||||||
|
* @return string|null If the package is being replaced or provided but is not really installed, null will be returned as version, use satisfies or getVersionRanges if you need to know if a given version is present
|
||||||
|
*/
|
||||||
|
public static function getVersion($packageName)
|
||||||
|
{
|
||||||
|
foreach (self::getInstalled() as $installed) {
|
||||||
|
if (!isset($installed['versions'][$packageName])) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!isset($installed['versions'][$packageName]['version'])) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
return $installed['versions'][$packageName]['version'];
|
||||||
|
}
|
||||||
|
|
||||||
|
throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param string $packageName
|
||||||
|
* @return string|null If the package is being replaced or provided but is not really installed, null will be returned as version, use satisfies or getVersionRanges if you need to know if a given version is present
|
||||||
|
*/
|
||||||
|
public static function getPrettyVersion($packageName)
|
||||||
|
{
|
||||||
|
foreach (self::getInstalled() as $installed) {
|
||||||
|
if (!isset($installed['versions'][$packageName])) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!isset($installed['versions'][$packageName]['pretty_version'])) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
return $installed['versions'][$packageName]['pretty_version'];
|
||||||
|
}
|
||||||
|
|
||||||
|
throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param string $packageName
|
||||||
|
* @return string|null If the package is being replaced or provided but is not really installed, null will be returned as reference
|
||||||
|
*/
|
||||||
|
public static function getReference($packageName)
|
||||||
|
{
|
||||||
|
foreach (self::getInstalled() as $installed) {
|
||||||
|
if (!isset($installed['versions'][$packageName])) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!isset($installed['versions'][$packageName]['reference'])) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
return $installed['versions'][$packageName]['reference'];
|
||||||
|
}
|
||||||
|
|
||||||
|
throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @param string $packageName
|
||||||
|
* @return string|null If the package is being replaced or provided but is not really installed, null will be returned as install path. Packages of type metapackages also have a null install path.
|
||||||
|
*/
|
||||||
|
public static function getInstallPath($packageName)
|
||||||
|
{
|
||||||
|
foreach (self::getInstalled() as $installed) {
|
||||||
|
if (!isset($installed['versions'][$packageName])) {
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
|
return isset($installed['versions'][$packageName]['install_path']) ? $installed['versions'][$packageName]['install_path'] : null;
|
||||||
|
}
|
||||||
|
|
||||||
|
throw new \OutOfBoundsException('Package "' . $packageName . '" is not installed');
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return array
|
||||||
|
* @psalm-return array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}
|
||||||
|
*/
|
||||||
|
public static function getRootPackage()
|
||||||
|
{
|
||||||
|
$installed = self::getInstalled();
|
||||||
|
|
||||||
|
return $installed[0]['root'];
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns the raw installed.php data for custom implementations
|
||||||
|
*
|
||||||
|
* @deprecated Use getAllRawData() instead which returns all datasets for all autoloaders present in the process. getRawData only returns the first dataset loaded, which may not be what you expect.
|
||||||
|
* @return array[]
|
||||||
|
* @psalm-return array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}
|
||||||
|
*/
|
||||||
|
public static function getRawData()
|
||||||
|
{
|
||||||
|
@trigger_error('getRawData only returns the first dataset loaded, which may not be what you expect. Use getAllRawData() instead which returns all datasets for all autoloaders present in the process.', E_USER_DEPRECATED);
|
||||||
|
|
||||||
|
if (null === self::$installed) {
|
||||||
|
// only require the installed.php file if this file is loaded from its dumped location,
|
||||||
|
// and not from its source location in the composer/composer package, see https://github.com/composer/composer/issues/9937
|
||||||
|
if (substr(__DIR__, -8, 1) !== 'C') {
|
||||||
|
self::$installed = include __DIR__ . '/installed.php';
|
||||||
|
} else {
|
||||||
|
self::$installed = array();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
return self::$installed;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns the raw data of all installed.php which are currently loaded for custom implementations
|
||||||
|
*
|
||||||
|
* @return array[]
|
||||||
|
* @psalm-return list<array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}>
|
||||||
|
*/
|
||||||
|
public static function getAllRawData()
|
||||||
|
{
|
||||||
|
return self::getInstalled();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Lets you reload the static array from another file
|
||||||
|
*
|
||||||
|
* This is only useful for complex integrations in which a project needs to use
|
||||||
|
* this class but then also needs to execute another project's autoloader in process,
|
||||||
|
* and wants to ensure both projects have access to their version of installed.php.
|
||||||
|
*
|
||||||
|
* A typical case would be PHPUnit, where it would need to make sure it reads all
|
||||||
|
* the data it needs from this class, then call reload() with
|
||||||
|
* `require $CWD/vendor/composer/installed.php` (or similar) as input to make sure
|
||||||
|
* the project in which it runs can then also use this class safely, without
|
||||||
|
* interference between PHPUnit's dependencies and the project's dependencies.
|
||||||
|
*
|
||||||
|
* @param array[] $data A vendor/composer/installed.php data set
|
||||||
|
* @return void
|
||||||
|
*
|
||||||
|
* @psalm-param array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>} $data
|
||||||
|
*/
|
||||||
|
public static function reload($data)
|
||||||
|
{
|
||||||
|
self::$installed = $data;
|
||||||
|
self::$installedByVendor = array();
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @return array[]
|
||||||
|
* @psalm-return list<array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>}>
|
||||||
|
*/
|
||||||
|
private static function getInstalled()
|
||||||
|
{
|
||||||
|
if (null === self::$canGetVendors) {
|
||||||
|
self::$canGetVendors = method_exists('Composer\Autoload\ClassLoader', 'getRegisteredLoaders');
|
||||||
|
}
|
||||||
|
|
||||||
|
$installed = array();
|
||||||
|
|
||||||
|
if (self::$canGetVendors) {
|
||||||
|
foreach (ClassLoader::getRegisteredLoaders() as $vendorDir => $loader) {
|
||||||
|
if (isset(self::$installedByVendor[$vendorDir])) {
|
||||||
|
$installed[] = self::$installedByVendor[$vendorDir];
|
||||||
|
} elseif (is_file($vendorDir.'/composer/installed.php')) {
|
||||||
|
/** @var array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>} $required */
|
||||||
|
$required = require $vendorDir.'/composer/installed.php';
|
||||||
|
$installed[] = self::$installedByVendor[$vendorDir] = $required;
|
||||||
|
if (null === self::$installed && strtr($vendorDir.'/composer', '\\', '/') === strtr(__DIR__, '\\', '/')) {
|
||||||
|
self::$installed = $installed[count($installed) - 1];
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (null === self::$installed) {
|
||||||
|
// only require the installed.php file if this file is loaded from its dumped location,
|
||||||
|
// and not from its source location in the composer/composer package, see https://github.com/composer/composer/issues/9937
|
||||||
|
if (substr(__DIR__, -8, 1) !== 'C') {
|
||||||
|
/** @var array{root: array{name: string, pretty_version: string, version: string, reference: string|null, type: string, install_path: string, aliases: string[], dev: bool}, versions: array<string, array{pretty_version?: string, version?: string, reference?: string|null, type?: string, install_path?: string, aliases?: string[], dev_requirement: bool, replaced?: string[], provided?: string[]}>} $required */
|
||||||
|
$required = require __DIR__ . '/installed.php';
|
||||||
|
self::$installed = $required;
|
||||||
|
} else {
|
||||||
|
self::$installed = array();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (self::$installed !== array()) {
|
||||||
|
$installed[] = self::$installed;
|
||||||
|
}
|
||||||
|
|
||||||
|
return $installed;
|
||||||
|
}
|
||||||
|
}
|
|
@ -2,10 +2,11 @@
|
||||||
|
|
||||||
// autoload_classmap.php @generated by Composer
|
// autoload_classmap.php @generated by Composer
|
||||||
|
|
||||||
$vendorDir = dirname(dirname(__FILE__));
|
$vendorDir = dirname(__DIR__);
|
||||||
$baseDir = dirname($vendorDir);
|
$baseDir = dirname($vendorDir);
|
||||||
|
|
||||||
return array(
|
return array(
|
||||||
|
'Composer\\InstalledVersions' => $vendorDir . '/composer/InstalledVersions.php',
|
||||||
'PHPMailer\\PHPMailer\\DSNConfigurator' => $vendorDir . '/phpmailer/phpmailer/src/DSNConfigurator.php',
|
'PHPMailer\\PHPMailer\\DSNConfigurator' => $vendorDir . '/phpmailer/phpmailer/src/DSNConfigurator.php',
|
||||||
'PHPMailer\\PHPMailer\\Exception' => $vendorDir . '/phpmailer/phpmailer/src/Exception.php',
|
'PHPMailer\\PHPMailer\\Exception' => $vendorDir . '/phpmailer/phpmailer/src/Exception.php',
|
||||||
'PHPMailer\\PHPMailer\\OAuth' => $vendorDir . '/phpmailer/phpmailer/src/OAuth.php',
|
'PHPMailer\\PHPMailer\\OAuth' => $vendorDir . '/phpmailer/phpmailer/src/OAuth.php',
|
||||||
|
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
// autoload_namespaces.php @generated by Composer
|
// autoload_namespaces.php @generated by Composer
|
||||||
|
|
||||||
$vendorDir = dirname(dirname(__FILE__));
|
$vendorDir = dirname(__DIR__);
|
||||||
$baseDir = dirname($vendorDir);
|
$baseDir = dirname($vendorDir);
|
||||||
|
|
||||||
return array(
|
return array(
|
||||||
|
|
2
phpmailer/vendor/composer/autoload_psr4.php
vendored
2
phpmailer/vendor/composer/autoload_psr4.php
vendored
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
// autoload_psr4.php @generated by Composer
|
// autoload_psr4.php @generated by Composer
|
||||||
|
|
||||||
$vendorDir = dirname(dirname(__FILE__));
|
$vendorDir = dirname(__DIR__);
|
||||||
$baseDir = dirname($vendorDir);
|
$baseDir = dirname($vendorDir);
|
||||||
|
|
||||||
return array(
|
return array(
|
||||||
|
|
27
phpmailer/vendor/composer/autoload_real.php
vendored
27
phpmailer/vendor/composer/autoload_real.php
vendored
|
@ -22,31 +22,14 @@ class ComposerAutoloaderInitPhpMailerAddon
|
||||||
return self::$loader;
|
return self::$loader;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
require __DIR__ . '/platform_check.php';
|
||||||
|
|
||||||
spl_autoload_register(array('ComposerAutoloaderInitPhpMailerAddon', 'loadClassLoader'), true, true);
|
spl_autoload_register(array('ComposerAutoloaderInitPhpMailerAddon', 'loadClassLoader'), true, true);
|
||||||
self::$loader = $loader = new \Composer\Autoload\ClassLoader();
|
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
|
||||||
spl_autoload_unregister(array('ComposerAutoloaderInitPhpMailerAddon', 'loadClassLoader'));
|
spl_autoload_unregister(array('ComposerAutoloaderInitPhpMailerAddon', 'loadClassLoader'));
|
||||||
|
|
||||||
$useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded());
|
require __DIR__ . '/autoload_static.php';
|
||||||
if ($useStaticLoader) {
|
call_user_func(\Composer\Autoload\ComposerStaticInitPhpMailerAddon::getInitializer($loader));
|
||||||
require_once __DIR__ . '/autoload_static.php';
|
|
||||||
|
|
||||||
call_user_func(\Composer\Autoload\ComposerStaticInitPhpMailerAddon::getInitializer($loader));
|
|
||||||
} else {
|
|
||||||
$map = require __DIR__ . '/autoload_namespaces.php';
|
|
||||||
foreach ($map as $namespace => $path) {
|
|
||||||
$loader->set($namespace, $path);
|
|
||||||
}
|
|
||||||
|
|
||||||
$map = require __DIR__ . '/autoload_psr4.php';
|
|
||||||
foreach ($map as $namespace => $path) {
|
|
||||||
$loader->setPsr4($namespace, $path);
|
|
||||||
}
|
|
||||||
|
|
||||||
$classMap = require __DIR__ . '/autoload_classmap.php';
|
|
||||||
if ($classMap) {
|
|
||||||
$loader->addClassMap($classMap);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
$loader->register(true);
|
$loader->register(true);
|
||||||
|
|
||||||
|
|
|
@ -21,6 +21,7 @@ class ComposerStaticInitPhpMailerAddon
|
||||||
);
|
);
|
||||||
|
|
||||||
public static $classMap = array (
|
public static $classMap = array (
|
||||||
|
'Composer\\InstalledVersions' => __DIR__ . '/..' . '/composer/InstalledVersions.php',
|
||||||
'PHPMailer\\PHPMailer\\DSNConfigurator' => __DIR__ . '/..' . '/phpmailer/phpmailer/src/DSNConfigurator.php',
|
'PHPMailer\\PHPMailer\\DSNConfigurator' => __DIR__ . '/..' . '/phpmailer/phpmailer/src/DSNConfigurator.php',
|
||||||
'PHPMailer\\PHPMailer\\Exception' => __DIR__ . '/..' . '/phpmailer/phpmailer/src/Exception.php',
|
'PHPMailer\\PHPMailer\\Exception' => __DIR__ . '/..' . '/phpmailer/phpmailer/src/Exception.php',
|
||||||
'PHPMailer\\PHPMailer\\OAuth' => __DIR__ . '/..' . '/phpmailer/phpmailer/src/OAuth.php',
|
'PHPMailer\\PHPMailer\\OAuth' => __DIR__ . '/..' . '/phpmailer/phpmailer/src/OAuth.php',
|
||||||
|
|
169
phpmailer/vendor/composer/installed.json
vendored
169
phpmailer/vendor/composer/installed.json
vendored
|
@ -1,81 +1,90 @@
|
||||||
[
|
{
|
||||||
{
|
"packages": [
|
||||||
"name": "phpmailer/phpmailer",
|
{
|
||||||
"version": "v6.9.1",
|
"name": "phpmailer/phpmailer",
|
||||||
"version_normalized": "6.9.1.0",
|
"version": "v6.10.0",
|
||||||
"source": {
|
"version_normalized": "6.10.0.0",
|
||||||
"type": "git",
|
"source": {
|
||||||
"url": "https://github.com/PHPMailer/PHPMailer.git",
|
"type": "git",
|
||||||
"reference": "039de174cd9c17a8389754d3b877a2ed22743e18"
|
"url": "https://github.com/PHPMailer/PHPMailer.git",
|
||||||
},
|
"reference": "bf74d75a1fde6beaa34a0ddae2ec5fce0f72a144"
|
||||||
"dist": {
|
},
|
||||||
"type": "zip",
|
"dist": {
|
||||||
"url": "https://api.github.com/repos/PHPMailer/PHPMailer/zipball/039de174cd9c17a8389754d3b877a2ed22743e18",
|
"type": "zip",
|
||||||
"reference": "039de174cd9c17a8389754d3b877a2ed22743e18",
|
"url": "https://api.github.com/repos/PHPMailer/PHPMailer/zipball/bf74d75a1fde6beaa34a0ddae2ec5fce0f72a144",
|
||||||
"shasum": ""
|
"reference": "bf74d75a1fde6beaa34a0ddae2ec5fce0f72a144",
|
||||||
},
|
"shasum": ""
|
||||||
"require": {
|
},
|
||||||
"ext-ctype": "*",
|
"require": {
|
||||||
"ext-filter": "*",
|
"ext-ctype": "*",
|
||||||
"ext-hash": "*",
|
"ext-filter": "*",
|
||||||
"php": ">=5.5.0"
|
"ext-hash": "*",
|
||||||
},
|
"php": ">=5.5.0"
|
||||||
"require-dev": {
|
},
|
||||||
"dealerdirect/phpcodesniffer-composer-installer": "^1.0",
|
"require-dev": {
|
||||||
"doctrine/annotations": "^1.2.6 || ^1.13.3",
|
"dealerdirect/phpcodesniffer-composer-installer": "^1.0",
|
||||||
"php-parallel-lint/php-console-highlighter": "^1.0.0",
|
"doctrine/annotations": "^1.2.6 || ^1.13.3",
|
||||||
"php-parallel-lint/php-parallel-lint": "^1.3.2",
|
"php-parallel-lint/php-console-highlighter": "^1.0.0",
|
||||||
"phpcompatibility/php-compatibility": "^9.3.5",
|
"php-parallel-lint/php-parallel-lint": "^1.3.2",
|
||||||
"roave/security-advisories": "dev-latest",
|
"phpcompatibility/php-compatibility": "^9.3.5",
|
||||||
"squizlabs/php_codesniffer": "^3.7.2",
|
"roave/security-advisories": "dev-latest",
|
||||||
"yoast/phpunit-polyfills": "^1.0.4"
|
"squizlabs/php_codesniffer": "^3.7.2",
|
||||||
},
|
"yoast/phpunit-polyfills": "^1.0.4"
|
||||||
"suggest": {
|
},
|
||||||
"decomplexity/SendOauth2": "Adapter for using XOAUTH2 authentication",
|
"suggest": {
|
||||||
"ext-mbstring": "Needed to send email in multibyte encoding charset or decode encoded addresses",
|
"decomplexity/SendOauth2": "Adapter for using XOAUTH2 authentication",
|
||||||
"ext-openssl": "Needed for secure SMTP sending and DKIM signing",
|
"ext-mbstring": "Needed to send email in multibyte encoding charset or decode encoded addresses",
|
||||||
"greew/oauth2-azure-provider": "Needed for Microsoft Azure XOAUTH2 authentication",
|
"ext-openssl": "Needed for secure SMTP sending and DKIM signing",
|
||||||
"hayageek/oauth2-yahoo": "Needed for Yahoo XOAUTH2 authentication",
|
"greew/oauth2-azure-provider": "Needed for Microsoft Azure XOAUTH2 authentication",
|
||||||
"league/oauth2-google": "Needed for Google XOAUTH2 authentication",
|
"hayageek/oauth2-yahoo": "Needed for Yahoo XOAUTH2 authentication",
|
||||||
"psr/log": "For optional PSR-3 debug logging",
|
"league/oauth2-google": "Needed for Google XOAUTH2 authentication",
|
||||||
"symfony/polyfill-mbstring": "To support UTF-8 if the Mbstring PHP extension is not enabled (^1.2)",
|
"psr/log": "For optional PSR-3 debug logging",
|
||||||
"thenetworg/oauth2-azure": "Needed for Microsoft XOAUTH2 authentication"
|
"symfony/polyfill-mbstring": "To support UTF-8 if the Mbstring PHP extension is not enabled (^1.2)",
|
||||||
},
|
"thenetworg/oauth2-azure": "Needed for Microsoft XOAUTH2 authentication"
|
||||||
"time": "2023-11-25T22:23:28+00:00",
|
},
|
||||||
"type": "library",
|
"time": "2025-04-24T15:19:31+00:00",
|
||||||
"installation-source": "dist",
|
"type": "library",
|
||||||
"autoload": {
|
"installation-source": "dist",
|
||||||
"psr-4": {
|
"autoload": {
|
||||||
"PHPMailer\\PHPMailer\\": "src/"
|
"psr-4": {
|
||||||
}
|
"PHPMailer\\PHPMailer\\": "src/"
|
||||||
},
|
}
|
||||||
"notification-url": "https://packagist.org/downloads/",
|
},
|
||||||
"license": [
|
"notification-url": "https://packagist.org/downloads/",
|
||||||
"LGPL-2.1-only"
|
"license": [
|
||||||
|
"LGPL-2.1-only"
|
||||||
|
],
|
||||||
|
"authors": [
|
||||||
|
{
|
||||||
|
"name": "Marcus Bointon",
|
||||||
|
"email": "phpmailer@synchromedia.co.uk"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Jim Jagielski",
|
||||||
|
"email": "jimjag@gmail.com"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Andy Prevost",
|
||||||
|
"email": "codeworxtech@users.sourceforge.net"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"name": "Brent R. Matzelle"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"description": "PHPMailer is a full-featured email creation and transfer class for PHP",
|
||||||
|
"support": {
|
||||||
|
"issues": "https://github.com/PHPMailer/PHPMailer/issues",
|
||||||
|
"source": "https://github.com/PHPMailer/PHPMailer/tree/v6.10.0"
|
||||||
|
},
|
||||||
|
"funding": [
|
||||||
|
{
|
||||||
|
"url": "https://github.com/Synchro",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
],
|
||||||
|
"install-path": "../phpmailer/phpmailer"
|
||||||
|
}
|
||||||
],
|
],
|
||||||
"authors": [
|
"dev": true,
|
||||||
{
|
"dev-package-names": []
|
||||||
"name": "Marcus Bointon",
|
}
|
||||||
"email": "phpmailer@synchromedia.co.uk"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "Jim Jagielski",
|
|
||||||
"email": "jimjag@gmail.com"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "Andy Prevost",
|
|
||||||
"email": "codeworxtech@users.sourceforge.net"
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"name": "Brent R. Matzelle"
|
|
||||||
}
|
|
||||||
],
|
|
||||||
"description": "PHPMailer is a full-featured email creation and transfer class for PHP",
|
|
||||||
"funding": [
|
|
||||||
{
|
|
||||||
"url": "https://github.com/Synchro",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
]
|
|
||||||
|
|
32
phpmailer/vendor/composer/installed.php
vendored
Normal file
32
phpmailer/vendor/composer/installed.php
vendored
Normal file
|
@ -0,0 +1,32 @@
|
||||||
|
<?php return array(
|
||||||
|
'root' => array(
|
||||||
|
'name' => 'friendica-addons/phpmailer',
|
||||||
|
'pretty_version' => 'dev-2025.07-rc',
|
||||||
|
'version' => 'dev-2025.07-rc',
|
||||||
|
'reference' => '715f70032330ad14f710284104c8593c7800e125',
|
||||||
|
'type' => 'friendica-addon',
|
||||||
|
'install_path' => __DIR__ . '/../../',
|
||||||
|
'aliases' => array(),
|
||||||
|
'dev' => true,
|
||||||
|
),
|
||||||
|
'versions' => array(
|
||||||
|
'friendica-addons/phpmailer' => array(
|
||||||
|
'pretty_version' => 'dev-2025.07-rc',
|
||||||
|
'version' => 'dev-2025.07-rc',
|
||||||
|
'reference' => '715f70032330ad14f710284104c8593c7800e125',
|
||||||
|
'type' => 'friendica-addon',
|
||||||
|
'install_path' => __DIR__ . '/../../',
|
||||||
|
'aliases' => array(),
|
||||||
|
'dev_requirement' => false,
|
||||||
|
),
|
||||||
|
'phpmailer/phpmailer' => array(
|
||||||
|
'pretty_version' => 'v6.10.0',
|
||||||
|
'version' => '6.10.0.0',
|
||||||
|
'reference' => 'bf74d75a1fde6beaa34a0ddae2ec5fce0f72a144',
|
||||||
|
'type' => 'library',
|
||||||
|
'install_path' => __DIR__ . '/../phpmailer/phpmailer',
|
||||||
|
'aliases' => array(),
|
||||||
|
'dev_requirement' => false,
|
||||||
|
),
|
||||||
|
),
|
||||||
|
);
|
26
phpmailer/vendor/composer/platform_check.php
vendored
Normal file
26
phpmailer/vendor/composer/platform_check.php
vendored
Normal file
|
@ -0,0 +1,26 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
// platform_check.php @generated by Composer
|
||||||
|
|
||||||
|
$issues = array();
|
||||||
|
|
||||||
|
if (!(PHP_VERSION_ID >= 70000)) {
|
||||||
|
$issues[] = 'Your Composer dependencies require a PHP version ">= 7.0.0". You are running ' . PHP_VERSION . '.';
|
||||||
|
}
|
||||||
|
|
||||||
|
if ($issues) {
|
||||||
|
if (!headers_sent()) {
|
||||||
|
header('HTTP/1.1 500 Internal Server Error');
|
||||||
|
}
|
||||||
|
if (!ini_get('display_errors')) {
|
||||||
|
if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') {
|
||||||
|
fwrite(STDERR, 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . implode(PHP_EOL, $issues) . PHP_EOL.PHP_EOL);
|
||||||
|
} elseif (!headers_sent()) {
|
||||||
|
echo 'Composer detected issues in your platform:' . PHP_EOL.PHP_EOL . str_replace('You are running '.PHP_VERSION.'.', '', implode(PHP_EOL, $issues)) . PHP_EOL.PHP_EOL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
trigger_error(
|
||||||
|
'Composer detected issues in your platform: ' . implode(' ', $issues),
|
||||||
|
E_USER_ERROR
|
||||||
|
);
|
||||||
|
}
|
|
@ -1,15 +0,0 @@
|
||||||
root = true
|
|
||||||
|
|
||||||
[*]
|
|
||||||
charset = utf-8
|
|
||||||
indent_size = 4
|
|
||||||
indent_style = space
|
|
||||||
end_of_line = lf
|
|
||||||
insert_final_newline = true
|
|
||||||
trim_trailing_whitespace = true
|
|
||||||
|
|
||||||
[*.md]
|
|
||||||
trim_trailing_whitespace = false
|
|
||||||
|
|
||||||
[*.{yml,yaml}]
|
|
||||||
indent_size = 2
|
|
27
phpmailer/vendor/phpmailer/phpmailer/README.md
vendored
27
phpmailer/vendor/phpmailer/phpmailer/README.md
vendored
|
@ -20,34 +20,35 @@
|
||||||
- Multipart/alternative emails for mail clients that do not read HTML email
|
- Multipart/alternative emails for mail clients that do not read HTML email
|
||||||
- Add attachments, including inline
|
- Add attachments, including inline
|
||||||
- Support for UTF-8 content and 8bit, base64, binary, and quoted-printable encodings
|
- Support for UTF-8 content and 8bit, base64, binary, and quoted-printable encodings
|
||||||
- SMTP authentication with LOGIN, PLAIN, CRAM-MD5, and XOAUTH2 mechanisms over SMTPS and SMTP+STARTTLS transports
|
- Full UTF-8 support when using servers that support `SMTPUTF8`.
|
||||||
|
- Support for iCal events in multiparts and attachments
|
||||||
|
- SMTP authentication with `LOGIN`, `PLAIN`, `CRAM-MD5`, and `XOAUTH2` mechanisms over SMTPS and SMTP+STARTTLS transports
|
||||||
- Validates email addresses automatically
|
- Validates email addresses automatically
|
||||||
- Protects against header injection attacks
|
- Protects against header injection attacks
|
||||||
- Error messages in over 50 languages!
|
- Error messages in over 50 languages!
|
||||||
- DKIM and S/MIME signing support
|
- DKIM and S/MIME signing support
|
||||||
- Compatible with PHP 5.5 and later, including PHP 8.2
|
- Compatible with PHP 5.5 and later, including PHP 8.4
|
||||||
- Namespaced to prevent name clashes
|
- Namespaced to prevent name clashes
|
||||||
- Much more!
|
- Much more!
|
||||||
|
|
||||||
## Why you might need it
|
## Why you might need it
|
||||||
Many PHP developers need to send email from their code. The only PHP function that supports this directly is [`mail()`](https://www.php.net/manual/en/function.mail.php). However, it does not provide any assistance for making use of popular features such as encryption, authentication, HTML messages, and attachments.
|
Many PHP developers need to send email from their code. The only PHP function that supports this directly is [`mail()`](https://www.php.net/manual/en/function.mail.php). However, it does not provide any assistance for making use of popular features such as authentication, HTML messages, and attachments.
|
||||||
|
|
||||||
Formatting email correctly is surprisingly difficult. There are myriad overlapping (and conflicting) standards, requiring tight adherence to horribly complicated formatting and encoding rules – the vast majority of code that you'll find online that uses the `mail()` function directly is just plain wrong, if not unsafe!
|
Formatting email correctly is surprisingly difficult. There are myriad overlapping (and conflicting) standards, requiring tight adherence to horribly complicated formatting and encoding rules – the vast majority of code that you'll find online that uses the `mail()` function directly is just plain wrong, if not unsafe!
|
||||||
|
|
||||||
The PHP `mail()` function usually sends via a local mail server, typically fronted by a `sendmail` binary on Linux, BSD, and macOS platforms, however, Windows usually doesn't include a local mail server; PHPMailer's integrated SMTP client allows email sending on all platforms without needing a local mail server. Be aware though, that the `mail()` function should be avoided when possible; it's both faster and [safer](https://exploitbox.io/paper/Pwning-PHP-Mail-Function-For-Fun-And-RCE.html) to use SMTP to localhost.
|
The PHP `mail()` function usually sends via a local mail server, typically fronted by a `sendmail` binary on Linux, BSD, and macOS platforms, however, Windows usually doesn't include a local mail server; PHPMailer's integrated SMTP client allows email sending on all platforms without needing a local mail server. Be aware though, that the `mail()` function should be avoided when possible; it's both faster and [safer](https://exploitbox.io/paper/Pwning-PHP-Mail-Function-For-Fun-And-RCE.html) to use SMTP to localhost.
|
||||||
|
|
||||||
*Please* don't be tempted to do it yourself – if you don't use PHPMailer, there are many other excellent libraries that
|
*Please* don't be tempted to do it yourself – if you don't use PHPMailer, there are many other excellent libraries that
|
||||||
you should look at before rolling your own. Try [SwiftMailer](https://swiftmailer.symfony.com/)
|
you should look at before rolling your own. Try [Symfony Mailer](https://symfony.com/doc/current/mailer.html), [Laminas/Mail](https://docs.laminas.dev/laminas-mail/), [ZetaComponents](https://github.com/zetacomponents/Mail), etc.
|
||||||
, [Laminas/Mail](https://docs.laminas.dev/laminas-mail/), [ZetaComponents](https://github.com/zetacomponents/Mail), etc.
|
|
||||||
|
|
||||||
## License
|
## License
|
||||||
This software is distributed under the [LGPL 2.1](http://www.gnu.org/licenses/lgpl-2.1.html) license, along with the [GPL Cooperation Commitment](https://gplcc.github.io/gplcc/). Please read [LICENSE](https://github.com/PHPMailer/PHPMailer/blob/master/LICENSE) for information on the software availability and distribution.
|
This software is distributed under the [LGPL 2.1](https://www.gnu.org/licenses/old-licenses/lgpl-2.1.html) license, along with the [GPL Cooperation Commitment](https://gplcc.github.io/gplcc/). Please read [LICENSE](https://github.com/PHPMailer/PHPMailer/blob/master/LICENSE) for information on the software availability and distribution.
|
||||||
|
|
||||||
## Installation & loading
|
## Installation & loading
|
||||||
PHPMailer is available on [Packagist](https://packagist.org/packages/phpmailer/phpmailer) (using semantic versioning), and installation via [Composer](https://getcomposer.org) is the recommended way to install PHPMailer. Just add this line to your `composer.json` file:
|
PHPMailer is available on [Packagist](https://packagist.org/packages/phpmailer/phpmailer) (using semantic versioning), and installation via [Composer](https://getcomposer.org) is the recommended way to install PHPMailer. Just add this line to your `composer.json` file:
|
||||||
|
|
||||||
```json
|
```json
|
||||||
"phpmailer/phpmailer": "^6.9.1"
|
"phpmailer/phpmailer": "^6.10.0"
|
||||||
```
|
```
|
||||||
|
|
||||||
or run
|
or run
|
||||||
|
@ -74,7 +75,7 @@ require 'path/to/PHPMailer/src/PHPMailer.php';
|
||||||
require 'path/to/PHPMailer/src/SMTP.php';
|
require 'path/to/PHPMailer/src/SMTP.php';
|
||||||
```
|
```
|
||||||
|
|
||||||
If you're not using the `SMTP` class explicitly (you're probably not), you don't need a `use` line for the SMTP class. Even if you're not using exceptions, you do still need to load the `Exception` class as it is used internally.
|
If you're not using the `SMTP` class explicitly (you're probably not), you don't need a `use` line for it. Even if you're not using exceptions, you do still need to load the `Exception` class as it is used internally.
|
||||||
|
|
||||||
## Legacy versions
|
## Legacy versions
|
||||||
PHPMailer 5.2 (which is compatible with PHP 5.0 — 7.0) is no longer supported, even for security updates. You will find the latest version of 5.2 in the [5.2-stable branch](https://github.com/PHPMailer/PHPMailer/tree/5.2-stable). If you're using PHP 5.5 or later (which you should be), switch to the 6.x releases.
|
PHPMailer 5.2 (which is compatible with PHP 5.0 — 7.0) is no longer supported, even for security updates. You will find the latest version of 5.2 in the [5.2-stable branch](https://github.com/PHPMailer/PHPMailer/tree/5.2-stable). If you're using PHP 5.5 or later (which you should be), switch to the 6.x releases.
|
||||||
|
@ -95,7 +96,7 @@ use PHPMailer\PHPMailer\PHPMailer;
|
||||||
use PHPMailer\PHPMailer\SMTP;
|
use PHPMailer\PHPMailer\SMTP;
|
||||||
use PHPMailer\PHPMailer\Exception;
|
use PHPMailer\PHPMailer\Exception;
|
||||||
|
|
||||||
//Load Composer's autoloader
|
//Load Composer's autoloader (created by composer, not included with PHPMailer)
|
||||||
require 'vendor/autoload.php';
|
require 'vendor/autoload.php';
|
||||||
|
|
||||||
//Create an instance; passing `true` enables exceptions
|
//Create an instance; passing `true` enables exceptions
|
||||||
|
@ -144,7 +145,7 @@ If you are re-using the instance (e.g. when sending to a mailing list), you may
|
||||||
That's it. You should now be ready to use PHPMailer!
|
That's it. You should now be ready to use PHPMailer!
|
||||||
|
|
||||||
## Localization
|
## Localization
|
||||||
PHPMailer defaults to English, but in the [language](https://github.com/PHPMailer/PHPMailer/tree/master/language/) folder, you'll find many translations for PHPMailer error messages that you may encounter. Their filenames contain [ISO 639-1](http://en.wikipedia.org/wiki/ISO_639-1) language code for the translations, for example `fr` for French. To specify a language, you need to tell PHPMailer which one to use, like this:
|
PHPMailer defaults to English, but in the [language](https://github.com/PHPMailer/PHPMailer/tree/master/language/) folder, you'll find many translations for PHPMailer error messages that you may encounter. Their filenames contain [ISO 639-1](https://en.wikipedia.org/wiki/ISO_639-1) language code for the translations, for example `fr` for French. To specify a language, you need to tell PHPMailer which one to use, like this:
|
||||||
|
|
||||||
```php
|
```php
|
||||||
//To load the French version
|
//To load the French version
|
||||||
|
@ -162,9 +163,9 @@ To reduce PHPMailer's deployed code footprint, examples are not included if you
|
||||||
|
|
||||||
Complete generated API documentation is [available online](https://phpmailer.github.io/PHPMailer/).
|
Complete generated API documentation is [available online](https://phpmailer.github.io/PHPMailer/).
|
||||||
|
|
||||||
You can generate complete API-level documentation by running `phpdoc` in the top-level folder, and documentation will appear in the `docs` folder, though you'll need to have [PHPDocumentor](http://www.phpdoc.org) installed. You may find [the unit tests](https://github.com/PHPMailer/PHPMailer/blob/master/test/PHPMailerTest.php) a good reference for how to do various operations such as encryption.
|
You can generate complete API-level documentation by running `phpdoc` in the top-level folder, and documentation will appear in the `docs` folder, though you'll need to have [PHPDocumentor](https://www.phpdoc.org) installed. You may find [the unit tests](https://github.com/PHPMailer/PHPMailer/blob/master/test/PHPMailer/PHPMailerTest.php) a good reference for how to do various operations such as encryption.
|
||||||
|
|
||||||
If the documentation doesn't cover what you need, search the [many questions on Stack Overflow](http://stackoverflow.com/questions/tagged/phpmailer), and before you ask a question about "SMTP Error: Could not connect to SMTP host.", [read the troubleshooting guide](https://github.com/PHPMailer/PHPMailer/wiki/Troubleshooting).
|
If the documentation doesn't cover what you need, search the [many questions on Stack Overflow](https://stackoverflow.com/questions/tagged/phpmailer), and before you ask a question about "SMTP Error: Could not connect to SMTP host.", [read the troubleshooting guide](https://github.com/PHPMailer/PHPMailer/wiki/Troubleshooting).
|
||||||
|
|
||||||
## Tests
|
## Tests
|
||||||
[PHPMailer tests](https://github.com/PHPMailer/PHPMailer/tree/master/test/) use PHPUnit 9, with [a polyfill](https://github.com/Yoast/PHPUnit-Polyfills) to let 9-style tests run on older PHPUnit and PHP versions.
|
[PHPMailer tests](https://github.com/PHPMailer/PHPMailer/tree/master/test/) use PHPUnit 9, with [a polyfill](https://github.com/Yoast/PHPUnit-Polyfills) to let 9-style tests run on older PHPUnit and PHP versions.
|
||||||
|
@ -213,7 +214,7 @@ use. [Learn more.](https://tidelift.com/subscription/pkg/packagist-phpmailer-php
|
||||||
See [changelog](changelog.md).
|
See [changelog](changelog.md).
|
||||||
|
|
||||||
## History
|
## History
|
||||||
- PHPMailer was originally written in 2001 by Brent R. Matzelle as a [SourceForge project](http://sourceforge.net/projects/phpmailer/).
|
- PHPMailer was originally written in 2001 by Brent R. Matzelle as a [SourceForge project](https://sourceforge.net/projects/phpmailer/).
|
||||||
- [Marcus Bointon](https://github.com/Synchro) (`coolbru` on SF) and Andy Prevost (`codeworxtech`) took over the project in 2004.
|
- [Marcus Bointon](https://github.com/Synchro) (`coolbru` on SF) and Andy Prevost (`codeworxtech`) took over the project in 2004.
|
||||||
- Became an Apache incubator project on Google Code in 2010, managed by Jim Jagielski.
|
- Became an Apache incubator project on Google Code in 2010, managed by Jim Jagielski.
|
||||||
- Marcus created [his fork on GitHub](https://github.com/Synchro/PHPMailer) in 2008.
|
- Marcus created [his fork on GitHub](https://github.com/Synchro/PHPMailer) in 2008.
|
||||||
|
|
|
@ -13,13 +13,13 @@ PHPMailer versions 6.1.5 and earlier contain an output escaping bug that occurs
|
||||||
|
|
||||||
PHPMailer versions prior to 6.0.6 and 5.2.27 are vulnerable to an object injection attack by passing `phar://` paths into `addAttachment()` and other functions that may receive unfiltered local paths, possibly leading to RCE. Recorded as [CVE-2018-19296](https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2018-19296). See [this article](https://knasmueller.net/5-answers-about-php-phar-exploitation) for more info on this type of vulnerability. Mitigated by blocking the use of paths containing URL-protocol style prefixes such as `phar://`. Reported by Sehun Oh of cyberone.kr.
|
PHPMailer versions prior to 6.0.6 and 5.2.27 are vulnerable to an object injection attack by passing `phar://` paths into `addAttachment()` and other functions that may receive unfiltered local paths, possibly leading to RCE. Recorded as [CVE-2018-19296](https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2018-19296). See [this article](https://knasmueller.net/5-answers-about-php-phar-exploitation) for more info on this type of vulnerability. Mitigated by blocking the use of paths containing URL-protocol style prefixes such as `phar://`. Reported by Sehun Oh of cyberone.kr.
|
||||||
|
|
||||||
PHPMailer versions prior to 5.2.24 (released July 26th 2017) have an XSS vulnerability in one of the code examples, [CVE-2017-11503](https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2017-11503). The `code_generator.phps` example did not filter user input prior to output. This file is distributed with a `.phps` extension, so it it not normally executable unless it is explicitly renamed, and the file is not included when PHPMailer is loaded through composer, so it is safe by default. There was also an undisclosed potential XSS vulnerability in the default exception handler (unused by default). Patches for both issues kindly provided by Patrick Monnerat of the Fedora Project.
|
PHPMailer versions prior to 5.2.24 (released July 26th 2017) have an XSS vulnerability in one of the code examples, [CVE-2017-11503](https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2017-11503). The `code_generator.phps` example did not filter user input prior to output. This file is distributed with a `.phps` extension, so it is not normally executable unless it is explicitly renamed, and the file is not included when PHPMailer is loaded through composer, so it is safe by default. There was also an undisclosed potential XSS vulnerability in the default exception handler (unused by default). Patches for both issues kindly provided by Patrick Monnerat of the Fedora Project.
|
||||||
|
|
||||||
PHPMailer versions prior to 5.2.22 (released January 9th 2017) have a local file disclosure vulnerability, [CVE-2017-5223](https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2017-5223). If content passed into `msgHTML()` is sourced from unfiltered user input, relative paths can map to absolute local file paths and added as attachments. Also note that `addAttachment` (just like `file_get_contents`, `passthru`, `unlink`, etc) should not be passed user-sourced params either! Reported by Yongxiang Li of Asiasecurity.
|
PHPMailer versions prior to 5.2.22 (released January 9th 2017) have a local file disclosure vulnerability, [CVE-2017-5223](https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2017-5223). If content passed into `msgHTML()` is sourced from unfiltered user input, relative paths can map to absolute local file paths and added as attachments. Also note that `addAttachment` (just like `file_get_contents`, `passthru`, `unlink`, etc) should not be passed user-sourced params either! Reported by Yongxiang Li of Asiasecurity.
|
||||||
|
|
||||||
PHPMailer versions prior to 5.2.20 (released December 28th 2016) are vulnerable to [CVE-2016-10045](https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2016-10045) a remote code execution vulnerability, responsibly reported by [Dawid Golunski](https://legalhackers.com/advisories/PHPMailer-Exploit-Remote-Code-Exec-CVE-2016-10045-Vuln-Patch-Bypass.html), and patched by Paul Buonopane (@Zenexer).
|
PHPMailer versions prior to 5.2.20 (released December 28th 2016) are vulnerable to [CVE-2016-10045](https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2016-10045) a remote code execution vulnerability, responsibly reported by [Dawid Golunski](https://legalhackers.com/advisories/PHPMailer-Exploit-Remote-Code-Exec-CVE-2016-10045-Vuln-Patch-Bypass.html), and patched by Paul Buonopane (@Zenexer).
|
||||||
|
|
||||||
PHPMailer versions prior to 5.2.18 (released December 2016) are vulnerable to [CVE-2016-10033](https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2016-10033) a remote code execution vulnerability, responsibly reported by [Dawid Golunski](http://legalhackers.com/advisories/PHPMailer-Exploit-Remote-Code-Exec-CVE-2016-10033-Vuln.html).
|
PHPMailer versions prior to 5.2.18 (released December 2016) are vulnerable to [CVE-2016-10033](https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2016-10033) a remote code execution vulnerability, responsibly reported by [Dawid Golunski](https://legalhackers.com/advisories/PHPMailer-Exploit-Remote-Code-Exec-CVE-2016-10033-Vuln.html).
|
||||||
|
|
||||||
PHPMailer versions prior to 5.2.14 (released November 2015) are vulnerable to [CVE-2015-8476](https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2015-8476) an SMTP CRLF injection bug permitting arbitrary message sending.
|
PHPMailer versions prior to 5.2.14 (released November 2015) are vulnerable to [CVE-2015-8476](https://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2015-8476) an SMTP CRLF injection bug permitting arbitrary message sending.
|
||||||
|
|
||||||
|
|
48
phpmailer/vendor/phpmailer/phpmailer/SMTPUTF8.md
vendored
Normal file
48
phpmailer/vendor/phpmailer/phpmailer/SMTPUTF8.md
vendored
Normal file
|
@ -0,0 +1,48 @@
|
||||||
|
# A short history of UTF-8 in email
|
||||||
|
|
||||||
|
## Background
|
||||||
|
|
||||||
|
For most of its existence, SMTP has been a 7-bit channel, only supporting US-ASCII characters. This has been a problem for many languages, especially those that use non-Latin scripts, and has led to the development of various workarounds.
|
||||||
|
|
||||||
|
The first major improvement, introduced in 1994 in [RFC 1652](https://www.rfc-editor.org/rfc/rfc1652) and extended in 2011 in [RFC 6152](https://www.rfc-editor.org/rfc/rfc6152), was the addition of the `8BITMIME` SMTP extension, which allowed raw 8-bit data to be included in message bodies sent over SMTP.
|
||||||
|
This allowed the message *contents* to contain 8-bit data, including things like UTF-8 text, even though the SMTP protocol itself was still firmly 7-bit. This worked by having the server switch to 8-bit after the headers, and then back to 7-bit after the completion of a `DATA` command.
|
||||||
|
|
||||||
|
From 1996, messages could support [RFC 2047 encoding](https://www.rfc-editor.org/rfc/rfc2047), which permitted inserting characters from any character set into header *values* (but not names), but only by encoding them in somewhat unreadable ways to allow them to survive passage through a 7-bit channel. An example with a subject of "Schrödinger's cat" would be:
|
||||||
|
|
||||||
|
```
|
||||||
|
Subject: =?utf-8?Q=Schr=C3=B6dinger=92s_Cat?=
|
||||||
|
```
|
||||||
|
|
||||||
|
Here the accented `ö` is encoded as `=C3=B6`, which is the UTF-8 encoding of the 2-byte character, and the whole thing is wrapped in `=?utf-8?Q?` to indicate that it uses the UTF-8 charset and `quoted-printable` encoding. This is a bit of a hack, and not very human-friendly, but it works.
|
||||||
|
|
||||||
|
Similarly, 8-bit message bodies could be encoded using the same `quoted-printable` and `base64` content transfer encoding (CTE) schemes, which preserved the 8-bit content while encoding it in a format that could survive transmission through a 7-bit channel.
|
||||||
|
|
||||||
|
Domain names were originally also stuck in a 7-bit world, actually even more constrained to only a subset of the US-ASCII character set. But of course, many people want to have domains in their own language/script. Internationalized domain name (IDN) permitted this, using yet another complex encoding scheme called punycode, defined for domain names in 2003 in [RFC 3492](https://www.rfc-editor.org/rfc/rfc3492). This finally allowed the domain part (after the `@`) of email addresses to contain UTF-8, though it was actually an illusion preserved by email client applications. For example, an address of
|
||||||
|
`user@café.example.com` translates to
|
||||||
|
`user@xn--caf-dma.example.com` in punycode, rendering it mostly unreadable, but 7-bit friendly, and remaining compatible with email clients that don't know about IDN.
|
||||||
|
|
||||||
|
The one remaining part of email that could not handle UTF-8 is the local part of email addresses (the part before the `@`).
|
||||||
|
|
||||||
|
I've only mentioned UTF-8 here, but most of these approaches also allowed other character sets that were popular, such as [the ISO-8859 family](https://en.wikipedia.org/wiki/ISO/IEC_8859). However, UTF-8 solves so many problems that these other character sets are gradually falling out of favour, as UTF-8 can support all languages.
|
||||||
|
|
||||||
|
This patchwork of overlapping approaches has served us well, but we have to admit that it's a mess.
|
||||||
|
|
||||||
|
## SMTPUTF8
|
||||||
|
|
||||||
|
`SMTPUTF8` is another SMTP extension, defined in [RFC 6531](https://www.rfc-editor.org/rfc/rfc6531) in 2012. This essentially solves the whole problem, allowing the entire SMTP conversation — commands, headers, and message bodies — to be sent in raw, unencoded UTF-8.
|
||||||
|
|
||||||
|
But there's a problem with this approach: adoption. If you send a UTF-8 message to a recipient whose mail server doesn't support this format, the sender has to somehow downgrade the message to make it survive a transition to 7-bit. This is a hard problem to solve, especially since there is no way to make a 7-bit system support UTF-8 in the local parts of addresses. This downgrade problem is what held up the adoption of `SMTPUTF8` in PHPMailer for many years, but in that time the *de facto* approach has become to simply fail in that situation, and tell the recipient it's time they upgraded their mail server 😅.
|
||||||
|
|
||||||
|
The vast majority of large email providers (gmail, Yahoo, Microsoft, etc), mail servers (postfix, exim, IIS, etc), and mail clients (Apple Mail, Outlook, Thunderbird, etc) now all support SMTPUTF8, so the need for backward compatibility is no longer what it was.
|
||||||
|
|
||||||
|
## SMTPUTF8 in PHPMailer
|
||||||
|
|
||||||
|
Several other PHP email libraries have implemented a halfway solution to `SMTPUTF8`, adding only the ability to support UTF-8 in email addresses, not elsewhere in the protocol. I wanted PHPMailer to do it "the right way", and this has taken much longer. PHPMailer now supports UTF-8 everywhere, and does not need to use transfer or header encodings for UTF-8 text when connecting to an `SMTPUTF8`-capable mail server.
|
||||||
|
|
||||||
|
This support is handled automatically: if you add an email address that requires UTF-8, PHPMailer will use UTF-8 for everything. If not, it will fall back to 7-bit and encode the message as necessary.
|
||||||
|
|
||||||
|
The one place you will need to be careful is in the selection of the address validator. By default, PHPMailer uses PHP's built-in `filter_var` validator, which does not allow UTF-8 email addresses. When PHPMailer spots that you have submitted a UTF-8 address, but have not altered the default validator, it will automatically switch to using a UTF-8-compatible validator. As soon as you do this, any SMTP connection you make will *require* that the server you connect to supports `SMTPUTF8`. You can select this validator explicitly by setting `PHPMailer::$validator = 'eai'` (an acronym for Email Address Internationalization).
|
||||||
|
|
||||||
|
### Postfix gotcha
|
||||||
|
|
||||||
|
Postfix has supported `SMTPUTF8` for a long time, but it has a peculiarity that it does not always advertise that it does so. However, rather surprisingly, if you use UTF-8 in the conversation, it will work anyway.
|
2
phpmailer/vendor/phpmailer/phpmailer/VERSION
vendored
2
phpmailer/vendor/phpmailer/phpmailer/VERSION
vendored
|
@ -1 +1 @@
|
||||||
6.9.1
|
6.10.0
|
||||||
|
|
|
@ -28,7 +28,8 @@
|
||||||
"config": {
|
"config": {
|
||||||
"allow-plugins": {
|
"allow-plugins": {
|
||||||
"dealerdirect/phpcodesniffer-composer-installer": true
|
"dealerdirect/phpcodesniffer-composer-installer": true
|
||||||
}
|
},
|
||||||
|
"lock": false
|
||||||
},
|
},
|
||||||
"require": {
|
"require": {
|
||||||
"php": ">=5.5.0",
|
"php": ">=5.5.0",
|
||||||
|
|
|
@ -12,7 +12,7 @@
|
||||||
* @copyright 2012 - 2020 Marcus Bointon
|
* @copyright 2012 - 2020 Marcus Bointon
|
||||||
* @copyright 2010 - 2012 Jim Jagielski
|
* @copyright 2010 - 2012 Jim Jagielski
|
||||||
* @copyright 2004 - 2009 Andy Prevost
|
* @copyright 2004 - 2009 Andy Prevost
|
||||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
* @license https://www.gnu.org/licenses/old-licenses/lgpl-2.1.html GNU Lesser General Public License
|
||||||
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE.
|
* FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
@ -36,7 +36,7 @@ namespace PHPMailer\PHPMailer;
|
||||||
* Aliases for League Provider Classes
|
* Aliases for League Provider Classes
|
||||||
* Make sure you have added these to your composer.json and run `composer install`
|
* Make sure you have added these to your composer.json and run `composer install`
|
||||||
* Plenty to choose from here:
|
* Plenty to choose from here:
|
||||||
* @see http://oauth2-client.thephpleague.com/providers/thirdparty/
|
* @see https://oauth2-client.thephpleague.com/providers/thirdparty/
|
||||||
*/
|
*/
|
||||||
//@see https://github.com/thephpleague/oauth2-google
|
//@see https://github.com/thephpleague/oauth2-google
|
||||||
use League\OAuth2\Client\Provider\Google;
|
use League\OAuth2\Client\Provider\Google;
|
||||||
|
@ -178,5 +178,5 @@ if (!isset($_GET['code'])) {
|
||||||
);
|
);
|
||||||
//Use this to interact with an API on the users behalf
|
//Use this to interact with an API on the users behalf
|
||||||
//Use this to get a new access token if the old one expires
|
//Use this to get a new access token if the old one expires
|
||||||
echo 'Refresh Token: ', $token->getRefreshToken();
|
echo 'Refresh Token: ', htmlspecialchars($token->getRefreshToken());
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,27 +5,32 @@
|
||||||
* @package PHPMailer
|
* @package PHPMailer
|
||||||
* @author Matt Sturdy <matt.sturdy@gmail.com>
|
* @author Matt Sturdy <matt.sturdy@gmail.com>
|
||||||
* @author Crystopher Glodzienski Cardoso <crystopher.glodzienski@gmail.com>
|
* @author Crystopher Glodzienski Cardoso <crystopher.glodzienski@gmail.com>
|
||||||
|
* @author Daniel Cruz <danicruz0415@gmail.com>
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$PHPMAILER_LANG['authenticate'] = 'Error SMTP: Imposible autentificar.';
|
$PHPMAILER_LANG['authenticate'] = 'Error SMTP: Imposible autentificar.';
|
||||||
|
$PHPMAILER_LANG['buggy_php'] = 'Tu versión de PHP está afectada por un bug que puede resultar en mensajes corruptos. Para arreglarlo, cambia a enviar usando SMTP, deshabilita la opción mail.add_x_header en tu php.ini, cambia a MacOS o Linux, o actualiza tu PHP a la versión 7.0.17+ o 7.1.3+.';
|
||||||
$PHPMAILER_LANG['connect_host'] = 'Error SMTP: Imposible conectar al servidor SMTP.';
|
$PHPMAILER_LANG['connect_host'] = 'Error SMTP: Imposible conectar al servidor SMTP.';
|
||||||
$PHPMAILER_LANG['data_not_accepted'] = 'Error SMTP: Datos no aceptados.';
|
$PHPMAILER_LANG['data_not_accepted'] = 'Error SMTP: Datos no aceptados.';
|
||||||
$PHPMAILER_LANG['empty_message'] = 'El cuerpo del mensaje está vacío.';
|
$PHPMAILER_LANG['empty_message'] = 'El cuerpo del mensaje está vacío.';
|
||||||
$PHPMAILER_LANG['encoding'] = 'Codificación desconocida: ';
|
$PHPMAILER_LANG['encoding'] = 'Codificación desconocida: ';
|
||||||
$PHPMAILER_LANG['execute'] = 'Imposible ejecutar: ';
|
$PHPMAILER_LANG['execute'] = 'Imposible ejecutar: ';
|
||||||
|
$PHPMAILER_LANG['extension_missing'] = 'Extensión faltante: ';
|
||||||
$PHPMAILER_LANG['file_access'] = 'Imposible acceder al archivo: ';
|
$PHPMAILER_LANG['file_access'] = 'Imposible acceder al archivo: ';
|
||||||
$PHPMAILER_LANG['file_open'] = 'Error de Archivo: Imposible abrir el archivo: ';
|
$PHPMAILER_LANG['file_open'] = 'Error de Archivo: Imposible abrir el archivo: ';
|
||||||
$PHPMAILER_LANG['from_failed'] = 'La(s) siguiente(s) direcciones de remitente fallaron: ';
|
$PHPMAILER_LANG['from_failed'] = 'La(s) siguiente(s) direcciones de remitente fallaron: ';
|
||||||
$PHPMAILER_LANG['instantiate'] = 'Imposible crear una instancia de la función Mail.';
|
$PHPMAILER_LANG['instantiate'] = 'Imposible crear una instancia de la función Mail.';
|
||||||
$PHPMAILER_LANG['invalid_address'] = 'Imposible enviar: dirección de email inválido: ';
|
$PHPMAILER_LANG['invalid_address'] = 'Imposible enviar: dirección de email inválido: ';
|
||||||
|
$PHPMAILER_LANG['invalid_header'] = 'Nombre o valor de encabezado no válido';
|
||||||
|
$PHPMAILER_LANG['invalid_hostentry'] = 'Hostentry inválido: ';
|
||||||
|
$PHPMAILER_LANG['invalid_host'] = 'Host inválido: ';
|
||||||
$PHPMAILER_LANG['mailer_not_supported'] = ' mailer no está soportado.';
|
$PHPMAILER_LANG['mailer_not_supported'] = ' mailer no está soportado.';
|
||||||
$PHPMAILER_LANG['provide_address'] = 'Debe proporcionar al menos una dirección de email de destino.';
|
$PHPMAILER_LANG['provide_address'] = 'Debe proporcionar al menos una dirección de email de destino.';
|
||||||
$PHPMAILER_LANG['recipients_failed'] = 'Error SMTP: Los siguientes destinos fallaron: ';
|
$PHPMAILER_LANG['recipients_failed'] = 'Error SMTP: Los siguientes destinos fallaron: ';
|
||||||
$PHPMAILER_LANG['signing'] = 'Error al firmar: ';
|
$PHPMAILER_LANG['signing'] = 'Error al firmar: ';
|
||||||
$PHPMAILER_LANG['smtp_connect_failed'] = 'SMTP Connect() falló.';
|
|
||||||
$PHPMAILER_LANG['smtp_error'] = 'Error del servidor SMTP: ';
|
|
||||||
$PHPMAILER_LANG['variable_set'] = 'No se pudo configurar la variable: ';
|
|
||||||
$PHPMAILER_LANG['extension_missing'] = 'Extensión faltante: ';
|
|
||||||
$PHPMAILER_LANG['smtp_code'] = 'Código del servidor SMTP: ';
|
$PHPMAILER_LANG['smtp_code'] = 'Código del servidor SMTP: ';
|
||||||
$PHPMAILER_LANG['smtp_code_ex'] = 'Información adicional del servidor SMTP: ';
|
$PHPMAILER_LANG['smtp_code_ex'] = 'Información adicional del servidor SMTP: ';
|
||||||
$PHPMAILER_LANG['invalid_header'] = 'Nombre o valor de encabezado no válido';
|
$PHPMAILER_LANG['smtp_connect_failed'] = 'SMTP Connect() falló.';
|
||||||
|
$PHPMAILER_LANG['smtp_detail'] = 'Detalle: ';
|
||||||
|
$PHPMAILER_LANG['smtp_error'] = 'Error del servidor SMTP: ';
|
||||||
|
$PHPMAILER_LANG['variable_set'] = 'No se pudo configurar la variable: ';
|
||||||
|
|
|
@ -6,7 +6,6 @@
|
||||||
* Some French punctuation requires a thin non-breaking space (U+202F) character before it,
|
* Some French punctuation requires a thin non-breaking space (U+202F) character before it,
|
||||||
* for example before a colon or exclamation mark.
|
* for example before a colon or exclamation mark.
|
||||||
* There is one of these characters between these quotes: " "
|
* There is one of these characters between these quotes: " "
|
||||||
* @see http://unicode.org/udhr/n/notes_fra.html
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$PHPMAILER_LANG['authenticate'] = 'Erreur SMTP : échec de l’authentification.';
|
$PHPMAILER_LANG['authenticate'] = 'Erreur SMTP : échec de l’authentification.';
|
||||||
|
@ -31,7 +30,7 @@ $PHPMAILER_LANG['recipients_failed'] = 'Erreur SMTP : les destinataires s
|
||||||
$PHPMAILER_LANG['signing'] = 'Erreur de signature : ';
|
$PHPMAILER_LANG['signing'] = 'Erreur de signature : ';
|
||||||
$PHPMAILER_LANG['smtp_code'] = 'Code SMTP : ';
|
$PHPMAILER_LANG['smtp_code'] = 'Code SMTP : ';
|
||||||
$PHPMAILER_LANG['smtp_code_ex'] = 'Informations supplémentaires SMTP : ';
|
$PHPMAILER_LANG['smtp_code_ex'] = 'Informations supplémentaires SMTP : ';
|
||||||
$PHPMAILER_LANG['smtp_connect_failed'] = 'La fonction SMTP connect() a échouée.';
|
$PHPMAILER_LANG['smtp_connect_failed'] = 'La fonction SMTP connect() a échoué.';
|
||||||
$PHPMAILER_LANG['smtp_detail'] = 'Détails : ';
|
$PHPMAILER_LANG['smtp_detail'] = 'Détails : ';
|
||||||
$PHPMAILER_LANG['smtp_error'] = 'Erreur du serveur SMTP : ';
|
$PHPMAILER_LANG['smtp_error'] = 'Erreur du serveur SMTP : ';
|
||||||
$PHPMAILER_LANG['variable_set'] = 'Impossible d’initialiser ou de réinitialiser une variable : ';
|
$PHPMAILER_LANG['variable_set'] = 'Impossible d’initialiser ou de réinitialiser une variable : ';
|
||||||
|
|
|
@ -3,27 +3,35 @@
|
||||||
/**
|
/**
|
||||||
* Japanese PHPMailer language file: refer to English translation for definitive list
|
* Japanese PHPMailer language file: refer to English translation for definitive list
|
||||||
* @package PHPMailer
|
* @package PHPMailer
|
||||||
* @author Mitsuhiro Yoshida <http://mitstek.com/>
|
* @author Mitsuhiro Yoshida <https://mitstek.com>
|
||||||
* @author Yoshi Sakai <http://bluemooninc.jp/>
|
* @author Yoshi Sakai <http://bluemooninc.jp/>
|
||||||
* @author Arisophy <https://github.com/arisophy/>
|
* @author Arisophy <https://github.com/arisophy/>
|
||||||
|
* @author ARAKI Musashi <https://github.com/arakim/>
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$PHPMAILER_LANG['authenticate'] = 'SMTPエラー: 認証できませんでした。';
|
$PHPMAILER_LANG['authenticate'] = 'SMTPエラー: 認証できませんでした。';
|
||||||
|
$PHPMAILER_LANG['buggy_php'] = 'ご利用のバージョンのPHPには不具合があり、メッセージが破損するおそれがあります。問題の解決は以下のいずれかを行ってください。SMTPでの送信に切り替える。php.iniのmail.add_x_headerをoffにする。MacOSまたはLinuxに切り替える。PHPバージョン7.0.17以降または7.1.3以降にアップグレードする。';
|
||||||
$PHPMAILER_LANG['connect_host'] = 'SMTPエラー: SMTPホストに接続できませんでした。';
|
$PHPMAILER_LANG['connect_host'] = 'SMTPエラー: SMTPホストに接続できませんでした。';
|
||||||
$PHPMAILER_LANG['data_not_accepted'] = 'SMTPエラー: データが受け付けられませんでした。';
|
$PHPMAILER_LANG['data_not_accepted'] = 'SMTPエラー: データが受け付けられませんでした。';
|
||||||
$PHPMAILER_LANG['empty_message'] = 'メール本文が空です。';
|
$PHPMAILER_LANG['empty_message'] = 'メール本文が空です。';
|
||||||
$PHPMAILER_LANG['encoding'] = '不明なエンコーディング: ';
|
$PHPMAILER_LANG['encoding'] = '不明なエンコーディング: ';
|
||||||
$PHPMAILER_LANG['execute'] = '実行できませんでした: ';
|
$PHPMAILER_LANG['execute'] = '実行できませんでした: ';
|
||||||
|
$PHPMAILER_LANG['extension_missing'] = '拡張機能が見つかりません: ';
|
||||||
$PHPMAILER_LANG['file_access'] = 'ファイルにアクセスできません: ';
|
$PHPMAILER_LANG['file_access'] = 'ファイルにアクセスできません: ';
|
||||||
$PHPMAILER_LANG['file_open'] = 'ファイルエラー: ファイルを開けません: ';
|
$PHPMAILER_LANG['file_open'] = 'ファイルエラー: ファイルを開けません: ';
|
||||||
$PHPMAILER_LANG['from_failed'] = 'Fromアドレスを登録する際にエラーが発生しました: ';
|
$PHPMAILER_LANG['from_failed'] = 'Fromアドレスを登録する際にエラーが発生しました: ';
|
||||||
$PHPMAILER_LANG['instantiate'] = 'メール関数が正常に動作しませんでした。';
|
$PHPMAILER_LANG['instantiate'] = 'メール関数が正常に動作しませんでした。';
|
||||||
$PHPMAILER_LANG['invalid_address'] = '不正なメールアドレス: ';
|
$PHPMAILER_LANG['invalid_address'] = '不正なメールアドレス: ';
|
||||||
$PHPMAILER_LANG['provide_address'] = '少なくとも1つメールアドレスを 指定する必要があります。';
|
$PHPMAILER_LANG['invalid_header'] = '不正なヘッダー名またはその内容';
|
||||||
|
$PHPMAILER_LANG['invalid_hostentry'] = '不正なホストエントリー: ';
|
||||||
|
$PHPMAILER_LANG['invalid_host'] = '不正なホスト: ';
|
||||||
$PHPMAILER_LANG['mailer_not_supported'] = ' メーラーがサポートされていません。';
|
$PHPMAILER_LANG['mailer_not_supported'] = ' メーラーがサポートされていません。';
|
||||||
|
$PHPMAILER_LANG['provide_address'] = '少なくとも1つメールアドレスを 指定する必要があります。';
|
||||||
$PHPMAILER_LANG['recipients_failed'] = 'SMTPエラー: 次の受信者アドレスに 間違いがあります: ';
|
$PHPMAILER_LANG['recipients_failed'] = 'SMTPエラー: 次の受信者アドレスに 間違いがあります: ';
|
||||||
$PHPMAILER_LANG['signing'] = '署名エラー: ';
|
$PHPMAILER_LANG['signing'] = '署名エラー: ';
|
||||||
|
$PHPMAILER_LANG['smtp_code'] = 'SMTPコード: ';
|
||||||
|
$PHPMAILER_LANG['smtp_code_ex'] = 'SMTP追加情報: ';
|
||||||
$PHPMAILER_LANG['smtp_connect_failed'] = 'SMTP接続に失敗しました。';
|
$PHPMAILER_LANG['smtp_connect_failed'] = 'SMTP接続に失敗しました。';
|
||||||
|
$PHPMAILER_LANG['smtp_detail'] = '詳細: ';
|
||||||
$PHPMAILER_LANG['smtp_error'] = 'SMTPサーバーエラー: ';
|
$PHPMAILER_LANG['smtp_error'] = 'SMTPサーバーエラー: ';
|
||||||
$PHPMAILER_LANG['variable_set'] = '変数が存在しません: ';
|
$PHPMAILER_LANG['variable_set'] = '変数が存在しません: ';
|
||||||
$PHPMAILER_LANG['extension_missing'] = '拡張機能が見つかりません: ';
|
|
||||||
|
|
27
phpmailer/vendor/phpmailer/phpmailer/language/phpmailer.lang-ku.php
vendored
Normal file
27
phpmailer/vendor/phpmailer/phpmailer/language/phpmailer.lang-ku.php
vendored
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Kurdish (Sorani) PHPMailer language file: refer to English translation for definitive list
|
||||||
|
* @package PHPMailer
|
||||||
|
* @author Halo Salman <halo@home4t.com>
|
||||||
|
*/
|
||||||
|
|
||||||
|
$PHPMAILER_LANG['authenticate'] = 'هەڵەی SMTP : نەتوانرا کۆدەکە پشتڕاست بکرێتەوە ';
|
||||||
|
$PHPMAILER_LANG['connect_host'] = 'هەڵەی SMTP: نەتوانرا پەیوەندی بە سێرڤەرەوە بکات SMTP.';
|
||||||
|
$PHPMAILER_LANG['data_not_accepted'] = 'هەڵەی SMTP: ئەو زانیاریانە قبوڵ نەکرا.';
|
||||||
|
$PHPMAILER_LANG['empty_message'] = 'پەیامەکە بەتاڵە';
|
||||||
|
$PHPMAILER_LANG['encoding'] = 'کۆدکردنی نەزانراو : ';
|
||||||
|
$PHPMAILER_LANG['execute'] = 'ناتوانرێت جێبەجێ بکرێت: ';
|
||||||
|
$PHPMAILER_LANG['file_access'] = 'ناتوانرێت دەستت بگات بە فایلەکە: ';
|
||||||
|
$PHPMAILER_LANG['file_open'] = 'هەڵەی پەڕگە(فایل): ناتوانرێت بکرێتەوە: ';
|
||||||
|
$PHPMAILER_LANG['from_failed'] = 'هەڵە لە ئاستی ناونیشانی نێرەر: ';
|
||||||
|
$PHPMAILER_LANG['instantiate'] = 'ناتوانرێت خزمەتگوزاری پۆستە پێشکەش بکرێت.';
|
||||||
|
$PHPMAILER_LANG['invalid_address'] = 'نەتوانرا بنێردرێت ، چونکە ناونیشانی ئیمەیڵەکە نادروستە: ';
|
||||||
|
$PHPMAILER_LANG['mailer_not_supported'] = ' مەیلەر پشتگیری ناکات';
|
||||||
|
$PHPMAILER_LANG['provide_address'] = 'دەبێت ناونیشانی ئیمەیڵی لانیکەم یەک وەرگر دابین بکرێت.';
|
||||||
|
$PHPMAILER_LANG['recipients_failed'] = ' هەڵەی SMTP: ئەم هەڵانەی خوارەوەشکستی هێنا لە ناردن بۆ هەردووکیان: ';
|
||||||
|
$PHPMAILER_LANG['signing'] = 'هەڵەی واژۆ: ';
|
||||||
|
$PHPMAILER_LANG['smtp_connect_failed'] = 'SMTP Connect()پەیوەندی شکستی هێنا .';
|
||||||
|
$PHPMAILER_LANG['smtp_error'] = 'هەڵەی ئاستی سێرڤەری SMTP: ';
|
||||||
|
$PHPMAILER_LANG['variable_set'] = 'ناتوانرێت بیگۆڕیت یان دوبارە بینێریتەوە: ';
|
||||||
|
$PHPMAILER_LANG['extension_missing'] = 'درێژکراوە نەماوە: ';
|
|
@ -3,25 +3,32 @@
|
||||||
/**
|
/**
|
||||||
* Portuguese (European) PHPMailer language file: refer to English translation for definitive list
|
* Portuguese (European) PHPMailer language file: refer to English translation for definitive list
|
||||||
* @package PHPMailer
|
* @package PHPMailer
|
||||||
* @author Jonadabe <jonadabe@hotmail.com>
|
* @author João Vieira <mail@joaovieira.eu>
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$PHPMAILER_LANG['authenticate'] = 'Erro do SMTP: Não foi possível realizar a autenticação.';
|
$PHPMAILER_LANG['authenticate'] = 'Erro SMTP: Falha na autenticação.';
|
||||||
$PHPMAILER_LANG['connect_host'] = 'Erro do SMTP: Não foi possível realizar ligação com o servidor SMTP.';
|
$PHPMAILER_LANG['buggy_php'] = 'A sua versão do PHP tem um bug que pode causar mensagens corrompidas. Para resolver, utilize o envio por SMTP, desative a opção mail.add_x_header no ficheiro php.ini, mude para MacOS ou Linux, ou atualize o PHP para a versão 7.0.17+ ou 7.1.3+.';
|
||||||
$PHPMAILER_LANG['data_not_accepted'] = 'Erro do SMTP: Os dados foram rejeitados.';
|
$PHPMAILER_LANG['connect_host'] = 'Erro SMTP: Não foi possível ligar ao servidor SMTP.';
|
||||||
$PHPMAILER_LANG['empty_message'] = 'A mensagem no e-mail está vazia.';
|
$PHPMAILER_LANG['data_not_accepted'] = 'Erro SMTP: Dados não aceites.';
|
||||||
|
$PHPMAILER_LANG['empty_message'] = 'A mensagem de e-mail está vazia.';
|
||||||
$PHPMAILER_LANG['encoding'] = 'Codificação desconhecida: ';
|
$PHPMAILER_LANG['encoding'] = 'Codificação desconhecida: ';
|
||||||
$PHPMAILER_LANG['execute'] = 'Não foi possível executar: ';
|
$PHPMAILER_LANG['execute'] = 'Não foi possível executar: ';
|
||||||
$PHPMAILER_LANG['file_access'] = 'Não foi possível aceder o ficheiro: ';
|
|
||||||
$PHPMAILER_LANG['file_open'] = 'Abertura do ficheiro: Não foi possível abrir o ficheiro: ';
|
|
||||||
$PHPMAILER_LANG['from_failed'] = 'Ocorreram falhas nos endereços dos seguintes remententes: ';
|
|
||||||
$PHPMAILER_LANG['instantiate'] = 'Não foi possível iniciar uma instância da função mail.';
|
|
||||||
$PHPMAILER_LANG['invalid_address'] = 'Não foi enviado nenhum e-mail para o endereço de e-mail inválido: ';
|
|
||||||
$PHPMAILER_LANG['mailer_not_supported'] = ' mailer não é suportado.';
|
|
||||||
$PHPMAILER_LANG['provide_address'] = 'Tem de fornecer pelo menos um endereço como destinatário do e-mail.';
|
|
||||||
$PHPMAILER_LANG['recipients_failed'] = 'Erro do SMTP: O endereço do seguinte destinatário falhou: ';
|
|
||||||
$PHPMAILER_LANG['signing'] = 'Erro ao assinar: ';
|
|
||||||
$PHPMAILER_LANG['smtp_connect_failed'] = 'SMTP Connect() falhou.';
|
|
||||||
$PHPMAILER_LANG['smtp_error'] = 'Erro de servidor SMTP: ';
|
|
||||||
$PHPMAILER_LANG['variable_set'] = 'Não foi possível definir ou redefinir a variável: ';
|
|
||||||
$PHPMAILER_LANG['extension_missing'] = 'Extensão em falta: ';
|
$PHPMAILER_LANG['extension_missing'] = 'Extensão em falta: ';
|
||||||
|
$PHPMAILER_LANG['file_access'] = 'Não foi possível aceder ao ficheiro: ';
|
||||||
|
$PHPMAILER_LANG['file_open'] = 'Erro ao abrir o ficheiro: ';
|
||||||
|
$PHPMAILER_LANG['from_failed'] = 'O envio falhou para o seguinte endereço do remetente: ';
|
||||||
|
$PHPMAILER_LANG['instantiate'] = 'Não foi possível instanciar a função mail.';
|
||||||
|
$PHPMAILER_LANG['invalid_address'] = 'Endereço de e-mail inválido: ';
|
||||||
|
$PHPMAILER_LANG['invalid_header'] = 'Nome ou valor do cabeçalho inválido.';
|
||||||
|
$PHPMAILER_LANG['invalid_hostentry'] = 'Entrada de host inválida: ';
|
||||||
|
$PHPMAILER_LANG['invalid_host'] = 'Host inválido: ';
|
||||||
|
$PHPMAILER_LANG['mailer_not_supported'] = 'O cliente de e-mail não é suportado.';
|
||||||
|
$PHPMAILER_LANG['provide_address'] = 'Deve fornecer pelo menos um endereço de destinatário.';
|
||||||
|
$PHPMAILER_LANG['recipients_failed'] = 'Erro SMTP: Falha no envio para os seguintes destinatários: ';
|
||||||
|
$PHPMAILER_LANG['signing'] = 'Erro ao assinar: ';
|
||||||
|
$PHPMAILER_LANG['smtp_code'] = 'Código SMTP: ';
|
||||||
|
$PHPMAILER_LANG['smtp_code_ex'] = 'Informações adicionais SMTP: ';
|
||||||
|
$PHPMAILER_LANG['smtp_connect_failed'] = 'Falha na função SMTP connect().';
|
||||||
|
$PHPMAILER_LANG['smtp_detail'] = 'Detalhes: ';
|
||||||
|
$PHPMAILER_LANG['smtp_error'] = 'Erro do servidor SMTP: ';
|
||||||
|
$PHPMAILER_LANG['variable_set'] = 'Não foi possível definir ou redefinir a variável: ';
|
||||||
|
|
|
@ -5,24 +5,32 @@
|
||||||
* @package PHPMailer
|
* @package PHPMailer
|
||||||
* @author Alexey Chumakov <alex@chumakov.ru>
|
* @author Alexey Chumakov <alex@chumakov.ru>
|
||||||
* @author Foster Snowhill <i18n@forstwoof.ru>
|
* @author Foster Snowhill <i18n@forstwoof.ru>
|
||||||
|
* @author ProjectSoft <projectsoft2009@yandex.ru>
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$PHPMAILER_LANG['authenticate'] = 'Ошибка SMTP: ошибка авторизации.';
|
$PHPMAILER_LANG['authenticate'] = 'Ошибка SMTP: не удалось пройти аутентификацию.';
|
||||||
|
$PHPMAILER_LANG['buggy_php'] = 'В вашей версии PHP есть ошибка, которая может привести к повреждению сообщений. Чтобы исправить, переключитесь на отправку по SMTP, отключите опцию mail.add_x_header в ваш php.ini, переключитесь на MacOS или Linux или обновите PHP до версии 7.0.17+ или 7.1.3+.';
|
||||||
$PHPMAILER_LANG['connect_host'] = 'Ошибка SMTP: не удается подключиться к SMTP-серверу.';
|
$PHPMAILER_LANG['connect_host'] = 'Ошибка SMTP: не удается подключиться к SMTP-серверу.';
|
||||||
$PHPMAILER_LANG['data_not_accepted'] = 'Ошибка SMTP: данные не приняты.';
|
$PHPMAILER_LANG['data_not_accepted'] = 'Ошибка SMTP: данные не приняты.';
|
||||||
|
$PHPMAILER_LANG['empty_message'] = 'Пустое сообщение';
|
||||||
$PHPMAILER_LANG['encoding'] = 'Неизвестная кодировка: ';
|
$PHPMAILER_LANG['encoding'] = 'Неизвестная кодировка: ';
|
||||||
$PHPMAILER_LANG['execute'] = 'Невозможно выполнить команду: ';
|
$PHPMAILER_LANG['execute'] = 'Невозможно выполнить команду: ';
|
||||||
|
$PHPMAILER_LANG['extension_missing'] = 'Расширение отсутствует: ';
|
||||||
$PHPMAILER_LANG['file_access'] = 'Нет доступа к файлу: ';
|
$PHPMAILER_LANG['file_access'] = 'Нет доступа к файлу: ';
|
||||||
$PHPMAILER_LANG['file_open'] = 'Файловая ошибка: не удаётся открыть файл: ';
|
$PHPMAILER_LANG['file_open'] = 'Файловая ошибка: не удаётся открыть файл: ';
|
||||||
$PHPMAILER_LANG['from_failed'] = 'Неверный адрес отправителя: ';
|
$PHPMAILER_LANG['from_failed'] = 'Неверный адрес отправителя: ';
|
||||||
$PHPMAILER_LANG['instantiate'] = 'Невозможно запустить функцию mail().';
|
$PHPMAILER_LANG['instantiate'] = 'Невозможно запустить функцию mail().';
|
||||||
$PHPMAILER_LANG['provide_address'] = 'Пожалуйста, введите хотя бы один email-адрес получателя.';
|
|
||||||
$PHPMAILER_LANG['mailer_not_supported'] = ' — почтовый сервер не поддерживается.';
|
|
||||||
$PHPMAILER_LANG['recipients_failed'] = 'Ошибка SMTP: не удалась отправка таким адресатам: ';
|
|
||||||
$PHPMAILER_LANG['empty_message'] = 'Пустое сообщение';
|
|
||||||
$PHPMAILER_LANG['invalid_address'] = 'Не отправлено из-за неправильного формата email-адреса: ';
|
$PHPMAILER_LANG['invalid_address'] = 'Не отправлено из-за неправильного формата email-адреса: ';
|
||||||
|
$PHPMAILER_LANG['invalid_header'] = 'Неверное имя или значение заголовка';
|
||||||
|
$PHPMAILER_LANG['invalid_hostentry'] = 'Неверная запись хоста: ';
|
||||||
|
$PHPMAILER_LANG['invalid_host'] = 'Неверный хост: ';
|
||||||
|
$PHPMAILER_LANG['mailer_not_supported'] = ' — почтовый сервер не поддерживается.';
|
||||||
|
$PHPMAILER_LANG['provide_address'] = 'Вы должны указать хотя бы один адрес электронной почты получателя.';
|
||||||
|
$PHPMAILER_LANG['recipients_failed'] = 'Ошибка SMTP: Ошибка следующих получателей: ';
|
||||||
$PHPMAILER_LANG['signing'] = 'Ошибка подписи: ';
|
$PHPMAILER_LANG['signing'] = 'Ошибка подписи: ';
|
||||||
$PHPMAILER_LANG['smtp_connect_failed'] = 'Ошибка соединения с SMTP-сервером';
|
$PHPMAILER_LANG['smtp_code'] = 'Код SMTP: ';
|
||||||
|
$PHPMAILER_LANG['smtp_code_ex'] = 'Дополнительная информация SMTP: ';
|
||||||
|
$PHPMAILER_LANG['smtp_connect_failed'] = 'Ошибка соединения с SMTP-сервером.';
|
||||||
|
$PHPMAILER_LANG['smtp_detail'] = 'Детали: ';
|
||||||
$PHPMAILER_LANG['smtp_error'] = 'Ошибка SMTP-сервера: ';
|
$PHPMAILER_LANG['smtp_error'] = 'Ошибка SMTP-сервера: ';
|
||||||
$PHPMAILER_LANG['variable_set'] = 'Невозможно установить или сбросить переменную: ';
|
$PHPMAILER_LANG['variable_set'] = 'Невозможно установить или сбросить переменную: ';
|
||||||
$PHPMAILER_LANG['extension_missing'] = 'Расширение отсутствует: ';
|
|
||||||
|
|
|
@ -11,21 +11,28 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
$PHPMAILER_LANG['authenticate'] = 'SMTP Hatası: Oturum açılamadı.';
|
$PHPMAILER_LANG['authenticate'] = 'SMTP Hatası: Oturum açılamadı.';
|
||||||
|
$PHPMAILER_LANG['buggy_php'] = 'PHP sürümünüz iletilerin bozulmasına neden olabilecek bir hatadan etkileniyor. Bunu düzeltmek için, SMTP kullanarak göndermeye geçin, mail.add_x_header seçeneğini devre dışı bırakın php.ini dosyanızdaki mail.add_x_header seçeneğini devre dışı bırakın, MacOS veya Linux geçin veya PHP sürümünü 7.0.17+ veya 7.1.3+ sürümüne yükseltin,';
|
||||||
$PHPMAILER_LANG['connect_host'] = 'SMTP Hatası: SMTP sunucusuna bağlanılamadı.';
|
$PHPMAILER_LANG['connect_host'] = 'SMTP Hatası: SMTP sunucusuna bağlanılamadı.';
|
||||||
$PHPMAILER_LANG['data_not_accepted'] = 'SMTP Hatası: Veri kabul edilmedi.';
|
$PHPMAILER_LANG['data_not_accepted'] = 'SMTP Hatası: Veri kabul edilmedi.';
|
||||||
$PHPMAILER_LANG['empty_message'] = 'Mesajın içeriği boş';
|
$PHPMAILER_LANG['empty_message'] = 'Mesajın içeriği boş';
|
||||||
$PHPMAILER_LANG['encoding'] = 'Bilinmeyen karakter kodlama: ';
|
$PHPMAILER_LANG['encoding'] = 'Bilinmeyen karakter kodlama: ';
|
||||||
$PHPMAILER_LANG['execute'] = 'Çalıştırılamadı: ';
|
$PHPMAILER_LANG['execute'] = 'Çalıştırılamadı: ';
|
||||||
|
$PHPMAILER_LANG['extension_missing'] = 'Eklenti bulunamadı: ';
|
||||||
$PHPMAILER_LANG['file_access'] = 'Dosyaya erişilemedi: ';
|
$PHPMAILER_LANG['file_access'] = 'Dosyaya erişilemedi: ';
|
||||||
$PHPMAILER_LANG['file_open'] = 'Dosya Hatası: Dosya açılamadı: ';
|
$PHPMAILER_LANG['file_open'] = 'Dosya Hatası: Dosya açılamadı: ';
|
||||||
$PHPMAILER_LANG['from_failed'] = 'Belirtilen adreslere gönderme başarısız: ';
|
$PHPMAILER_LANG['from_failed'] = 'Belirtilen adreslere gönderme başarısız: ';
|
||||||
$PHPMAILER_LANG['instantiate'] = 'Örnek e-posta fonksiyonu oluşturulamadı.';
|
$PHPMAILER_LANG['instantiate'] = 'Örnek e-posta fonksiyonu oluşturulamadı.';
|
||||||
$PHPMAILER_LANG['invalid_address'] = 'Geçersiz e-posta adresi: ';
|
$PHPMAILER_LANG['invalid_address'] = 'Geçersiz e-posta adresi: ';
|
||||||
|
$PHPMAILER_LANG['invalid_header'] = 'Geçersiz başlık adı veya değeri: ';
|
||||||
|
$PHPMAILER_LANG['invalid_hostentry'] = 'Geçersiz ana bilgisayar girişi: ';
|
||||||
|
$PHPMAILER_LANG['invalid_host'] = 'Geçersiz ana bilgisayar: ';
|
||||||
$PHPMAILER_LANG['mailer_not_supported'] = ' e-posta kütüphanesi desteklenmiyor.';
|
$PHPMAILER_LANG['mailer_not_supported'] = ' e-posta kütüphanesi desteklenmiyor.';
|
||||||
$PHPMAILER_LANG['provide_address'] = 'En az bir alıcı e-posta adresi belirtmelisiniz.';
|
$PHPMAILER_LANG['provide_address'] = 'En az bir alıcı e-posta adresi belirtmelisiniz.';
|
||||||
$PHPMAILER_LANG['recipients_failed'] = 'SMTP Hatası: Belirtilen alıcılara ulaşılamadı: ';
|
$PHPMAILER_LANG['recipients_failed'] = 'SMTP Hatası: Belirtilen alıcılara ulaşılamadı: ';
|
||||||
$PHPMAILER_LANG['signing'] = 'İmzalama hatası: ';
|
$PHPMAILER_LANG['signing'] = 'İmzalama hatası: ';
|
||||||
|
$PHPMAILER_LANG['smtp_code'] = 'SMTP kodu: ';
|
||||||
|
$PHPMAILER_LANG['smtp_code_ex'] = 'ek SMTP bilgileri: ';
|
||||||
$PHPMAILER_LANG['smtp_connect_failed'] = 'SMTP connect() fonksiyonu başarısız.';
|
$PHPMAILER_LANG['smtp_connect_failed'] = 'SMTP connect() fonksiyonu başarısız.';
|
||||||
|
$PHPMAILER_LANG['smtp_detail'] = 'SMTP SMTP Detayı: ';
|
||||||
$PHPMAILER_LANG['smtp_error'] = 'SMTP sunucu hatası: ';
|
$PHPMAILER_LANG['smtp_error'] = 'SMTP sunucu hatası: ';
|
||||||
$PHPMAILER_LANG['variable_set'] = 'Değişken ayarlanamadı ya da sıfırlanamadı: ';
|
$PHPMAILER_LANG['variable_set'] = 'Değişken ayarlanamadı ya da sıfırlanamadı: ';
|
||||||
$PHPMAILER_LANG['extension_missing'] = 'Eklenti bulunamadı: ';
|
|
||||||
|
|
30
phpmailer/vendor/phpmailer/phpmailer/language/phpmailer.lang-ur.php
vendored
Normal file
30
phpmailer/vendor/phpmailer/phpmailer/language/phpmailer.lang-ur.php
vendored
Normal file
|
@ -0,0 +1,30 @@
|
||||||
|
<?php
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Urdu PHPMailer language file: refer to English translation for definitive list
|
||||||
|
* @package PHPMailer
|
||||||
|
* @author Saqib Ali Siddiqui <saqibsra@gmail.com>
|
||||||
|
*/
|
||||||
|
|
||||||
|
$PHPMAILER_LANG['authenticate'] = 'SMTP خرابی: تصدیق کرنے سے قاصر۔';
|
||||||
|
$PHPMAILER_LANG['connect_host'] = 'SMTP خرابی: سرور سے منسلک ہونے سے قاصر۔';
|
||||||
|
$PHPMAILER_LANG['data_not_accepted'] = 'SMTP خرابی: ڈیٹا قبول نہیں کیا گیا۔';
|
||||||
|
$PHPMAILER_LANG['empty_message'] = 'پیغام کی باڈی خالی ہے۔';
|
||||||
|
$PHPMAILER_LANG['encoding'] = 'نامعلوم انکوڈنگ: ';
|
||||||
|
$PHPMAILER_LANG['execute'] = 'عمل کرنے کے قابل نہیں ';
|
||||||
|
$PHPMAILER_LANG['file_access'] = 'فائل تک رسائی سے قاصر:';
|
||||||
|
$PHPMAILER_LANG['file_open'] = 'فائل کی خرابی: فائل کو کھولنے سے قاصر:';
|
||||||
|
$PHPMAILER_LANG['from_failed'] = 'درج ذیل بھیجنے والے کا پتہ ناکام ہو گیا:';
|
||||||
|
$PHPMAILER_LANG['instantiate'] = 'میل فنکشن کی مثال بنانے سے قاصر۔';
|
||||||
|
$PHPMAILER_LANG['invalid_address'] = 'بھیجنے سے قاصر: غلط ای میل پتہ:';
|
||||||
|
$PHPMAILER_LANG['mailer_not_supported'] = ' میلر تعاون یافتہ نہیں ہے۔';
|
||||||
|
$PHPMAILER_LANG['provide_address'] = 'آپ کو کم از کم ایک منزل کا ای میل پتہ فراہم کرنا چاہیے۔';
|
||||||
|
$PHPMAILER_LANG['recipients_failed'] = 'SMTP خرابی: درج ذیل پتہ پر نہیں بھیجا جاسکا: ';
|
||||||
|
$PHPMAILER_LANG['signing'] = 'دستخط کی خرابی: ';
|
||||||
|
$PHPMAILER_LANG['smtp_connect_failed'] = 'SMTP ملنا ناکام ہوا';
|
||||||
|
$PHPMAILER_LANG['smtp_error'] = 'SMTP سرور کی خرابی: ';
|
||||||
|
$PHPMAILER_LANG['variable_set'] = 'متغیر سیٹ نہیں کیا جا سکا: ';
|
||||||
|
$PHPMAILER_LANG['extension_missing'] = 'ایکٹینشن موجود نہیں ہے۔ ';
|
||||||
|
$PHPMAILER_LANG['smtp_code'] = 'SMTP سرور کوڈ: ';
|
||||||
|
$PHPMAILER_LANG['smtp_code_ex'] = 'اضافی SMTP سرور کی معلومات:';
|
||||||
|
$PHPMAILER_LANG['invalid_header'] = 'غلط ہیڈر کا نام یا قدر';
|
|
@ -13,7 +13,7 @@
|
||||||
* @copyright 2012 - 2023 Marcus Bointon
|
* @copyright 2012 - 2023 Marcus Bointon
|
||||||
* @copyright 2010 - 2012 Jim Jagielski
|
* @copyright 2010 - 2012 Jim Jagielski
|
||||||
* @copyright 2004 - 2009 Andy Prevost
|
* @copyright 2004 - 2009 Andy Prevost
|
||||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
* @license https://www.gnu.org/licenses/old-licenses/lgpl-2.1.html GNU Lesser General Public License
|
||||||
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE.
|
* FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
* @copyright 2012 - 2020 Marcus Bointon
|
* @copyright 2012 - 2020 Marcus Bointon
|
||||||
* @copyright 2010 - 2012 Jim Jagielski
|
* @copyright 2010 - 2012 Jim Jagielski
|
||||||
* @copyright 2004 - 2009 Andy Prevost
|
* @copyright 2004 - 2009 Andy Prevost
|
||||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
* @license https://www.gnu.org/licenses/old-licenses/lgpl-2.1.html GNU Lesser General Public License
|
||||||
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE.
|
* FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
* @copyright 2012 - 2020 Marcus Bointon
|
* @copyright 2012 - 2020 Marcus Bointon
|
||||||
* @copyright 2010 - 2012 Jim Jagielski
|
* @copyright 2010 - 2012 Jim Jagielski
|
||||||
* @copyright 2004 - 2009 Andy Prevost
|
* @copyright 2004 - 2009 Andy Prevost
|
||||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
* @license https://www.gnu.org/licenses/old-licenses/lgpl-2.1.html GNU Lesser General Public License
|
||||||
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE.
|
* FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
@ -29,7 +29,7 @@ use League\OAuth2\Client\Token\AccessToken;
|
||||||
* OAuth - OAuth2 authentication wrapper class.
|
* OAuth - OAuth2 authentication wrapper class.
|
||||||
* Uses the oauth2-client package from the League of Extraordinary Packages.
|
* Uses the oauth2-client package from the League of Extraordinary Packages.
|
||||||
*
|
*
|
||||||
* @see http://oauth2-client.thephpleague.com
|
* @see https://oauth2-client.thephpleague.com
|
||||||
*
|
*
|
||||||
* @author Marcus Bointon (Synchro/coolbru) <phpmailer@synchromedia.co.uk>
|
* @author Marcus Bointon (Synchro/coolbru) <phpmailer@synchromedia.co.uk>
|
||||||
*/
|
*/
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
* @copyright 2012 - 2020 Marcus Bointon
|
* @copyright 2012 - 2020 Marcus Bointon
|
||||||
* @copyright 2010 - 2012 Jim Jagielski
|
* @copyright 2010 - 2012 Jim Jagielski
|
||||||
* @copyright 2004 - 2009 Andy Prevost
|
* @copyright 2004 - 2009 Andy Prevost
|
||||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
* @license https://www.gnu.org/licenses/old-licenses/lgpl-2.1.html GNU Lesser General Public License
|
||||||
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE.
|
* FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
* @copyright 2012 - 2020 Marcus Bointon
|
* @copyright 2012 - 2020 Marcus Bointon
|
||||||
* @copyright 2010 - 2012 Jim Jagielski
|
* @copyright 2010 - 2012 Jim Jagielski
|
||||||
* @copyright 2004 - 2009 Andy Prevost
|
* @copyright 2004 - 2009 Andy Prevost
|
||||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
* @license https://www.gnu.org/licenses/old-licenses/lgpl-2.1.html GNU Lesser General Public License
|
||||||
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE.
|
* FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
@ -152,8 +152,7 @@ class PHPMailer
|
||||||
* Only supported in simple alt or alt_inline message types
|
* Only supported in simple alt or alt_inline message types
|
||||||
* To generate iCal event structures, use classes like EasyPeasyICS or iCalcreator.
|
* To generate iCal event structures, use classes like EasyPeasyICS or iCalcreator.
|
||||||
*
|
*
|
||||||
* @see http://sprain.ch/blog/downloads/php-class-easypeasyics-create-ical-files-with-php/
|
* @see https://kigkonsult.se/iCalcreator/
|
||||||
* @see http://kigkonsult.se/iCalcreator/
|
|
||||||
*
|
*
|
||||||
* @var string
|
* @var string
|
||||||
*/
|
*/
|
||||||
|
@ -254,7 +253,7 @@ class PHPMailer
|
||||||
* You can set your own, but it must be in the format "<id@domain>",
|
* You can set your own, but it must be in the format "<id@domain>",
|
||||||
* as defined in RFC5322 section 3.6.4 or it will be ignored.
|
* as defined in RFC5322 section 3.6.4 or it will be ignored.
|
||||||
*
|
*
|
||||||
* @see https://tools.ietf.org/html/rfc5322#section-3.6.4
|
* @see https://www.rfc-editor.org/rfc/rfc5322#section-3.6.4
|
||||||
*
|
*
|
||||||
* @var string
|
* @var string
|
||||||
*/
|
*/
|
||||||
|
@ -358,7 +357,7 @@ class PHPMailer
|
||||||
public $AuthType = '';
|
public $AuthType = '';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* SMTP SMTPXClient command attibutes
|
* SMTP SMTPXClient command attributes
|
||||||
*
|
*
|
||||||
* @var array
|
* @var array
|
||||||
*/
|
*/
|
||||||
|
@ -388,7 +387,7 @@ class PHPMailer
|
||||||
* 'DELAY' will notify you if there is an unusual delay in delivery, but the actual
|
* 'DELAY' will notify you if there is an unusual delay in delivery, but the actual
|
||||||
* delivery's outcome (success or failure) is not yet decided.
|
* delivery's outcome (success or failure) is not yet decided.
|
||||||
*
|
*
|
||||||
* @see https://tools.ietf.org/html/rfc3461 See section 4.1 for more information about NOTIFY
|
* @see https://www.rfc-editor.org/rfc/rfc3461.html#section-4.1 for more information about NOTIFY
|
||||||
*/
|
*/
|
||||||
public $dsn = '';
|
public $dsn = '';
|
||||||
|
|
||||||
|
@ -468,7 +467,7 @@ class PHPMailer
|
||||||
* Only applicable when sending via SMTP.
|
* Only applicable when sending via SMTP.
|
||||||
*
|
*
|
||||||
* @see https://en.wikipedia.org/wiki/Variable_envelope_return_path
|
* @see https://en.wikipedia.org/wiki/Variable_envelope_return_path
|
||||||
* @see http://www.postfix.org/VERP_README.html Postfix VERP info
|
* @see https://www.postfix.org/VERP_README.html Postfix VERP info
|
||||||
*
|
*
|
||||||
* @var bool
|
* @var bool
|
||||||
*/
|
*/
|
||||||
|
@ -551,10 +550,10 @@ class PHPMailer
|
||||||
* The function that handles the result of the send email action.
|
* The function that handles the result of the send email action.
|
||||||
* It is called out by send() for each email sent.
|
* It is called out by send() for each email sent.
|
||||||
*
|
*
|
||||||
* Value can be any php callable: http://www.php.net/is_callable
|
* Value can be any php callable: https://www.php.net/is_callable
|
||||||
*
|
*
|
||||||
* Parameters:
|
* Parameters:
|
||||||
* bool $result result of the send action
|
* bool $result result of the send action
|
||||||
* array $to email addresses of the recipients
|
* array $to email addresses of the recipients
|
||||||
* array $cc cc email addresses
|
* array $cc cc email addresses
|
||||||
* array $bcc bcc email addresses
|
* array $bcc bcc email addresses
|
||||||
|
@ -581,6 +580,10 @@ class PHPMailer
|
||||||
* May be a callable to inject your own validator, but there are several built-in validators.
|
* May be a callable to inject your own validator, but there are several built-in validators.
|
||||||
* The default validator uses PHP's FILTER_VALIDATE_EMAIL filter_var option.
|
* The default validator uses PHP's FILTER_VALIDATE_EMAIL filter_var option.
|
||||||
*
|
*
|
||||||
|
* If CharSet is UTF8, the validator is left at the default value,
|
||||||
|
* and you send to addresses that use non-ASCII local parts, then
|
||||||
|
* PHPMailer automatically changes to the 'eai' validator.
|
||||||
|
*
|
||||||
* @see PHPMailer::validateAddress()
|
* @see PHPMailer::validateAddress()
|
||||||
*
|
*
|
||||||
* @var string|callable
|
* @var string|callable
|
||||||
|
@ -660,6 +663,14 @@ class PHPMailer
|
||||||
*/
|
*/
|
||||||
protected $ReplyToQueue = [];
|
protected $ReplyToQueue = [];
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Whether the need for SMTPUTF8 has been detected. Set by
|
||||||
|
* preSend() if necessary.
|
||||||
|
*
|
||||||
|
* @var bool
|
||||||
|
*/
|
||||||
|
public $UseSMTPUTF8 = false;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The array of attachments.
|
* The array of attachments.
|
||||||
*
|
*
|
||||||
|
@ -757,7 +768,7 @@ class PHPMailer
|
||||||
*
|
*
|
||||||
* @var string
|
* @var string
|
||||||
*/
|
*/
|
||||||
const VERSION = '6.9.1';
|
const VERSION = '6.10.0';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Error severity: message only, continue processing.
|
* Error severity: message only, continue processing.
|
||||||
|
@ -903,7 +914,7 @@ class PHPMailer
|
||||||
}
|
}
|
||||||
//Is this a PSR-3 logger?
|
//Is this a PSR-3 logger?
|
||||||
if ($this->Debugoutput instanceof \Psr\Log\LoggerInterface) {
|
if ($this->Debugoutput instanceof \Psr\Log\LoggerInterface) {
|
||||||
$this->Debugoutput->debug($str);
|
$this->Debugoutput->debug(rtrim($str, "\r\n"));
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -1072,7 +1083,7 @@ class PHPMailer
|
||||||
* be modified after calling this function), addition of such addresses is delayed until send().
|
* be modified after calling this function), addition of such addresses is delayed until send().
|
||||||
* Addresses that have been added already return false, but do not throw exceptions.
|
* Addresses that have been added already return false, but do not throw exceptions.
|
||||||
*
|
*
|
||||||
* @param string $kind One of 'to', 'cc', 'bcc', or 'ReplyTo'
|
* @param string $kind One of 'to', 'cc', 'bcc', or 'Reply-To'
|
||||||
* @param string $address The email address
|
* @param string $address The email address
|
||||||
* @param string $name An optional username associated with the address
|
* @param string $name An optional username associated with the address
|
||||||
*
|
*
|
||||||
|
@ -1111,19 +1122,22 @@ class PHPMailer
|
||||||
$params = [$kind, $address, $name];
|
$params = [$kind, $address, $name];
|
||||||
//Enqueue addresses with IDN until we know the PHPMailer::$CharSet.
|
//Enqueue addresses with IDN until we know the PHPMailer::$CharSet.
|
||||||
//Domain is assumed to be whatever is after the last @ symbol in the address
|
//Domain is assumed to be whatever is after the last @ symbol in the address
|
||||||
if (static::idnSupported() && $this->has8bitChars(substr($address, ++$pos))) {
|
if ($this->has8bitChars(substr($address, ++$pos))) {
|
||||||
if ('Reply-To' !== $kind) {
|
if (static::idnSupported()) {
|
||||||
if (!array_key_exists($address, $this->RecipientsQueue)) {
|
if ('Reply-To' !== $kind) {
|
||||||
$this->RecipientsQueue[$address] = $params;
|
if (!array_key_exists($address, $this->RecipientsQueue)) {
|
||||||
|
$this->RecipientsQueue[$address] = $params;
|
||||||
|
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
} elseif (!array_key_exists($address, $this->ReplyToQueue)) {
|
||||||
|
$this->ReplyToQueue[$address] = $params;
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
} elseif (!array_key_exists($address, $this->ReplyToQueue)) {
|
|
||||||
$this->ReplyToQueue[$address] = $params;
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
|
//We have an 8-bit domain, but we are missing the necessary extensions to support it
|
||||||
|
//Or we are already sending to this address
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1161,6 +1175,15 @@ class PHPMailer
|
||||||
*/
|
*/
|
||||||
protected function addAnAddress($kind, $address, $name = '')
|
protected function addAnAddress($kind, $address, $name = '')
|
||||||
{
|
{
|
||||||
|
if (
|
||||||
|
self::$validator === 'php' &&
|
||||||
|
((bool) preg_match('/[\x80-\xFF]/', $address))
|
||||||
|
) {
|
||||||
|
//The caller has not altered the validator and is sending to an address
|
||||||
|
//with UTF-8, so assume that they want UTF-8 support instead of failing
|
||||||
|
$this->CharSet = self::CHARSET_UTF8;
|
||||||
|
self::$validator = 'eai';
|
||||||
|
}
|
||||||
if (!in_array($kind, ['to', 'cc', 'bcc', 'Reply-To'])) {
|
if (!in_array($kind, ['to', 'cc', 'bcc', 'Reply-To'])) {
|
||||||
$error_message = sprintf(
|
$error_message = sprintf(
|
||||||
'%s: %s',
|
'%s: %s',
|
||||||
|
@ -1212,7 +1235,7 @@ class PHPMailer
|
||||||
* Uses the imap_rfc822_parse_adrlist function if the IMAP extension is available.
|
* Uses the imap_rfc822_parse_adrlist function if the IMAP extension is available.
|
||||||
* Note that quotes in the name part are removed.
|
* Note that quotes in the name part are removed.
|
||||||
*
|
*
|
||||||
* @see http://www.andrew.cmu.edu/user/agreen1/testing/mrbs/web/Mail/RFC822.php A more careful implementation
|
* @see https://www.andrew.cmu.edu/user/agreen1/testing/mrbs/web/Mail/RFC822.php A more careful implementation
|
||||||
*
|
*
|
||||||
* @param string $addrstr The address list string
|
* @param string $addrstr The address list string
|
||||||
* @param bool $useimap Whether to use the IMAP extension to parse the list
|
* @param bool $useimap Whether to use the IMAP extension to parse the list
|
||||||
|
@ -1363,6 +1386,7 @@ class PHPMailer
|
||||||
* * `pcre` Use old PCRE implementation;
|
* * `pcre` Use old PCRE implementation;
|
||||||
* * `php` Use PHP built-in FILTER_VALIDATE_EMAIL;
|
* * `php` Use PHP built-in FILTER_VALIDATE_EMAIL;
|
||||||
* * `html5` Use the pattern given by the HTML5 spec for 'email' type form input elements.
|
* * `html5` Use the pattern given by the HTML5 spec for 'email' type form input elements.
|
||||||
|
* * `eai` Use a pattern similar to the HTML5 spec for 'email' and to firefox, extended to support EAI (RFC6530).
|
||||||
* * `noregex` Don't use a regex: super fast, really dumb.
|
* * `noregex` Don't use a regex: super fast, really dumb.
|
||||||
* Alternatively you may pass in a callable to inject your own validator, for example:
|
* Alternatively you may pass in a callable to inject your own validator, for example:
|
||||||
*
|
*
|
||||||
|
@ -1407,7 +1431,6 @@ class PHPMailer
|
||||||
* * IPv6 literals: 'first.last@[IPv6:a1::]'
|
* * IPv6 literals: 'first.last@[IPv6:a1::]'
|
||||||
* Not all of these will necessarily work for sending!
|
* Not all of these will necessarily work for sending!
|
||||||
*
|
*
|
||||||
* @see http://squiloople.com/2009/12/20/email-address-validation/
|
|
||||||
* @copyright 2009-2010 Michael Rushton
|
* @copyright 2009-2010 Michael Rushton
|
||||||
* Feel free to use and redistribute this code. But please keep this copyright notice.
|
* Feel free to use and redistribute this code. But please keep this copyright notice.
|
||||||
*/
|
*/
|
||||||
|
@ -1434,6 +1457,24 @@ class PHPMailer
|
||||||
'[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/sD',
|
'[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/sD',
|
||||||
$address
|
$address
|
||||||
);
|
);
|
||||||
|
case 'eai':
|
||||||
|
/*
|
||||||
|
* This is the pattern used in the HTML5 spec for validation of 'email' type
|
||||||
|
* form input elements (as above), modified to accept Unicode email addresses.
|
||||||
|
* This is also more lenient than Firefox' html5 spec, in order to make the regex faster.
|
||||||
|
* 'eai' is an acronym for Email Address Internationalization.
|
||||||
|
* This validator is selected automatically if you attempt to use recipient addresses
|
||||||
|
* that contain Unicode characters in the local part.
|
||||||
|
*
|
||||||
|
* @see https://html.spec.whatwg.org/#e-mail-state-(type=email)
|
||||||
|
* @see https://en.wikipedia.org/wiki/International_email
|
||||||
|
*/
|
||||||
|
return (bool) preg_match(
|
||||||
|
'/^[-\p{L}\p{N}\p{M}.!#$%&\'*+\/=?^_`{|}~]+@[\p{L}\p{N}\p{M}](?:[\p{L}\p{N}\p{M}-]{0,61}' .
|
||||||
|
'[\p{L}\p{N}\p{M}])?(?:\.[\p{L}\p{N}\p{M}]' .
|
||||||
|
'(?:[-\p{L}\p{N}\p{M}]{0,61}[\p{L}\p{N}\p{M}])?)*$/usD',
|
||||||
|
$address
|
||||||
|
);
|
||||||
case 'php':
|
case 'php':
|
||||||
default:
|
default:
|
||||||
return filter_var($address, FILTER_VALIDATE_EMAIL) !== false;
|
return filter_var($address, FILTER_VALIDATE_EMAIL) !== false;
|
||||||
|
@ -1567,9 +1608,26 @@ class PHPMailer
|
||||||
$this->error_count = 0; //Reset errors
|
$this->error_count = 0; //Reset errors
|
||||||
$this->mailHeader = '';
|
$this->mailHeader = '';
|
||||||
|
|
||||||
|
//The code below tries to support full use of Unicode,
|
||||||
|
//while remaining compatible with legacy SMTP servers to
|
||||||
|
//the greatest degree possible: If the message uses
|
||||||
|
//Unicode in the local parts of any addresses, it is sent
|
||||||
|
//using SMTPUTF8. If not, it it sent using
|
||||||
|
//punycode-encoded domains and plain SMTP.
|
||||||
|
if (
|
||||||
|
static::CHARSET_UTF8 === strtolower($this->CharSet) &&
|
||||||
|
($this->anyAddressHasUnicodeLocalPart($this->RecipientsQueue) ||
|
||||||
|
$this->anyAddressHasUnicodeLocalPart(array_keys($this->all_recipients)) ||
|
||||||
|
$this->anyAddressHasUnicodeLocalPart($this->ReplyToQueue) ||
|
||||||
|
$this->addressHasUnicodeLocalPart($this->From))
|
||||||
|
) {
|
||||||
|
$this->UseSMTPUTF8 = true;
|
||||||
|
}
|
||||||
//Dequeue recipient and Reply-To addresses with IDN
|
//Dequeue recipient and Reply-To addresses with IDN
|
||||||
foreach (array_merge($this->RecipientsQueue, $this->ReplyToQueue) as $params) {
|
foreach (array_merge($this->RecipientsQueue, $this->ReplyToQueue) as $params) {
|
||||||
$params[1] = $this->punyencodeAddress($params[1]);
|
if (!$this->UseSMTPUTF8) {
|
||||||
|
$params[1] = $this->punyencodeAddress($params[1]);
|
||||||
|
}
|
||||||
call_user_func_array([$this, 'addAnAddress'], $params);
|
call_user_func_array([$this, 'addAnAddress'], $params);
|
||||||
}
|
}
|
||||||
if (count($this->to) + count($this->cc) + count($this->bcc) < 1) {
|
if (count($this->to) + count($this->cc) + count($this->bcc) < 1) {
|
||||||
|
@ -1734,9 +1792,8 @@ class PHPMailer
|
||||||
//This sets the SMTP envelope sender which gets turned into a return-path header by the receiver
|
//This sets the SMTP envelope sender which gets turned into a return-path header by the receiver
|
||||||
//A space after `-f` is optional, but there is a long history of its presence
|
//A space after `-f` is optional, but there is a long history of its presence
|
||||||
//causing problems, so we don't use one
|
//causing problems, so we don't use one
|
||||||
//Exim docs: http://www.exim.org/exim-html-current/doc/html/spec_html/ch-the_exim_command_line.html
|
//Exim docs: https://www.exim.org/exim-html-current/doc/html/spec_html/ch-the_exim_command_line.html
|
||||||
//Sendmail docs: http://www.sendmail.org/~ca/email/man/sendmail.html
|
//Sendmail docs: https://www.sendmail.org/~ca/email/man/sendmail.html
|
||||||
//Qmail docs: http://www.qmail.org/man/man8/qmail-inject.html
|
|
||||||
//Example problem: https://www.drupal.org/node/1057954
|
//Example problem: https://www.drupal.org/node/1057954
|
||||||
|
|
||||||
//PHP 5.6 workaround
|
//PHP 5.6 workaround
|
||||||
|
@ -1874,7 +1931,7 @@ class PHPMailer
|
||||||
*/
|
*/
|
||||||
protected static function isPermittedPath($path)
|
protected static function isPermittedPath($path)
|
||||||
{
|
{
|
||||||
//Matches scheme definition from https://tools.ietf.org/html/rfc3986#section-3.1
|
//Matches scheme definition from https://www.rfc-editor.org/rfc/rfc3986#section-3.1
|
||||||
return !preg_match('#^[a-z][a-z\d+.-]*://#i', $path);
|
return !preg_match('#^[a-z][a-z\d+.-]*://#i', $path);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1901,7 +1958,7 @@ class PHPMailer
|
||||||
/**
|
/**
|
||||||
* Send mail using the PHP mail() function.
|
* Send mail using the PHP mail() function.
|
||||||
*
|
*
|
||||||
* @see http://www.php.net/manual/en/book.mail.php
|
* @see https://www.php.net/manual/en/book.mail.php
|
||||||
*
|
*
|
||||||
* @param string $header The message headers
|
* @param string $header The message headers
|
||||||
* @param string $body The message body
|
* @param string $body The message body
|
||||||
|
@ -1931,9 +1988,8 @@ class PHPMailer
|
||||||
//This sets the SMTP envelope sender which gets turned into a return-path header by the receiver
|
//This sets the SMTP envelope sender which gets turned into a return-path header by the receiver
|
||||||
//A space after `-f` is optional, but there is a long history of its presence
|
//A space after `-f` is optional, but there is a long history of its presence
|
||||||
//causing problems, so we don't use one
|
//causing problems, so we don't use one
|
||||||
//Exim docs: http://www.exim.org/exim-html-current/doc/html/spec_html/ch-the_exim_command_line.html
|
//Exim docs: https://www.exim.org/exim-html-current/doc/html/spec_html/ch-the_exim_command_line.html
|
||||||
//Sendmail docs: http://www.sendmail.org/~ca/email/man/sendmail.html
|
//Sendmail docs: https://www.sendmail.org/~ca/email/man/sendmail.html
|
||||||
//Qmail docs: http://www.qmail.org/man/man8/qmail-inject.html
|
|
||||||
//Example problem: https://www.drupal.org/node/1057954
|
//Example problem: https://www.drupal.org/node/1057954
|
||||||
//CVE-2016-10033, CVE-2016-10045: Don't pass -f if characters will be escaped.
|
//CVE-2016-10033, CVE-2016-10045: Don't pass -f if characters will be escaped.
|
||||||
|
|
||||||
|
@ -2062,6 +2118,11 @@ class PHPMailer
|
||||||
if (!$this->smtpConnect($this->SMTPOptions)) {
|
if (!$this->smtpConnect($this->SMTPOptions)) {
|
||||||
throw new Exception($this->lang('smtp_connect_failed'), self::STOP_CRITICAL);
|
throw new Exception($this->lang('smtp_connect_failed'), self::STOP_CRITICAL);
|
||||||
}
|
}
|
||||||
|
//If we have recipient addresses that need Unicode support,
|
||||||
|
//but the server doesn't support it, stop here
|
||||||
|
if ($this->UseSMTPUTF8 && !$this->smtp->getServerExt('SMTPUTF8')) {
|
||||||
|
throw new Exception($this->lang('no_smtputf8'), self::STOP_CRITICAL);
|
||||||
|
}
|
||||||
//Sender already validated in preSend()
|
//Sender already validated in preSend()
|
||||||
if ('' === $this->Sender) {
|
if ('' === $this->Sender) {
|
||||||
$smtp_from = $this->From;
|
$smtp_from = $this->From;
|
||||||
|
@ -2163,6 +2224,7 @@ class PHPMailer
|
||||||
$this->smtp->setDebugLevel($this->SMTPDebug);
|
$this->smtp->setDebugLevel($this->SMTPDebug);
|
||||||
$this->smtp->setDebugOutput($this->Debugoutput);
|
$this->smtp->setDebugOutput($this->Debugoutput);
|
||||||
$this->smtp->setVerp($this->do_verp);
|
$this->smtp->setVerp($this->do_verp);
|
||||||
|
$this->smtp->setSMTPUTF8($this->UseSMTPUTF8);
|
||||||
if ($this->Host === null) {
|
if ($this->Host === null) {
|
||||||
$this->Host = 'localhost';
|
$this->Host = 'localhost';
|
||||||
}
|
}
|
||||||
|
@ -2360,6 +2422,7 @@ class PHPMailer
|
||||||
'smtp_detail' => 'Detail: ',
|
'smtp_detail' => 'Detail: ',
|
||||||
'smtp_error' => 'SMTP server error: ',
|
'smtp_error' => 'SMTP server error: ',
|
||||||
'variable_set' => 'Cannot set or reset variable: ',
|
'variable_set' => 'Cannot set or reset variable: ',
|
||||||
|
'no_smtputf8' => 'Server does not support SMTPUTF8 needed to send to Unicode addresses',
|
||||||
];
|
];
|
||||||
if (empty($lang_path)) {
|
if (empty($lang_path)) {
|
||||||
//Calculate an absolute path so it can work if CWD is not here
|
//Calculate an absolute path so it can work if CWD is not here
|
||||||
|
@ -2709,7 +2772,7 @@ class PHPMailer
|
||||||
}
|
}
|
||||||
|
|
||||||
//Only allow a custom message ID if it conforms to RFC 5322 section 3.6.4
|
//Only allow a custom message ID if it conforms to RFC 5322 section 3.6.4
|
||||||
//https://tools.ietf.org/html/rfc5322#section-3.6.4
|
//https://www.rfc-editor.org/rfc/rfc5322#section-3.6.4
|
||||||
if (
|
if (
|
||||||
'' !== $this->MessageID &&
|
'' !== $this->MessageID &&
|
||||||
preg_match(
|
preg_match(
|
||||||
|
@ -2874,7 +2937,9 @@ class PHPMailer
|
||||||
$bodyEncoding = $this->Encoding;
|
$bodyEncoding = $this->Encoding;
|
||||||
$bodyCharSet = $this->CharSet;
|
$bodyCharSet = $this->CharSet;
|
||||||
//Can we do a 7-bit downgrade?
|
//Can we do a 7-bit downgrade?
|
||||||
if (static::ENCODING_8BIT === $bodyEncoding && !$this->has8bitChars($this->Body)) {
|
if ($this->UseSMTPUTF8) {
|
||||||
|
$bodyEncoding = static::ENCODING_8BIT;
|
||||||
|
} elseif (static::ENCODING_8BIT === $bodyEncoding && !$this->has8bitChars($this->Body)) {
|
||||||
$bodyEncoding = static::ENCODING_7BIT;
|
$bodyEncoding = static::ENCODING_7BIT;
|
||||||
//All ISO 8859, Windows codepage and UTF-8 charsets are ascii compatible up to 7-bit
|
//All ISO 8859, Windows codepage and UTF-8 charsets are ascii compatible up to 7-bit
|
||||||
$bodyCharSet = static::CHARSET_ASCII;
|
$bodyCharSet = static::CHARSET_ASCII;
|
||||||
|
@ -3511,7 +3576,8 @@ class PHPMailer
|
||||||
/**
|
/**
|
||||||
* Encode a header value (not including its label) optimally.
|
* Encode a header value (not including its label) optimally.
|
||||||
* Picks shortest of Q, B, or none. Result includes folding if needed.
|
* Picks shortest of Q, B, or none. Result includes folding if needed.
|
||||||
* See RFC822 definitions for phrase, comment and text positions.
|
* See RFC822 definitions for phrase, comment and text positions,
|
||||||
|
* and RFC2047 for inline encodings.
|
||||||
*
|
*
|
||||||
* @param string $str The header value to encode
|
* @param string $str The header value to encode
|
||||||
* @param string $position What context the string will be used in
|
* @param string $position What context the string will be used in
|
||||||
|
@ -3520,6 +3586,11 @@ class PHPMailer
|
||||||
*/
|
*/
|
||||||
public function encodeHeader($str, $position = 'text')
|
public function encodeHeader($str, $position = 'text')
|
||||||
{
|
{
|
||||||
|
$position = strtolower($position);
|
||||||
|
if ($this->UseSMTPUTF8 && !("comment" === $position)) {
|
||||||
|
return trim(static::normalizeBreaks($str));
|
||||||
|
}
|
||||||
|
|
||||||
$matchcount = 0;
|
$matchcount = 0;
|
||||||
switch (strtolower($position)) {
|
switch (strtolower($position)) {
|
||||||
case 'phrase':
|
case 'phrase':
|
||||||
|
@ -3634,7 +3705,7 @@ class PHPMailer
|
||||||
* without breaking lines within a character.
|
* without breaking lines within a character.
|
||||||
* Adapted from a function by paravoid.
|
* Adapted from a function by paravoid.
|
||||||
*
|
*
|
||||||
* @see http://www.php.net/manual/en/function.mb-encode-mimeheader.php#60283
|
* @see https://www.php.net/manual/en/function.mb-encode-mimeheader.php#60283
|
||||||
*
|
*
|
||||||
* @param string $str multi-byte text to wrap encode
|
* @param string $str multi-byte text to wrap encode
|
||||||
* @param string $linebreak string to use as linefeed/end-of-line
|
* @param string $linebreak string to use as linefeed/end-of-line
|
||||||
|
@ -3690,7 +3761,7 @@ class PHPMailer
|
||||||
/**
|
/**
|
||||||
* Encode a string using Q encoding.
|
* Encode a string using Q encoding.
|
||||||
*
|
*
|
||||||
* @see http://tools.ietf.org/html/rfc2047#section-4.2
|
* @see https://www.rfc-editor.org/rfc/rfc2047#section-4.2
|
||||||
*
|
*
|
||||||
* @param string $str the text to encode
|
* @param string $str the text to encode
|
||||||
* @param string $position Where the text is going to be used, see the RFC for what that means
|
* @param string $position Where the text is going to be used, see the RFC for what that means
|
||||||
|
@ -4184,7 +4255,7 @@ class PHPMailer
|
||||||
if ('smtp' === $this->Mailer && null !== $this->smtp) {
|
if ('smtp' === $this->Mailer && null !== $this->smtp) {
|
||||||
$lasterror = $this->smtp->getError();
|
$lasterror = $this->smtp->getError();
|
||||||
if (!empty($lasterror['error'])) {
|
if (!empty($lasterror['error'])) {
|
||||||
$msg .= $this->lang('smtp_error') . $lasterror['error'];
|
$msg .= ' ' . $this->lang('smtp_error') . $lasterror['error'];
|
||||||
if (!empty($lasterror['detail'])) {
|
if (!empty($lasterror['detail'])) {
|
||||||
$msg .= ' ' . $this->lang('smtp_detail') . $lasterror['detail'];
|
$msg .= ' ' . $this->lang('smtp_detail') . $lasterror['detail'];
|
||||||
}
|
}
|
||||||
|
@ -4228,7 +4299,7 @@ class PHPMailer
|
||||||
$result = $_SERVER['SERVER_NAME'];
|
$result = $_SERVER['SERVER_NAME'];
|
||||||
} elseif (function_exists('gethostname') && gethostname() !== false) {
|
} elseif (function_exists('gethostname') && gethostname() !== false) {
|
||||||
$result = gethostname();
|
$result = gethostname();
|
||||||
} elseif (php_uname('n') !== false) {
|
} elseif (php_uname('n') !== '') {
|
||||||
$result = php_uname('n');
|
$result = php_uname('n');
|
||||||
}
|
}
|
||||||
if (!static::isValidHost($result)) {
|
if (!static::isValidHost($result)) {
|
||||||
|
@ -4253,7 +4324,7 @@ class PHPMailer
|
||||||
empty($host)
|
empty($host)
|
||||||
|| !is_string($host)
|
|| !is_string($host)
|
||||||
|| strlen($host) > 256
|
|| strlen($host) > 256
|
||||||
|| !preg_match('/^([a-zA-Z\d.-]*|\[[a-fA-F\d:]+\])$/', $host)
|
|| !preg_match('/^([a-z\d.-]*|\[[a-f\d:]+\])$/i', $host)
|
||||||
) {
|
) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -4267,10 +4338,49 @@ class PHPMailer
|
||||||
//Is it a valid IPv4 address?
|
//Is it a valid IPv4 address?
|
||||||
return filter_var($host, FILTER_VALIDATE_IP, FILTER_FLAG_IPV4) !== false;
|
return filter_var($host, FILTER_VALIDATE_IP, FILTER_FLAG_IPV4) !== false;
|
||||||
}
|
}
|
||||||
//Is it a syntactically valid hostname (when embeded in a URL)?
|
//Is it a syntactically valid hostname (when embedded in a URL)?
|
||||||
return filter_var('http://' . $host, FILTER_VALIDATE_URL) !== false;
|
return filter_var('https://' . $host, FILTER_VALIDATE_URL) !== false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Check whether the supplied address uses Unicode in the local part.
|
||||||
|
*
|
||||||
|
* @return bool
|
||||||
|
*/
|
||||||
|
protected function addressHasUnicodeLocalPart($address)
|
||||||
|
{
|
||||||
|
return (bool) preg_match('/[\x80-\xFF].*@/', $address);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Check whether any of the supplied addresses use Unicode in the local part.
|
||||||
|
*
|
||||||
|
* @return bool
|
||||||
|
*/
|
||||||
|
protected function anyAddressHasUnicodeLocalPart($addresses)
|
||||||
|
{
|
||||||
|
foreach ($addresses as $address) {
|
||||||
|
if (is_array($address)) {
|
||||||
|
$address = $address[0];
|
||||||
|
}
|
||||||
|
if ($this->addressHasUnicodeLocalPart($address)) {
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Check whether the message requires SMTPUTF8 based on what's known so far.
|
||||||
|
*
|
||||||
|
* @return bool
|
||||||
|
*/
|
||||||
|
public function needsSMTPUTF8()
|
||||||
|
{
|
||||||
|
return $this->UseSMTPUTF8;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get an error message in the current language.
|
* Get an error message in the current language.
|
||||||
*
|
*
|
||||||
|
@ -4679,7 +4789,7 @@ class PHPMailer
|
||||||
* Multi-byte-safe pathinfo replacement.
|
* Multi-byte-safe pathinfo replacement.
|
||||||
* Drop-in replacement for pathinfo(), but multibyte- and cross-platform-safe.
|
* Drop-in replacement for pathinfo(), but multibyte- and cross-platform-safe.
|
||||||
*
|
*
|
||||||
* @see http://www.php.net/manual/en/function.pathinfo.php#107461
|
* @see https://www.php.net/manual/en/function.pathinfo.php#107461
|
||||||
*
|
*
|
||||||
* @param string $path A filename or path, does not need to exist as a file
|
* @param string $path A filename or path, does not need to exist as a file
|
||||||
* @param int|string $options Either a PATHINFO_* constant,
|
* @param int|string $options Either a PATHINFO_* constant,
|
||||||
|
@ -4914,7 +5024,7 @@ class PHPMailer
|
||||||
* Uses the 'relaxed' algorithm from RFC6376 section 3.4.2.
|
* Uses the 'relaxed' algorithm from RFC6376 section 3.4.2.
|
||||||
* Canonicalized headers should *always* use CRLF, regardless of mailer setting.
|
* Canonicalized headers should *always* use CRLF, regardless of mailer setting.
|
||||||
*
|
*
|
||||||
* @see https://tools.ietf.org/html/rfc6376#section-3.4.2
|
* @see https://www.rfc-editor.org/rfc/rfc6376#section-3.4.2
|
||||||
*
|
*
|
||||||
* @param string $signHeader Header
|
* @param string $signHeader Header
|
||||||
*
|
*
|
||||||
|
@ -4926,7 +5036,7 @@ class PHPMailer
|
||||||
$signHeader = static::normalizeBreaks($signHeader, self::CRLF);
|
$signHeader = static::normalizeBreaks($signHeader, self::CRLF);
|
||||||
//Unfold header lines
|
//Unfold header lines
|
||||||
//Note PCRE \s is too broad a definition of whitespace; RFC5322 defines it as `[ \t]`
|
//Note PCRE \s is too broad a definition of whitespace; RFC5322 defines it as `[ \t]`
|
||||||
//@see https://tools.ietf.org/html/rfc5322#section-2.2
|
//@see https://www.rfc-editor.org/rfc/rfc5322#section-2.2
|
||||||
//That means this may break if you do something daft like put vertical tabs in your headers.
|
//That means this may break if you do something daft like put vertical tabs in your headers.
|
||||||
$signHeader = preg_replace('/\r\n[ \t]+/', ' ', $signHeader);
|
$signHeader = preg_replace('/\r\n[ \t]+/', ' ', $signHeader);
|
||||||
//Break headers out into an array
|
//Break headers out into an array
|
||||||
|
@ -4958,7 +5068,7 @@ class PHPMailer
|
||||||
* Uses the 'simple' algorithm from RFC6376 section 3.4.3.
|
* Uses the 'simple' algorithm from RFC6376 section 3.4.3.
|
||||||
* Canonicalized bodies should *always* use CRLF, regardless of mailer setting.
|
* Canonicalized bodies should *always* use CRLF, regardless of mailer setting.
|
||||||
*
|
*
|
||||||
* @see https://tools.ietf.org/html/rfc6376#section-3.4.3
|
* @see https://www.rfc-editor.org/rfc/rfc6376#section-3.4.3
|
||||||
*
|
*
|
||||||
* @param string $body Message Body
|
* @param string $body Message Body
|
||||||
*
|
*
|
||||||
|
@ -4994,7 +5104,7 @@ class PHPMailer
|
||||||
$DKIMquery = 'dns/txt'; //Query method
|
$DKIMquery = 'dns/txt'; //Query method
|
||||||
$DKIMtime = time();
|
$DKIMtime = time();
|
||||||
//Always sign these headers without being asked
|
//Always sign these headers without being asked
|
||||||
//Recommended list from https://tools.ietf.org/html/rfc6376#section-5.4.1
|
//Recommended list from https://www.rfc-editor.org/rfc/rfc6376#section-5.4.1
|
||||||
$autoSignHeaders = [
|
$autoSignHeaders = [
|
||||||
'from',
|
'from',
|
||||||
'to',
|
'to',
|
||||||
|
@ -5100,7 +5210,7 @@ class PHPMailer
|
||||||
}
|
}
|
||||||
//The DKIM-Signature header is included in the signature *except for* the value of the `b` tag
|
//The DKIM-Signature header is included in the signature *except for* the value of the `b` tag
|
||||||
//which is appended after calculating the signature
|
//which is appended after calculating the signature
|
||||||
//https://tools.ietf.org/html/rfc6376#section-3.5
|
//https://www.rfc-editor.org/rfc/rfc6376#section-3.5
|
||||||
$dkimSignatureHeader = 'DKIM-Signature: v=1;' .
|
$dkimSignatureHeader = 'DKIM-Signature: v=1;' .
|
||||||
' d=' . $this->DKIM_domain . ';' .
|
' d=' . $this->DKIM_domain . ';' .
|
||||||
' s=' . $this->DKIM_selector . ';' . static::$LE .
|
' s=' . $this->DKIM_selector . ';' . static::$LE .
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
* @copyright 2012 - 2020 Marcus Bointon
|
* @copyright 2012 - 2020 Marcus Bointon
|
||||||
* @copyright 2010 - 2012 Jim Jagielski
|
* @copyright 2010 - 2012 Jim Jagielski
|
||||||
* @copyright 2004 - 2009 Andy Prevost
|
* @copyright 2004 - 2009 Andy Prevost
|
||||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
* @license https://www.gnu.org/licenses/old-licenses/lgpl-2.1.html GNU Lesser General Public License
|
||||||
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE.
|
* FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
@ -46,7 +46,7 @@ class POP3
|
||||||
*
|
*
|
||||||
* @var string
|
* @var string
|
||||||
*/
|
*/
|
||||||
const VERSION = '6.9.1';
|
const VERSION = '6.10.0';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Default POP3 port number.
|
* Default POP3 port number.
|
||||||
|
@ -250,7 +250,9 @@ class POP3
|
||||||
|
|
||||||
//On Windows this will raise a PHP Warning error if the hostname doesn't exist.
|
//On Windows this will raise a PHP Warning error if the hostname doesn't exist.
|
||||||
//Rather than suppress it with @fsockopen, capture it cleanly instead
|
//Rather than suppress it with @fsockopen, capture it cleanly instead
|
||||||
set_error_handler([$this, 'catchWarning']);
|
set_error_handler(function () {
|
||||||
|
call_user_func_array([$this, 'catchWarning'], func_get_args());
|
||||||
|
});
|
||||||
|
|
||||||
if (false === $port) {
|
if (false === $port) {
|
||||||
$port = static::DEFAULT_PORT;
|
$port = static::DEFAULT_PORT;
|
||||||
|
|
|
@ -13,7 +13,7 @@
|
||||||
* @copyright 2012 - 2020 Marcus Bointon
|
* @copyright 2012 - 2020 Marcus Bointon
|
||||||
* @copyright 2010 - 2012 Jim Jagielski
|
* @copyright 2010 - 2012 Jim Jagielski
|
||||||
* @copyright 2004 - 2009 Andy Prevost
|
* @copyright 2004 - 2009 Andy Prevost
|
||||||
* @license http://www.gnu.org/copyleft/lesser.html GNU Lesser General Public License
|
* @license https://www.gnu.org/licenses/old-licenses/lgpl-2.1.html GNU Lesser General Public License
|
||||||
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
* @note This program is distributed in the hope that it will be useful - WITHOUT
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
||||||
* FITNESS FOR A PARTICULAR PURPOSE.
|
* FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
|
@ -35,7 +35,7 @@ class SMTP
|
||||||
*
|
*
|
||||||
* @var string
|
* @var string
|
||||||
*/
|
*/
|
||||||
const VERSION = '6.9.1';
|
const VERSION = '6.10.0';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* SMTP line break constant.
|
* SMTP line break constant.
|
||||||
|
@ -62,7 +62,7 @@ class SMTP
|
||||||
* The maximum line length allowed by RFC 5321 section 4.5.3.1.6,
|
* The maximum line length allowed by RFC 5321 section 4.5.3.1.6,
|
||||||
* *excluding* a trailing CRLF break.
|
* *excluding* a trailing CRLF break.
|
||||||
*
|
*
|
||||||
* @see https://tools.ietf.org/html/rfc5321#section-4.5.3.1.6
|
* @see https://www.rfc-editor.org/rfc/rfc5321#section-4.5.3.1.6
|
||||||
*
|
*
|
||||||
* @var int
|
* @var int
|
||||||
*/
|
*/
|
||||||
|
@ -72,7 +72,7 @@ class SMTP
|
||||||
* The maximum line length allowed for replies in RFC 5321 section 4.5.3.1.5,
|
* The maximum line length allowed for replies in RFC 5321 section 4.5.3.1.5,
|
||||||
* *including* a trailing CRLF line break.
|
* *including* a trailing CRLF line break.
|
||||||
*
|
*
|
||||||
* @see https://tools.ietf.org/html/rfc5321#section-4.5.3.1.5
|
* @see https://www.rfc-editor.org/rfc/rfc5321#section-4.5.3.1.5
|
||||||
*
|
*
|
||||||
* @var int
|
* @var int
|
||||||
*/
|
*/
|
||||||
|
@ -152,19 +152,28 @@ class SMTP
|
||||||
/**
|
/**
|
||||||
* Whether to use VERP.
|
* Whether to use VERP.
|
||||||
*
|
*
|
||||||
* @see http://en.wikipedia.org/wiki/Variable_envelope_return_path
|
* @see https://en.wikipedia.org/wiki/Variable_envelope_return_path
|
||||||
* @see http://www.postfix.org/VERP_README.html Info on VERP
|
* @see https://www.postfix.org/VERP_README.html Info on VERP
|
||||||
*
|
*
|
||||||
* @var bool
|
* @var bool
|
||||||
*/
|
*/
|
||||||
public $do_verp = false;
|
public $do_verp = false;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Whether to use SMTPUTF8.
|
||||||
|
*
|
||||||
|
* @see https://www.rfc-editor.org/rfc/rfc6531
|
||||||
|
*
|
||||||
|
* @var bool
|
||||||
|
*/
|
||||||
|
public $do_smtputf8 = false;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The timeout value for connection, in seconds.
|
* The timeout value for connection, in seconds.
|
||||||
* Default of 5 minutes (300sec) is from RFC2821 section 4.5.3.2.
|
* Default of 5 minutes (300sec) is from RFC2821 section 4.5.3.2.
|
||||||
* This needs to be quite high to function correctly with hosts using greetdelay as an anti-spam measure.
|
* This needs to be quite high to function correctly with hosts using greetdelay as an anti-spam measure.
|
||||||
*
|
*
|
||||||
* @see http://tools.ietf.org/html/rfc2821#section-4.5.3.2
|
* @see https://www.rfc-editor.org/rfc/rfc2821#section-4.5.3.2
|
||||||
*
|
*
|
||||||
* @var int
|
* @var int
|
||||||
*/
|
*/
|
||||||
|
@ -187,12 +196,12 @@ class SMTP
|
||||||
*/
|
*/
|
||||||
protected $smtp_transaction_id_patterns = [
|
protected $smtp_transaction_id_patterns = [
|
||||||
'exim' => '/[\d]{3} OK id=(.*)/',
|
'exim' => '/[\d]{3} OK id=(.*)/',
|
||||||
'sendmail' => '/[\d]{3} 2.0.0 (.*) Message/',
|
'sendmail' => '/[\d]{3} 2\.0\.0 (.*) Message/',
|
||||||
'postfix' => '/[\d]{3} 2.0.0 Ok: queued as (.*)/',
|
'postfix' => '/[\d]{3} 2\.0\.0 Ok: queued as (.*)/',
|
||||||
'Microsoft_ESMTP' => '/[0-9]{3} 2.[\d].0 (.*)@(?:.*) Queued mail for delivery/',
|
'Microsoft_ESMTP' => '/[0-9]{3} 2\.[\d]\.0 (.*)@(?:.*) Queued mail for delivery/',
|
||||||
'Amazon_SES' => '/[\d]{3} Ok (.*)/',
|
'Amazon_SES' => '/[\d]{3} Ok (.*)/',
|
||||||
'SendGrid' => '/[\d]{3} Ok: queued as (.*)/',
|
'SendGrid' => '/[\d]{3} Ok: queued as (.*)/',
|
||||||
'CampaignMonitor' => '/[\d]{3} 2.0.0 OK:([a-zA-Z\d]{48})/',
|
'CampaignMonitor' => '/[\d]{3} 2\.0\.0 OK:([a-zA-Z\d]{48})/',
|
||||||
'Haraka' => '/[\d]{3} Message Queued \((.*)\)/',
|
'Haraka' => '/[\d]{3} Message Queued \((.*)\)/',
|
||||||
'ZoneMTA' => '/[\d]{3} Message queued as (.*)/',
|
'ZoneMTA' => '/[\d]{3} Message queued as (.*)/',
|
||||||
'Mailjet' => '/[\d]{3} OK queued as (.*)/',
|
'Mailjet' => '/[\d]{3} OK queued as (.*)/',
|
||||||
|
@ -280,7 +289,8 @@ class SMTP
|
||||||
}
|
}
|
||||||
//Is this a PSR-3 logger?
|
//Is this a PSR-3 logger?
|
||||||
if ($this->Debugoutput instanceof \Psr\Log\LoggerInterface) {
|
if ($this->Debugoutput instanceof \Psr\Log\LoggerInterface) {
|
||||||
$this->Debugoutput->debug($str);
|
//Remove trailing line breaks potentially added by calls to SMTP::client_send()
|
||||||
|
$this->Debugoutput->debug(rtrim($str, "\r\n"));
|
||||||
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -293,6 +303,7 @@ class SMTP
|
||||||
switch ($this->Debugoutput) {
|
switch ($this->Debugoutput) {
|
||||||
case 'error_log':
|
case 'error_log':
|
||||||
//Don't output, just log
|
//Don't output, just log
|
||||||
|
/** @noinspection ForgottenDebugOutputInspection */
|
||||||
error_log($str);
|
error_log($str);
|
||||||
break;
|
break;
|
||||||
case 'html':
|
case 'html':
|
||||||
|
@ -371,7 +382,7 @@ class SMTP
|
||||||
}
|
}
|
||||||
//Anything other than a 220 response means something went wrong
|
//Anything other than a 220 response means something went wrong
|
||||||
//RFC 5321 says the server will wait for us to send a QUIT in response to a 554 error
|
//RFC 5321 says the server will wait for us to send a QUIT in response to a 554 error
|
||||||
//https://tools.ietf.org/html/rfc5321#section-3.1
|
//https://www.rfc-editor.org/rfc/rfc5321#section-3.1
|
||||||
if ($responseCode === 554) {
|
if ($responseCode === 554) {
|
||||||
$this->quit();
|
$this->quit();
|
||||||
}
|
}
|
||||||
|
@ -404,7 +415,9 @@ class SMTP
|
||||||
$errstr = '';
|
$errstr = '';
|
||||||
if ($streamok) {
|
if ($streamok) {
|
||||||
$socket_context = stream_context_create($options);
|
$socket_context = stream_context_create($options);
|
||||||
set_error_handler([$this, 'errorHandler']);
|
set_error_handler(function () {
|
||||||
|
call_user_func_array([$this, 'errorHandler'], func_get_args());
|
||||||
|
});
|
||||||
$connection = stream_socket_client(
|
$connection = stream_socket_client(
|
||||||
$host . ':' . $port,
|
$host . ':' . $port,
|
||||||
$errno,
|
$errno,
|
||||||
|
@ -419,7 +432,9 @@ class SMTP
|
||||||
'Connection: stream_socket_client not available, falling back to fsockopen',
|
'Connection: stream_socket_client not available, falling back to fsockopen',
|
||||||
self::DEBUG_CONNECTION
|
self::DEBUG_CONNECTION
|
||||||
);
|
);
|
||||||
set_error_handler([$this, 'errorHandler']);
|
set_error_handler(function () {
|
||||||
|
call_user_func_array([$this, 'errorHandler'], func_get_args());
|
||||||
|
});
|
||||||
$connection = fsockopen(
|
$connection = fsockopen(
|
||||||
$host,
|
$host,
|
||||||
$port,
|
$port,
|
||||||
|
@ -483,7 +498,9 @@ class SMTP
|
||||||
}
|
}
|
||||||
|
|
||||||
//Begin encrypted connection
|
//Begin encrypted connection
|
||||||
set_error_handler([$this, 'errorHandler']);
|
set_error_handler(function () {
|
||||||
|
call_user_func_array([$this, 'errorHandler'], func_get_args());
|
||||||
|
});
|
||||||
$crypto_ok = stream_socket_enable_crypto(
|
$crypto_ok = stream_socket_enable_crypto(
|
||||||
$this->smtp_conn,
|
$this->smtp_conn,
|
||||||
true,
|
true,
|
||||||
|
@ -574,7 +591,7 @@ class SMTP
|
||||||
}
|
}
|
||||||
//Send encoded username and password
|
//Send encoded username and password
|
||||||
if (
|
if (
|
||||||
//Format from https://tools.ietf.org/html/rfc4616#section-2
|
//Format from https://www.rfc-editor.org/rfc/rfc4616#section-2
|
||||||
//We skip the first field (it's forgery), so the string starts with a null byte
|
//We skip the first field (it's forgery), so the string starts with a null byte
|
||||||
!$this->sendCommand(
|
!$this->sendCommand(
|
||||||
'User & Password',
|
'User & Password',
|
||||||
|
@ -648,7 +665,7 @@ class SMTP
|
||||||
}
|
}
|
||||||
|
|
||||||
//The following borrowed from
|
//The following borrowed from
|
||||||
//http://php.net/manual/en/function.mhash.php#27225
|
//https://www.php.net/manual/en/function.mhash.php#27225
|
||||||
|
|
||||||
//RFC 2104 HMAC implementation for php.
|
//RFC 2104 HMAC implementation for php.
|
||||||
//Creates an md5 HMAC.
|
//Creates an md5 HMAC.
|
||||||
|
@ -787,7 +804,7 @@ class SMTP
|
||||||
//Send the lines to the server
|
//Send the lines to the server
|
||||||
foreach ($lines_out as $line_out) {
|
foreach ($lines_out as $line_out) {
|
||||||
//Dot-stuffing as per RFC5321 section 4.5.2
|
//Dot-stuffing as per RFC5321 section 4.5.2
|
||||||
//https://tools.ietf.org/html/rfc5321#section-4.5.2
|
//https://www.rfc-editor.org/rfc/rfc5321#section-4.5.2
|
||||||
if (!empty($line_out) && $line_out[0] === '.') {
|
if (!empty($line_out) && $line_out[0] === '.') {
|
||||||
$line_out = '.' . $line_out;
|
$line_out = '.' . $line_out;
|
||||||
}
|
}
|
||||||
|
@ -905,7 +922,15 @@ class SMTP
|
||||||
* $from. Returns true if successful or false otherwise. If True
|
* $from. Returns true if successful or false otherwise. If True
|
||||||
* the mail transaction is started and then one or more recipient
|
* the mail transaction is started and then one or more recipient
|
||||||
* commands may be called followed by a data command.
|
* commands may be called followed by a data command.
|
||||||
* Implements RFC 821: MAIL <SP> FROM:<reverse-path> <CRLF>.
|
* Implements RFC 821: MAIL <SP> FROM:<reverse-path> <CRLF> and
|
||||||
|
* two extensions, namely XVERP and SMTPUTF8.
|
||||||
|
*
|
||||||
|
* The server's EHLO response is not checked. If use of either
|
||||||
|
* extensions is enabled even though the server does not support
|
||||||
|
* that, mail submission will fail.
|
||||||
|
*
|
||||||
|
* XVERP is documented at https://www.postfix.org/VERP_README.html
|
||||||
|
* and SMTPUTF8 is specified in RFC 6531.
|
||||||
*
|
*
|
||||||
* @param string $from Source address of this message
|
* @param string $from Source address of this message
|
||||||
*
|
*
|
||||||
|
@ -914,10 +939,11 @@ class SMTP
|
||||||
public function mail($from)
|
public function mail($from)
|
||||||
{
|
{
|
||||||
$useVerp = ($this->do_verp ? ' XVERP' : '');
|
$useVerp = ($this->do_verp ? ' XVERP' : '');
|
||||||
|
$useSmtputf8 = ($this->do_smtputf8 ? ' SMTPUTF8' : '');
|
||||||
|
|
||||||
return $this->sendCommand(
|
return $this->sendCommand(
|
||||||
'MAIL FROM',
|
'MAIL FROM',
|
||||||
'MAIL FROM:<' . $from . '>' . $useVerp,
|
'MAIL FROM:<' . $from . '>' . $useSmtputf8 . $useVerp,
|
||||||
250
|
250
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
@ -1162,7 +1188,9 @@ class SMTP
|
||||||
} else {
|
} else {
|
||||||
$this->edebug('CLIENT -> SERVER: ' . $data, self::DEBUG_CLIENT);
|
$this->edebug('CLIENT -> SERVER: ' . $data, self::DEBUG_CLIENT);
|
||||||
}
|
}
|
||||||
set_error_handler([$this, 'errorHandler']);
|
set_error_handler(function () {
|
||||||
|
call_user_func_array([$this, 'errorHandler'], func_get_args());
|
||||||
|
});
|
||||||
$result = fwrite($this->smtp_conn, $data);
|
$result = fwrite($this->smtp_conn, $data);
|
||||||
restore_error_handler();
|
restore_error_handler();
|
||||||
|
|
||||||
|
@ -1265,7 +1293,9 @@ class SMTP
|
||||||
while (is_resource($this->smtp_conn) && !feof($this->smtp_conn)) {
|
while (is_resource($this->smtp_conn) && !feof($this->smtp_conn)) {
|
||||||
//Must pass vars in here as params are by reference
|
//Must pass vars in here as params are by reference
|
||||||
//solution for signals inspired by https://github.com/symfony/symfony/pull/6540
|
//solution for signals inspired by https://github.com/symfony/symfony/pull/6540
|
||||||
set_error_handler([$this, 'errorHandler']);
|
set_error_handler(function () {
|
||||||
|
call_user_func_array([$this, 'errorHandler'], func_get_args());
|
||||||
|
});
|
||||||
$n = stream_select($selR, $selW, $selW, $this->Timelimit);
|
$n = stream_select($selR, $selW, $selW, $this->Timelimit);
|
||||||
restore_error_handler();
|
restore_error_handler();
|
||||||
|
|
||||||
|
@ -1352,6 +1382,26 @@ class SMTP
|
||||||
return $this->do_verp;
|
return $this->do_verp;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Enable or disable use of SMTPUTF8.
|
||||||
|
*
|
||||||
|
* @param bool $enabled
|
||||||
|
*/
|
||||||
|
public function setSMTPUTF8($enabled = false)
|
||||||
|
{
|
||||||
|
$this->do_smtputf8 = $enabled;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get SMTPUTF8 use.
|
||||||
|
*
|
||||||
|
* @return bool
|
||||||
|
*/
|
||||||
|
public function getSMTPUTF8()
|
||||||
|
{
|
||||||
|
return $this->do_smtputf8;
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Set error messages and codes.
|
* Set error messages and codes.
|
||||||
*
|
*
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue