Register for Semperis' Hybrid Identity Protection (HIP) Conference - June 30 - July 1 Register for Semperis' Hybrid Identity Protection (HIP) Conference - June 30 - July 1
Exchange Server

Install / Uninstall Anti-Spam in Exchange 2007

In Exchange 2003 the Anti-Spam system is part of the exchange installation and can be enabled or disabled by marking the relevant component on the SMTP Virtual Server: https://petri.com/block_spam_with_exchange_2003.htm

Exchange 2007 is built differently and a new element called Edge was added in order to handle Spam and Viruses, and because of this the traditional Anti-spam system is not installed as a default during the Exchange 2007 installation.

When you are not installing the Edge server role as a mailrelay, but you still want to use the Anti-Spam system that that is part of Exchange 2007, you need to install it from a PowerShell script that was installed during the Exchange 2007 installation on the Hub transport role. To do this, follow the instructions listed below.

Installing Exchange 2007 Anti-spam system

  1. Close the EMC (Exchange Management Console).
  2. Open the PowerShell and navigate using the following path: “Program Files\Microsoft\Exchange Server\Scripts“.
  3. Run the “install-AntispamAgents.ps1” script as shown in window (with ./ before the script name) below:
  4. Restart the “Microsoft Exchange Transport” service in order to apply configuration changes.
  5. Open the Exchange Management Console, and on the Organization configuration list, select Hub Transport. The “Anti-Spam” tab has been added to the Hub Transport properties.

Uninstalling Exchange 2007 Anti-spam system

If from some reason, you would like to uninstall the Anti-Spam system from the Hub Transport role, follow the next steps:

  1. Close the EMC (Exchange Management Console).
  2. Open the PowerShell and navigate using the following path: “Program Files\Microsoft\Exchange Server\Scripts“.
  3. Run the “uninstall-AntispamAgents.ps1” script as shown in window (with ./ before the script name) below: Note: You will be prompt to disable and then uninstall each agent of the Anti-spam system like the Connection filtering, content filter, Sender filtering etc.
  4. Restart the “Microsoft Exchange Transport” service in order to apply configuration changes.
  5. Open the Exchange Management Console, and on the Organization configuration list, select Hub Transport. You will see that the “Anti-Spam” tab has been removed from the Hub Transport properties.

Related Topics:

Register for the Hybrid Identity Protection (HIP) Europe Conference!

Hybrid Identity Protection (HIP) Europe 2021 - Virtual Conference

Mobile workforces, cloud applications, and digitalization are changing every aspect of the modern enterprise. And with radical transformation come new business risks. Hybrid Identity Protection (HIP) is the premier educational forum for identity-centric practitioners. At the inaugural HIP Europe, join your local IAM experts and Microsoft MVPs to learn all the latest from the Hybrid Identity world.