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!

Add Forwarder Hook - How to block?

Discussion in 'cPanel Developers' started by saad92, Jan 31, 2018.

Tags:
  1. saad92

    saad92 Member

    Joined:
    Apr 22, 2016
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Earth
    cPanel Access Level:
    Root Administrator
    Hi,

    I am trying to use the add_forwarder hook to block addition of forwarders to email addressing ending with gmail.com. I am able to execute the hook and process the data as well but the only problem is that it is not blocking the creation of email forwarders. In the code I am returning false as the first argument and a message as the second argument but still the forwarder is being added. Can you please help me confirm if blocking is not enabled on creation of email forwarders?

    Regards,
    Saad
     
  2. saad92

    saad92 Member

    Joined:
    Apr 22, 2016
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Earth
    cPanel Access Level:
    Root Administrator
    I actually wanted to reply to this post but that thread is over a year old. If any moderator can merge the threads it would make more sense.
     
  3. saad92

    saad92 Member

    Joined:
    Apr 22, 2016
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Earth
    cPanel Access Level:
    Root Administrator
    This is so frustrating - I wanted to add my code and edited the whole post but at the end it said my message is spam-like and can not be posted. Is this the case with everyone or I am too new to even post a legitimate message?
     
  4. cPanelKenneth

    cPanelKenneth cPanel Development
    Staff Member

    Joined:
    Apr 7, 2006
    Messages:
    4,563
    Likes Received:
    42
    Trophy Points:
    308
    cPanel Access Level:
    Root Administrator
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  5. saad92

    saad92 Member

    Joined:
    Apr 22, 2016
    Messages:
    5
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Earth
    cPanel Access Level:
    Root Administrator
  6. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    44,378
    Likes Received:
    1,857
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello @saad92,

    I'm not aware of any method to achieve the functionality you are seeking because, as mentioned in the earlier post, the blocking attribute of the hook system is not supported when using cPanel API calls.

    Note we do have a feature request open for this at:

    option to prevent forwarders to free email accounts

    I encourage you to vote and add feedback to this request if you'd like to see it implemented.

    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