Merge pull request #423 from geraldurbas/geraldurbas-patch-1

Change Ordering of SASLMechanisms
This commit is contained in:
the-djmaze 2022-05-30 13:13:01 +02:00 committed by GitHub
commit 98b49104cb
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -120,7 +120,7 @@ class SmtpClient extends \MailSo\Net\NetClient
$sPassword = $aCredentials['Password'];
$type = '';
$aCredentials['SASLMechanisms'][] = 'LOGIN';
array_unshift($aCredentials['SASLMechanisms'],'LOGIN');
foreach ($aCredentials['SASLMechanisms'] as $sasl_type) {
if ($this->IsAuthSupported($sasl_type) && \SnappyMail\SASL::isSupported($sasl_type)) {
$type = $sasl_type;