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!

Exim Blacklist -> *domain doesn't work

Discussion in 'E-mail Discussion' started by vagkaefer, Jun 22, 2015.

  1. vagkaefer

    vagkaefer Member

    Joined:
    Jun 25, 2014
    Messages:
    20
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    I have a manual filter in the exim. It was done this way:

    In section: "CONFIG". I put:

    domainlist exim_blacklist lsearch;/etc/eximblacklist

    In Section: "PREROUTERS". I put:

    driver = redirect
    # RBL Blacklist incoming hosts
    domains = +exim_blacklist
    allow_fail
    data = :fail: Connection rejected: SPAM source $domain is manually blacklisted.

    So I put a host in each line of the file /etc/eximblacklist. Works perfectly, the emails are blocked.

    But sometimes i need to use a "wildcard". For example, I like to block all senders of the .tk domains.

    I thought I'd use: * .tk

    But it does not work, how do I use the "wildcard"?
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  2. 24x7server

    24x7server Well-Known Member

    Joined:
    Apr 17, 2013
    Messages:
    1,787
    Likes Received:
    82
    Trophy Points:
    78
    Location:
    India
    cPanel Access Level:
    Root Administrator
    You can try to create your custom filter in your /usr/local/cpanel/etc/exim/sysfilter/options/ directory and try to enable it through WHM->Exim Configuration Manager->Basic Editor->Filters

    Create /usr/local/cpanel/etc/exim/sysfilter/options/inbound_tld_block file and add following code

    Code:
    if first_delivery
    and ("$h_to:, $h_cc:" contains ".tld")
    or ("$h_from:" contains ".tld")
    then
    seen finish
    endif
    To disable the filter, you can set it to “Off” in the WHM->Exim Configuration Manager->Basic Editor->Filters : "** Custom Filter: inbound_tld_block"
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
    vagkaefer likes this.
  3. vagkaefer

    vagkaefer Member

    Joined:
    Jun 25, 2014
    Messages:
    20
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Worked fine! Tks so much!
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  4. 24x7server

    24x7server Well-Known Member

    Joined:
    Apr 17, 2013
    Messages:
    1,787
    Likes Received:
    82
    Trophy Points:
    78
    Location:
    India
    cPanel Access Level:
    Root Administrator
    I am happy to see the issue is now resolved. Thank you for updating.
     
    Stop hovering to collapse... Click to collapse... Hover to expand... Click to expand...
  5. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

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

    Thank you for taking the time to let us know it worked. I'm marking this thread as resolved.
     
    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