Applies to: Exchange Server 2007 SP3, Exchange Server 2007 SP2, Exchange Server 2007 SP1, Exchange Server 2007
Topic Last Modified: 2007-01-02

This topic explains how to use the Exchange Management Shell to configure anti-spam features on a mailbox. All messages that come into the Exchange organization from the Internet are filtered by the anti-spam agents that are enabled on the Edge Transport server. As the messages are filtered, metadata is added to the messages.

Legitimate messages that have not been filtered are delivered to the recipient's mailbox.

Before You Begin

To perform the following procedures, the account you use must be delegated the following:

  • Exchange Organization Administrator role

For more information about permissions, delegating roles, and the rights that are required to administer Microsoft Exchange Server 2007, see Permission Considerations.

Also, before you perform these procedures, confirm the following:

Procedure

This section explains how to use the Exchange Management Shell to configure the anti-spam features on a mailbox. You use the following parameters to configure anti-spam features with the Set-Mailbox cmdlet: 

  • AntispamBypassEnabled

  • SCLDeleteEnabled

  • SCLDeleteThreshold

  • SCLJunkEnabled

  • SCLJunkThreshold

  • SCLQuarantineEnabled

  • SCLQuarantineThreshold

  • SCLRejectEnabled

  • SCLRejectThreshold

For detailed syntax and parameter information, see Set-Mailbox.

Note:
With the exception of the junk e-mail settings, the spam confidence level (SCL) settings on the mailbox are the same as the settings that you apply on the Content Filter agent. The content filtering settings are applied to the organization. The mailbox settings are applied to the individual mailbox user. The mailbox settings override the organization-wide content filtering settings.
Note:
The SCLDeleteEnabled, SCLJunkEnabled, SCLQuarantineEnabled, and SCLRejectEnabled parameters have three possible values: $true, $false, and $null. If a parameter has the value of $true or $false, that parameter overrides the settings on the Content Filter agent. If the setting is $null, the settings on the Content Filter agent are applied.

To use the Exchange Management Shell to configure anti-spam features on a single mailbox

  • To configure all the anti-spam settings on a mailbox, run the following command:

    Copy Code
    set-Mailbox -Identity <MailboxIdParameter> -AntispamBypassEnabled <$true | $false> -RequireSenderAuthenticationEnabled <$true | $false> -SCLDeleteEnabled <$true | $false | $null> -SCLDeleteThreshold <Nullable> -SCLJunkEnabled <$true | $false | $null > -SCLJunkThreshold <Nullable> -SCLQuarantineEnabled <$true | $false | $null > -SCLQuarantineThreshold <Nullable> -SCLRejectEnabled <$true | $false | $null > -SCLRejectThreshold <Nullable>
    

    For example, to configure John Peoples' mailbox to bypass all the anti-spam filters and to have messages that meet or exceed an SCL Junk E-mail folder threshold of 5 delivered to his Junk E-mail folder in Microsoft Office Outlook, run the following command:

    Copy Code
    Set-Mailbox -Identity John -AntispamBypassEnabled $true -SCLJunkEnabled $true -SCLJunkThreshold 5
    

To use the Exchange Management Shell to configure anti-spam features on multiple mailboxes by using a piped command

  • Run the following command:

    Copy Code
    Get-Mailbox | Set-Mailbox
    

    For example, to enable the SCL quarantine threshold with a value of 7 on all mailboxes in the Users container in the Contoso.com domain, run the following command:

    Copy Code
    Get-Mailbox -OrganizationalUnit Contoso.com\Users | Set-Mailbox -SCLQuarantineEnabled $true -SCLQuarantineThreshold 7
    

To use the Exchange Management Shell to configure anti-spam features on multiple mailboxes by using the Set-OrganizationConfig cmdlet

  • Run the following command:

    Copy Code
    Set-OrganizationConfig -SCLJunkThreshold <Int32>
    

    For example, to set the organization's junk e-mail threshold to 5, run the following command:

    Copy Code
    Set-OrganizationConfig -SCLJunkThreshold 5
    
    Note:
    You can only configure the SCLJunkThreshold parameter by using the set-OrganizationConfig cmdlet.

For More Information

For more information about the SCL and content filtering, see the following topics:

For more information about how to manage mailboxes, see the following topics:

For more information about anti-spam features, see the following topics: