Email Configuration Issue

Wile configuring email i got this error
Email could not be sent: stream_socket_client(): unable to connect to tcp://{domain}:587 (Permission denied)
while using ./cake command to send email i got email but email configuration is default
Host: localhost
Port: 25
Password: *********
TLS: false
Sending email from: Passbolt you@localhost
Sending email to: {mail}

i change the config file on passbolt.default.php…but not working i tried to rename file to passbolt.php
as per documentation in Email/SMTP Configuration
i cannot find config/passbolt.php

Hi @abhimanyu :wave: and welcome to passbolt community forum :handshake:

Can you tell us on which operating system you are running passbolt and the documentation you followed ?

If running on a rpm Linux distro, can you give us the output of the sestatus command ?

If you are using gmail as SMTP provider, you can’t use you@localhost without modify smtp settings, as explained in our email troubleshooting page


I am running on centos 7.
i simply install my application shown on homepage and tried to setup smtp. I am not using gmail as SMTP provider.
Email setting in /etc/passbolt/passbolt.default.php

// Email configuration.
‘EmailTransport’ => [
‘default’ => [
‘host’ => ‘’,
‘port’ => 465,
‘username’ => ‘’,
‘password’ => ‘i******’,
// Is this a secure connection? true if yes, null if no.
‘tls’ => null,
//‘timeout’ => 30,
//‘client’ => null,
//‘url’ => null,
‘Email’ => [
‘default’ => [
// Defines the default name and email of the sender of the emails.
‘from’ => [‘’ => ‘Passbolt’],
//‘charset’ => ‘utf-8’,
//‘headerCharset’ => ‘utf-8’,

Hum ok I understand, you have followed this:

It is a quick how-to, the full documentation is here: Passbolt Help | Install Passbolt CE on CentOS 7

Once the package installed, you have to launch the configuration tool:

sudo /usr/local/bin/passbolt-configure

I will report that to the website team.


i already did that. Once i reached at email setup page i entered all parameters and test but i got
Email could not be sent: stream_socket_client(): unable to connect to tcp://{domain}:587 (Permission denied)

this error.

Ok perfect. Can you check if selinux is enabled with the sestatus command ?

We have a known issue with the current passbolt-selinux package, there is a missing rule for allowing communication with standard smtp ports.

The issue has been fixed but the new package is not yet published. You can try to reduce selinux hardening and check if it is your issue.
Open /etc/selinux/config and replace enforcing with permissive and reboot your server to apply.

I will keep you posted when the new passbolt-selinux package will be released.


Thank you that problem has been solved. Now receiving SMTP time out
when i send test mail via cli using ./cake to gmail it sent

Yes, It’s work for me!