sending email with TLS auth

Support questions about the Threshold plugin

Moderators: Developers, Moderators

Post Reply
masscrx
Posts: 1
Joined: Tue Aug 16, 2011 8:43 am

sending email with TLS auth

Post by masscrx »

Hi!
I have cacti 0.8.7g with Plugin Architecture Version: 2.8. I want send email notification by SMTP server of php mail() function, but i have account on outlook.com where is TLS authentication, when i try to send test email from cacti i got this error:

Checking Configuration...
Method: SMTP
Creating Message Text...

This is a test message generated from Cacti. This message was sent to test the configuration of your Mail Settings.

Your email settings are currently set as follows

Method: SMTP
Host: amsprd0402.outlook.com
Port: 587
Authenication: true
Username: mailer@akademiasztuki.eu
Password: (Not Shown for Security Reasons)

Sending Message...

ERROR: SMTP Host does not appear to support authenication: 504 5.7.4 Unrecognized authentication type
SMTP Host does not appear to support authenication: 504 5.7.4 Unrecognized authentication type


I tried to edit /usr/share/cacti/site/plugins/settings/include/mailer.php by adding on line 735 this: fputs($smtp_sock, "STARTTLS\r\n"); :

Code: Select all

/* Perform Authenication - If username and password set */                                                                           
if ((! empty($this->Config["Mail"]["SMTP_Username"])) && (! empty($this->Config["Mail"]["SMTP_Password"]))) {                        
fputs($smtp_sock, "STARTTLS\r\n"); <-- i add this                                                                                                                 
fputs($smtp_sock, "AUTH LOGIN\r\n");                                                                                         
$smtp_response = fgets($smtp_sock, 4096);                                                                                    
if (substr($smtp_response,0,3) != "334") {                                                                                   
$this->Error = "SMTP Host does not appear to support authenication: " . $smtp_response;                              
fclose($smtp_sock);                                                                                                  
return false; 
But adding this doesnt help :(

Any idea?
User avatar
TheWitness
Developer
Posts: 17007
Joined: Tue May 14, 2002 5:08 pm
Location: MI, USA
Contact:

Re: sending email with TLS auth

Post by TheWitness »

I believe that there may be some handshaking required. Please log a bug and include the detail from this post at http://bugs.cacti.net
True understanding begins only when we realize how little we truly understand...

Life is an adventure, let yours begin with Cacti!

Author of dozens of Cacti plugins and customization's. Advocate of LAMP, MariaDB, IBM Spectrum LSF and the world of batch. Creator of IBM Spectrum RTM, author of quite a bit of unpublished work and most of Cacti's bugs.
_________________
Official Cacti Documentation
GitHub Repository with Supported Plugins
Percona Device Packages (no support)
Interesting Device Packages


For those wondering, I'm still here, but lost in the shadows. Yearning for less bugs. Who want's a Cacti 1.3/2.0? Streams anyone?
User avatar
rony
Developer/Forum Admin
Posts: 6022
Joined: Mon Nov 17, 2003 6:35 pm
Location: Michigan, USA
Contact:

Re: sending email with TLS auth

Post by rony »

The SMTP mailer doesn't currently support TLS.

Do put a bug in.
[size=117][i][b]Tony Roman[/b][/i][/size]
[size=84][i]Experience is what causes a person to make new mistakes instead of old ones.[/i][/size]
[size=84][i]There are only 3 way to complete a project: Good, Fast or Cheap, pick two.[/i][/size]
[size=84][i]With age comes wisdom, what you choose to do with it determines whether or not you are wise.[/i][/size]
splinter510
Posts: 1
Joined: Wed Nov 19, 2014 11:34 am

Re: sending email with TLS auth

Post by splinter510 »

Long time fan of Cacti, but new member here.

Was wondering if the issue with the SMTP mailer using TLS ever was addressed?
kkuma
Posts: 2
Joined: Fri Jan 02, 2015 1:11 am

Re: sending email with TLS auth

Post by kkuma »

I think its not supports yet. If TLS or SSL can support, please let me know. Stuck with email alert thing for days.
User avatar
phalek
Developer
Posts: 2838
Joined: Thu Jan 31, 2008 6:39 am
Location: Kressbronn, Germany
Contact:

Re: sending email with TLS auth

Post by phalek »

I think the next Cacti version is going to include an advanced "settings" plugin using the PHPMailer addon. This one does indeed support TLS then.
Greetings,
Phalek
---
Need more help ? Read the Cacti documentation or my new Cacti 1.x Book
Need on-site support ? Look here Cacti Workshop
Need professional Cacti support ? Look here CereusService
---
Plugins : CereusReporting
kkuma
Posts: 2
Joined: Fri Jan 02, 2015 1:11 am

Re: sending email with TLS auth

Post by kkuma »

Hello Guys,

Just an update. I managed to send email with ssl. The problem I had was with SELINUX. After set to permissive, it worked.
On tls option, iam still having a trouble because email server responds as "synchronization error".

Cheers
williambonomo
Posts: 1
Joined: Mon Jul 27, 2015 2:49 pm

Re: sending email with TLS auth

Post by williambonomo »

TLS aut was released?
flooreus
Posts: 22
Joined: Fri Nov 07, 2014 8:55 am

Re: sending email with TLS auth

Post by flooreus »

All,

I was just wondering if there has been any movement on having TLS authentication enabled in Cacti?

If not, is there any way I will be able to use SMTP to send e-mails using publicly-available SMTP servers? These e-mails do not need to be particularly secure as no sensitive information is being transmitted, so if anyone can help that'd be appreciated. I've tried a few, but none of them seem to work. As SSL support is being dropped more and more it's getting harder to find one that doesn't only support TLS :(

Regards,

Tom
Post Reply

Who is online

Users browsing this forum: No registered users and 4 guests