CAN`T SEND EMAIL FROM USERS EMAIL ADDRESSES - URGENT PLEASE HELP

Hello and thank you for your reply.

As i can see from log file FromName is correct but in FROM: display the recipient email address

See below :

Tue Jul 10 09:06:41 2018 [8627][780ddb1d-1702-5d51-b59c-520523390ff7][FATAL] PHPMailer Send Function: { FromName: Nordine M. From: it@traders-trust.com Host: smtp.office365.com UserName: nme@ttcm.com }

And in outgoing mail server Properties i have :

Name: Nordine
From Name: nme@ttcm.com
From Address: nme@ttcm.com
Exchange Server: smtp.office365.com
Exchange Sever Port: 587
Enable SMTP over SSL or TLS: TLS
Exchange User name: nme@ttcm.com
Exchange Password: xxxxxxxx

For sure user credentials and Microsoft exchange settings are correct. I do not know if the problem is the value in FROM email address which showing recipient email address If anyone knows please let me know.

The above settings configured with admin user in user management -> user->edit -> settings -> mail accounts -> add

I see something else very strange. When i tried to configured outbound email settings from admin panel with same settings as above it`s working and i received the test email, but does not showing the specific email account in user email settings so i can choose it from there.

Please advise because i must find a solution yesterday :slight_smile:

Outbound Email

Outbound Email Accounts

Outbound Email Accounts Settings

Results:

I can’t assigned above account to any user because does not showing anywhere only global mail account showing.

User settings :


And when i tested from user mail accounts settings to add new outgoing Mail Server with admin user

Add mail settings to user from user management with admin user :

Email Address for test notification

ych@ttcm.com

Results :

Tue Jul 10 09:24:54 2018 [8570][1][FATAL] PHPMailer Send Function: { FromName: Yiannis C. From: ych@ttcm.com Host: smtp.office365.com UserName: nme@ttcm.com }

There is a bug with From Name, I’m not sure what you’re getting is exactly the same, but… let’s me give you a workaround and then let’s hope one of the next versions reviews this “From” code.

Just before that line where you uncommented the code to log the email settings, add this:


if (strcmp($this->FromName, 'Nordine M.') == 0) {
      $this->From = 'nme@ttcm.com';
}

This will force the correct value into place.

Thank you pgr for your help. I did above changes and now i am getting the error message client does not have permissions to send as this sender.

But this is not true because from user mailbox i can send behind this email address (csu@ttcm.com).

From Microsoft exchange, they informed that from the time that I can send behind of this mailbox then the problem still in Suite CRM.

Any ideas?

Error:SMTP Error: data not accepted.SMTP server error: DATA END command failed Detail: 5.7.60 SMTP; Client does not have permissions to send as this sender [HE1PR05MB1562.eurprd05.prod.outlook.com] SMTP code: 550

Just put the same “From” address as the email address you’re configuring, and the server will accept it for sure.

Hi,

Is the problem with sending emails through a user email (office 365 Smtp mail server) solved already? Version: Version SuiteCRM 7.10.10, Sugar Versie 6.5.25 (Maken 344).

We use Office 365 for exchange. The system email works fine and users can send email through the system email account. But we also want users to send email with their personal account. When a user creates a outgoing SMTP mail server with his own user account (email address) and from field is filled with the email address, and sends a test e-mail in de ‘outgoing mail server properties’, it works fine. But when an email is send from the module emails whereby from field is filled with the user account (SMTP) is gives an error (Error Sending Email. Please contact your administrator for assistance.).
In the system email settings Users may send as themselves is enabled.

Please advise. thanks in advance.

Hello Damo,

I tried all suggestions above and updates also but problem does not resolved.

We are using only one emal address for outgoing emails.

Maybe something is wrong in SugarPHPMailer.php but i do not know what…

Please try this workaround to see if it helps:

https://suitecrm.com/suitecrm/forum/suitecrm-7-0-discussion/20055-outbound-email-unable-to-set-up-properly#74208

and give us your feedback afterwards. Thanks

That solution means that I’ve to put my business (personal) office 365 account stored in suitecrm? Is that safe?

it is as safe as your SuiteCRM installation is safe. It depends on how you keep your server, your password policies, user education, etc.

But I wouldn’t call this a “solution”, I called it a “workaround”… a better fix needs to come.

Note that not all fixes should be expected from SalesAgility, since that is literally impossible. Sometimes there needs to be someone in the Community that pays a PHP developer for a couple of days work to improve something that is needed for their company, and then contributes that to the entire Community.

When many people do that, we all win.

I’ve been having the same issues as most people on this topic thread: email servers are configured and tested successfully but when I try and send an email after clicking on a contract’s email address, I get an error stating, “Error Sending Email. Please contact your administrator for assistance…”

