• DevOps
    Case Study

    How we built a resilient multi-account, multi-cloud solution for a Health Tech service provider!

    READ CASESTUDY
    icon

    24/7 DevOps as a Service

    Round-the-clock DevOps for uninterrupted efficiency.

    icon

    Infrastructure as a Code

    Crafting infrastructure with ingenious code.

    icon

    CI/CD Pipeline

    Automated CI/CD pipeline for seamless deployments.

    icon

    DevSecOps

    Integrated security in continuous DevOps practices.

    icon

    Hire DevOps Engineers

    Level up your team with DevOps visionaries.

    icon

    Consulting Services

    Navigate success with expert DevOps consulting.

  • TechOps
    Case Study

    How we built a scalable Odoo solution for a Travel Tech service provider!

    READ CASESTUDY

    WEB HOSTING SUPPORT

    icon

    HelpDesk Support

    Highly skilled 24/7 HelpDesk Support

    icon

    Product Support

    Boost your product support with our expertise.

    MANAGED SERVICES

    icon

    Server Management

    Don’t let server issues slow you down. Let us manage them for you.

    icon

    Server Monitoring

    Safeguard your server health with our comprehensive monitoring solutions.

    STAFF AUGMENTATION

    icon

    Hire an Admin

    Transform your business operations with our expert administrative support.

    icon

    Hire a Team

    Augment your workforce with highly skilled professionals from our diverse talent pool.

  • CloudOps
    Case Study

    How we helped a Private Deemed University in India, save US $3500/m on hosting charges!

    READ CASESTUDY
    icon

    AWS Well Architected Review

    Round-the-clock for uninterrupted efficiency

    icon

    Optimize

    Efficient CloudOps mastery for seamless cloud management

    icon

    Manage

    Automated CI/CD pipeline for seamless deployments

    icon

    Migrate

    Upgrade the journey, Migrate & Modernize seamlessly

    icon

    Modernize

    Simplify compliance complexities with our dedicated services

    icon

    FinOps as a Service

    FinOps as a Service

  • SecOps
    Case Study

    How we built a scalable Odoo solution for TravelTech service provider!

    READ CASESTUDY
    icon

    VAPT

    Vulnerability Assessment and Penetration Testing

    icon

    Source Code Review

    Ensuring source code security ans safe practices to reduce risks

    icon

    Security Consultation

    On demand services for improving server security

    icon

    System Hardening

    Reduced vulnerability and proactive protection

    icon

    Managed SoC

    Monitors and maintains system security. Quick response on incidents.

    icon

    Compliance as a Service

    Regulatory compliance, reduced risk

  • Insights
    Case Study

    How we helped a Private Deemed University in India, save US $3,500/m on hosting charges!

    READ CASESTUDY
    icon

    Blog

    Explore our latest articles and insights

    icon

    Case Studies

    Read about our client success stories

    icon

    Flipbook

    Explore our latest Flipbook

    icon

    Events

    Join us at upcoming events and conferences

    icon

    Webinars

    Watch our educational webinar series

  • Our Story
  • Contact Us

Interested to collaborate?

Get in touch with us!

Ready to elevate your business with certified cloud expertise? Contact us today to learn how our team can help you leverage cloud technology to drive growth, streamline operations, and enhance security.

  • AWSAWS
  • Azure CloudAzure Cloud
  • Google CloudGoogle Cloud
  • Akamai CloudAkamai Cloud
  • OVHOVH
  • Digital OceanDigital Ocean
  • HetznerHetzner
  • Kubernetes Consultancy Services
  • K8s & Cloud native Solutions
  • 24/7 Infrastructure Monitoring
  • DevOps as a Service
  • Cloud CI/CD Solutions
  • White Labeled MSP Support
  • Our story
  • Life@SupportSages
  • Insights
  • Careers
  • Events
  • Contact Us

Connect with us!


LinkedInFacebookXInstagramYouTube

aws partneraws advanced partner
SupportSages

Copyright © 2008 – 2026 SupportSages Pvt Ltd. All Rights Reserved.
Privacy PolicyLegal TermsData ProtectionCookie Policy
Custom Email Filtering across cPanel Server

Custom Email Filtering across cPanel Server

Albert Reilly

  • 4 min read
Custom Email Filtering across cPanel Server

Generating audio, please wait...

Using a custom filter with custom rules to discard emails considered spam across the whole server.

HOWTO

Exim uses a global file to set filters for all the accounts in a server, but they contain just some default rules. We can add new rules to this file and make filters to work across the server.

Filters are usually setup using cPanel>>Global Filters but this is used only for filtering mails to that particular account. The filters created via cPanel is saved in /etc/vfilters directory.

So we can use the Global Filter in cPanel to generate these rules and then add these to the global file so that the change is available across the server. Below I will explain in detail on how to do this.

Below I will explain how the rules for filtering were created.

1. Log into cPanel >> Global Filters
2. Create a Filter

Global Filters

3. test1 filter for attaining ‘Spam status -> begins with -> Yes -> Discard‘

Global Filters
4. test2 filter for attaining ‘Spam bar -> contains -> ++++++ -> Discard‘

Global Filters

Now the rules created for these filters in the file /etc/vfilters/example.com is fetched and it is as below.

# Exim filter # Auto Generated by cPanel.  Do not manually edit this file as your changes will be overwritten.  If you must edit this filter, edit the corresponding .yaml file as well. if not first_delivery and error_message then finish endif #test1 if  $h_X-Spam-Status: begins "Yes" then  save "/dev/null" 660 endif #test2 if  $h_X-Spam-Bar: contains "++++++" then  save "/dev/null" 660 endif

Now the above snippet for filtering mails is now made global across the server by adding it to the file /etc/cpanel_exim_system_filter which is the file that exim checks for filtering contents.

Goto WHM >> Exim Configuration Manager and click Filters

Now we can see the used default file as below.

Now we make a new custom file via backend for this so that the filters are preserved even after any updates.

We copy the default file to a new file to keep the existing settings as well and then add the custom rules to it.

cp -a  /etc/cpanel_exim_system_filter /etc/cpanel_exim_system_filter_custom

Now we add the above snippet to the newly created file ‘/etc/cpanel_exim_system_filter_custom‘

Then the Exim Configuration Manager setting is changed to use this new file as below.

Now the filter is made global across the server.

Hope you enjoyed ! (smile)

  • cPanel
  • Email service

Building up a WordPress website with AWS – PART 1

Building up a WordPress website with  AWS – PART 1
  • Apache
  • VPS
logo

Building up a WordPress website with AWS – PART 2

Building up a WordPress website with AWS – PART 2
  • Apache
  • VPS
logo

Building up a WordPress website with AWS – PART 3

Building up a WordPress website with AWS – PART 3
  • Apache
  • VPS
logo

Building up a WordPress website with AWS – PART 4

Building up a WordPress website with AWS – PART 4
  • WordPress
logo

Posts by Albert Reilly

Albert likes to explore and learn new things. He is hardworking, enthusiastic and is getting expertise in Linux administration, Networking and Security areas. He understands client requirements and is able to act accordingly. He has been working for 2 years with us.