Please whitelist cPanel in your adblocker so that you’re able to see our version release promotions, thanks!

The Community Forums

Interact with an entire community of cPanel & WHM users!

PHP Mail Configuration

Discussion in 'E-mail Discussion' started by VexTaylor, Feb 17, 2015.

  1. VexTaylor

    VexTaylor Registered

    Joined:
    Feb 17, 2015
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Hello all!

    I am fairly new to the administrative side of cPanel/WHM and could use some help understanding how (and if it's even possible) to do what I would like.

    I want to to disable PHP scripts (scripts using the mail() function and SMTP if possible) from sending messages externally, but still be able to send messages to internal email addresses. I thought I had read about this somewhere before, but decided I didn't need it at the time and have since been unable to relocate the place I read it.

    Email is being handled on the same server as the web hosting.

    I need the following to remain functional:
    • Email addresses need to be able to send and receive internally and externally.
    • PHP using the mail() function or SMTP need to be able to send internally to existing email addresses (or to forwards)
    • Some accounts are using dedicated IP addresses, so I will need to make sure they are able to send from their scripts internally as well

    I would greatly appreciate any assistance with this.
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    43,722
    Likes Received:
    1,794
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello :)

    I'm not sure it's possible to limit emails to internal addresses through PHP scripts, but to allow it for normal email accounts. You might be able to implement a custom Exim ACL, so you may want to post the Exim users mailing list to see if any other users have a similar configuration:

    Exim Users Mailing List

    Thank you.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
Loading...

Share This Page

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice