Block entire top level domain

Discussion in 'Installation/Configuration' started by firepages, Jan 31, 2022.

  1. firepages

    firepages New Member

    Hi, I want to block an entire TLD in global filters, I found an old thread which suggested the following regex
    /<.+?@.+?\.online>/
    but that appears to be ignored, any other methods ?
     
  2. Taleman

    Taleman Well-Known Member HowtoForge Supporter

  3. firepages

    firepages New Member

    Hi Cheers, not sure where the thread was but it uses the same regex as in that tutorial which is not - for me at least - working.
     
  4. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    The tutorial has comments where regex is discussed and commenters claim to have better versions.
    There are regex testers in the Internet, websites with regex test tool, for example https://regex101.com/ . More websites can be found using Internet Search Engines.
     
  5. firepages

    firepages New Member

    The regex
    \^*.online$
    works in the regex validator, so trying that now.
     
  6. firepages

    firepages New Member

    ... and similarly does not work ... does anyone have any examples of a working format they are using in the global content filter ? even if it is for different rules ?
     
  7. Jesse Norell

    Jesse Norell Well-Known Member Staff Member Howtoforge Staff

    I think that is a working example in the tutorial you looked at. What is the exact header you are trying to match?
     
  8. firepages

    firepages New Member

    Hi, I want to block all incoming email from the .online TLD , not interested in domain part etc just the whole TLD.
     
  9. ahrasis

    ahrasis Well-Known Member HowtoForge Supporter

    May I know why you are not just using closely to the one suggested like:
     
    firepages likes this.
  10. firepages

    firepages New Member

    because I did not know it ~...
    but it works so many thanks!
     

Share This Page