Skip to content

Mail (smtp): password and username not set in config  #18170

@maurocolella

Description

@maurocolella
  • Laravel Version: 5.4.12
  • PHP Version: HipHop VM 3.18.1 (rel)
  • Database Driver & Version: Ver 15.1 Distrib 10.1.21-MariaDB, for debian-linux-gnu (x86_64) using readline 5.2

Description:

If set in either config/mail.php, .env, or both, when using SMTP authentication over TLS or SSL, username and password are not set in config.

From a route, dd(Config::get('mail')); prints a configuration that misses username and password.

Steps To Reproduce:

Configure mail using either the global config/mail.php or .env file, eq.

MAIL_DRIVER=smtp
MAIL_HOST=smtp.gmail.com
MAIL_PORT=587
MAIL_USERNAME=support@domain.com
MAIL_PASSWORD=...
MAIL_ENCRYPTION=tls

Open matching outgoing ports (465 for ssl or 587 for tls). Authentication to the smtp server should fail (error 530). Server reports credentials are not set.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions