Connection problems by PHP command to read messages from Outlook Enterprise account

Alex V 0 Reputation points
2023-01-19T17:00:20.5733333+00:00

Hello I have been having problems since January 18 at 00:18 a.m. where I stopped generating problems when connecting to the outlook account by command to just capture the emails and enter the information to our platforms.

We had been working since November with the application password since it had stopped working with the normal password, and for security reasons we changed it. Now we have the same problem again, and the IT team changed the account and application passwords and still does not allow access. We use the library without OAuth, which is PHP-IMAP attached link https://github.com/Webklex/php-imap


        try {
            $cm = new ClientManager([
                'options' => [
                    'fetch' => \Webklex\PHPIMAP\IMAP::FT_PEEK,
                    'fetch_order' => 'desc',
                    'sequence' => \Webklex\PHPIMAP\IMAP::ST_UID,
                ],
            ]);
            static::$client = $cm->make([
                'host'          => 'outlook.office365.com',
                'port'          => 993,
                'protocol'      => 'IMAP',
                'encryption'    => 'ssl',
                'validate_cert' => true,
                'username'      => '******@company.cl',
                'password'      => 'passwordappl'
            ]);
            
            dd(static::$client->connect());
        } catch (\Throwable $th) {
            //throw $th;
            echo "No ingreso \n";
        }
        
Attached error message.

Besides all this we are using PHP 7.4 with Laravel 7 framework.

https://tinypic.host/i/error.Kcj4e

Image Error

Microsoft 365 and Office Development Other
Outlook Windows Classic Outlook for Windows For business
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.