Just upgraded SuiteCRM to 7.11.0 which alone did not fix the problem, but I was able to get email working by clicking the box in Admin>Email Setting labelled “Users may send as themselves”. I successfully sent an email and it worked! FINALLY!

Hope this helps someone else.

:evil:
This bug still exists !!
Fix it - or SuiteCRM is useless and will die!
IT Gurus from the provider siteground tried to fix it in this way:

The issue is caused due to a bug in the current version of Suitecrm’s PHP mailer class script which causes the sender and recipient of each test message to be the same.

The only fix for the current version is to edit the script /include/SugarPHPMailer.php and uncomment the line numbers between 453 to 455, and add the needed sender credentials in them.

Doing similar test has brought the desired results as shown from the full test headers below:

Code:
Return-Path: institut@justizopfer-hilfe.at
Delivered-To: sgtest@justizopfer-hilfe.at
Received: from uk45.siteground.eu
by uk45.siteground.eu with LMTP id iKQ3GUTSW1w5bAAA8XWnnA
for sgtest@justizopfer-hilfe.at; Thu, 07 Feb 2019 06:37:56 +0000
Return-path: institut@justizopfer-hilfe.at
Envelope-to: sgtest@justizopfer-hilfe.at
Delivery-date: Thu, 07 Feb 2019 06:37:56 +0000
Received: from [77.104.173.243] (port=45908 helo=indoor-architecture.co.uk)
by uk45.siteground.eu with esmtpa (Exim 4.89_34-9f6032f-XX)
(envelope-from institut@justizopfer-hilfe.at)
id 1grdJs-0007Ch-Ad
for sgtest@justizopfer-hilfe.at; Thu, 07 Feb 2019 06:37:56 +0000
Date: Thu, 7 Feb 2019 00:37:56 -0600
To: sgtest@justizopfer-hilfe.at
From: SGTest institut@justizopfer-hilfe.at
Subject: Test Email from SuiteCRM
Message-ID: 80e0d1a46355b7b32c40112ef21d5f49@indoor-architecture.co.uk
X-Mailer: PHPMailer 5.2.25 (https://github.com/PHPMailer/PHPMailer)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: quoted-printable
SG-Abuse: user, USERNAME=indoora7 SENDER_HOST=77.104.173.243 MAIL=institut@justizopfer-hilfe.at

This email was sent in order to test the outgoing mail server information p=
rovided in the SuiteCRM application. A successful receipt of this email ind=
icates that the outgoing mail server information provided is valid.

The actual bug report can be seen in the following article:

https://suitecrm.com/suitecrm/forum/suitecrm-7-0-discussion/19208-can-t-send-email-from-users-email-addresses-urgent-please-help

The fully updated code can be seen in the link below.

Unfortunately at this point, it is not compatible with the other SMTP classes of your application:

[url]https://github.com/salesagility/SuiteCRM/blob/46a9b2190347e2bdb2e3b29ae98fd087c3f477c5/include/SugarPHPMailer.php[.url]

You see, this bug needs a urgent fix.

Emails are the core of any CRM !

@Jog thanks for that report.

Is that on 7.11.0 or 7.11.1?

And did you re-create the accounts on the new version?

I ask because I am convinced this bug is already fixed, but I would like to further understand if it is a bug in the account creation code, you might have a left-over broken account in your database.

When I am debugging I usually try to keep an eye on the database itself, tables “outbound_email” and “inbound_email”, this usually provides valuable insights.

I’m having the same issue. How or what are you using to get around this?

With the 7.11.8, I can’t check the User may send as themselves. This checkbox is never saved.

To make it works I have to :

  • Uncheck “users may send as this account identity”
  • Create users incoming mails and configure smtp
  • Connect to user account with his login (important)
  • Go to his profile and associate his smtp account. The admin account destroy this association if I edit it as Administrator. The problem is that email doesn’t have a Sender Name, because the sender same can only be set up by the administrator, it’s the email that is display instead of the name, but I don’t find another solution now.

That’s not the ideal solution but it works for my users now.

@metfab can you please open a new Issue on Github with this description of the problem?

https://github.com/salesagility/SuiteCRM/issues/

We need to get that fixed. Thanks for reporting.

this and the following are related but were these merged into any releases?

1 Like

Having the same problem myself. Hopefully fundamental issues like this will be addressed in updates prior to SuiteCRM v8 being released as no doubt there will be other issues with the new release.

1 Like

This could be a little late.

I just tested this issue and it seems working for me.

  1. Go to administration > Email Settings > setup the email server (Mine is an exchange server).
  2. Make sure the “Users may send as themselves” checkbox is ticked.
  3. Go to User profile, and add in the mail server login detail. Mine is IMAP.
  4. Go to email module > compose. There is from drop down where i can select my email as the sender.

It seems to me this issue has been fixed in 7.11.15