disable PHPMailer ( Biggest Spammer point )

 

PHPMailer ( Biggest Spammer point )


How to disable PHPMailer sending functionality if email not authenticated like if no correct inbox, user name and password, No email will go out of server ?

In my honest opinion, if your users are spamming using mail() function, its time to suspend them unless your sites are hacked and hackers are using the function to send out spam emails.

But if you want to disable users from using mail(), you can do the following.

To simply disable mail() function in php you can edit your php.ini, then add the following line/ find the line:

Go to:


/usr/local/lsws/lsphp74/etc/php/7.4/litespeed/php.ini

add this in last


disabled_functions = mail


You can do it for the global php.ini and it should be disabled for your users.

Just head to https://host.example.com:8090/managephp/editPHPConfigs 5 and edit the advanced php config there.



Please confirm the last query, after this, user able to use SMTP with authentication to send mails if required in the application.

Above setting only disable unauthenticated mail from the server.


Yes they would have to use smtp to send mail.


Don’t forget to restart litespeed after.

systemctl restart openlitespeed



Comments

Popular posts from this blog

cpanel exam CPSP Answers

How to install zimbra collaboration suite 8.8.11 on CentOS 7

awstats installation