Closed GrayFox14048 closed 1 year ago
As described by m2hd in https://forums.cacti.net/viewtopic.php?p=252897, mactrack it's enable to send email again! Follow that guide, works for me
Can you do a pull request with your change?
done! Anyway I'm new here, I'm not sure that's the right way to do that
I use mactrack 4.5 with Cacti1.2.23 and I get macauth notification emails without any modification required.
Okay, a little more information on my findings. If using a single email address it works as expected. If using 2 email addresses like user1@mydomain.com;user2@mydomain.com without a space after the semicolon you get the following
2023/01/10 13:41:02 - CMDPHP MAILER ERROR Backtrace: (/plugins/mactrack/poller_mactrack.php[229]:collect_mactrack_data(), /plugins/mactrack/poller_mactrack.php[856]:mactrack_mail(), /plugins/mactrack/lib/mactrack_functions.php[3138]:mailer(), /lib/functions.php[4848]:record_mailer_error(), /lib/functions.php[5049]:cacti_debug_backtrace())
2023/01/10 13:41:02 - CMDPHP MAILER ERROR: Invalid address: (to): user1@mydomain.com;user2@mydomain.com
If using 2 email addresses like user1@mydomain.com; user2@mydomain.com with a space after the semicolon you see success in the log like
2023/01/10 09:40:52 - MAILER INFO: Mail successfully sent via Sendmail from 'Cacti MACTrack <cacti@mydomain.com>', to 'user1@mydomain.com; <user2@mydomain.com>', cc '', and took 0.08 seconds, Subject 'MACAUTH Notification: Mac Address 'D4:81:D7:48:88:4F' Found, For: 'Dan Testing''
In this case only user2 receives an email.
Also the help tooltip reads "Enter a semicolon separated of email addresses" missing the word list. :)
I think they are supposed to be comma delimited. Read the help and get back to me.
Also the help tooltip reads "Enter a semicolon separated of email addresses" missing the word list. :)
Looks like a real bug. Something changed obviously.
Should be fixed now.
With the SMTP mail configured and tested in cacti settings, mactrack doesn't send any mail, or any error in log