Come and Check our BETA Alpha version of Powershellcenter.net
Send me your comment to Powershell@powershellcenter.com

Synopsis

Sets the configuration options for the spam content filter.

Syntax

Set-FseSpamContentFilter [-AllowedRecipient <string[]>] [-AllowedSender <string[]>] [-AllowedSenderDomain <string>] [-Enabled <Boolean>] [-EnableStatisticsUpload <Boolean>] [-RejectionResponse <string>] [-SpamAction <SpamActionEnum>] [-SuspectAction <SuspectActionEnum>] [-Threshold <int>] [<CommonParameters>]

Detailed Description

Sets the configuration options for the spam content filter. The spam content filter analyzes the content of a message to determine if it is spam. When a message is analyzed by the spam content filter, it is assigned a Spam Confidence Level (SCL) score that indicates the likelihood that the message is spam. Use the -Threshold parameter to adjust the SCL score threshold at which the message is considered "suspect" or "spam". Use the -SuspectAction and -SpamAction parameters to specify how the spam content filter should treat suspect messages and spam messages. NOTE: Various access permissions must be set on Exchange and Active Directory resources before the spam content filter can be used. These are set using the Set-FseSpamFiltering cmdlet, which also enables all spam features, including the the spam content filter. NOTE: The values for the parameters -AllowedRecipients, -AllowedSender, and -AllowedSenderDomain also exist in Microsoft Exchange Server. If you have similar values in similar lists in Exchange and wish to use them for the Microsoft Forefront Protection 2010 for Exchange Server (FPE) spam content filter, you must manually copy the lists from Exchange into FPE.

Parameters

-AllowedRecipient [<string[]>]

Lists the allowed recipients. Optional. If the recipient of a message is on this list, the message is stamped with an SCL score of -1 and delivered to the recipient. This parameter accepts an array of string values. Enter recipients as e-mail addresses, for example: manuel@fabrikam.com.

Required?   false
Position?   named
Default value?  
Accept pipeline input?   false
Accept wildcard characters?   false

-AllowedSender [<string[]>]

Lists the allowed senders. Optional. If the sender of an e-mail message is on this list, the message is stamped with an SCL score of -1 and delivered to the recipient. This parameter accepts an array of string values. Enter senders as e-mail addresses, for example: Fred@contoso.com.

Required?   false
Position?   named
Default value?   no value
Accept pipeline input?   false
Accept wildcard characters?   false

-AllowedSenderDomain [<string>]

Lists the allowed sender domains. Optional. When the domain of the sender of an e-mail is on this list, the message is stamped with an SCL score of -1 and delivered to the recipient. This parameter accepts an array of string values. Enter senders as domain names, for example: "contoso.com". Do not enter the domain name as, for example, "*.contoso.com"

Required?   false
Position?   named
Default value?   no value
Accept pipeline input?   false
Accept wildcard characters?   false

-Enabled [<Boolean>]

Enables the spam content filter. Optional. The possible values are $false and $true. The default of $false indicates that the spam content filter is disabled. The spam content filter requires various access permissions to be set on certain Exchange and Active Directory resources. The Set-FseSpamFiltering cmdlet sets these permissions and enables all spam features, including the the spam content filter. This parameter is used to turn the spam content filter on and off, but only after spam features have been enabled using the Set-FseSpamFiltering cmdlet.

NOTE: The Microsoft Exchange Transport service must be stopped and then started again for changes to this setting to take effect. Do not use the Restart function.

If the spam content filter is enabled, but the antispam engine is not enabled for automatic updates, you receive a warning message. You also receive a warning message if the spam content filter is disabled, but the antispam engine is still enabled for automatic updates.

Required?   false
Position?   named
Default value?   false
Accept pipeline input?   false
Accept wildcard characters?   false

-EnableStatisticsUpload [<Boolean>]

Specifies whether FPE should upload information about how the spam content filter is performing. Optional. This information is used to improve the spam content filter. The possible values are $false and $true. The default of $false means that statistics data are not sent. Set this value to $true to enable FPE to upload statistics.

Required?   false
Position?   named
Default value?   false
Accept pipeline input?   false
Accept wildcard characters?   false

-RejectionResponse [<string>]

Specifies the text of the message that FPE uses when rejecting e-mail that is determined by the spam content filter to be spam. Optional. Forefront rejects a message as spam when its SCL score is greater than or equal to the value set with the -Threshold parameter and the -SpamAction parameter has a value of "Reject". The default value is: "Message rejected due to content restrictions". The response text has a maximum length of 240 characters.

NOTE: The spam content filter automatically includes the SMTP machine-readable code "550 5.7.1" in the response.

Required?   false
Position?   named
Default value?   see description
Accept pipeline input?   false
Accept wildcard characters?   false

-SpamAction [<SpamActionEnum>]

Specifies the action to take on messages that are determined to be spam, based on their SCL score and the value of the -Threshold parameter. Optional. The possible values are Reject and Delete.

The default action of "Reject" causes the spam message to be rejected. The sender of the message receives a response that includes the message specified in the -RejectionResponse parameter.

If the action is set to "Delete", the spam message is deleted and the sender of the message does not receive a response.

Required?   false
Position?   named
Default value?   Reject
Accept pipeline input?   false
Accept wildcard characters?   false

-SuspectAction [<SuspectActionEnum>]

Specifies the action to take on messages that are determined to be suspect, based on their SCL score and the value of the -Threshold parameter. Optional. The possible values are Quarantine and Deliver.

The default value is "Quarantine", meaning that FPE quarantines the suspect message.

A -SuspectAction value of "Deliver" means that the message is stamped with its SCL score and delivered to Exchange. Outlook downloads the message and rescans it to determine if it should be placed in the junk mail folder.

Required?   false
Position?   named
Default value?   Quarantine
Accept pipeline input?   false
Accept wildcard characters?   false

-Threshold [<int>]

Specifies the Spam Confidence Level (SCL) threshold for determining if messages are suspected to be spam or most likely are spam. Optional. Every message that is scanned by the spam content filter is assigned an SCL score. The possible value of the threshold is an integer between 4 and 9. The default value is 8.

Messages that receive an SCL score above or equal to the threshold value are treated as spam. They are rejected or deleted, depending on the value of the -SpamAction parameter.

Messages that receive an SCL score greater than 4 but less than the threshold value are treated as suspect. They are quarantined or delivered, depending on the value of the -SuspectAction parameter.

Messages that receive a score less than 5 are treated as legitimate messages. They are stamped with an SCL score of -1 to ensure that they are not rescanned by Outlook, and are delivered to the recipient.

Required?   false
Position?   named
Default value?   8
Accept pipeline input?   false
Accept wildcard characters?   false

Input Type

Return Type

Notes

Examples

EXAMPLE 1

PS> Set-FseSpamContentFilter -Threshold 7 -SpamAction Delete -SuspectAction Quarantine -AllowedSenderDomain contoso.com -AllowedSender Fred@fabrikam.com,Herbie@fabrikam.com -Enabled $true There is no output if the command completes successfully.

Description

-----------

Enables the spam content filter. Sets the threshold to 7, the SpamAction to "Delete", and the SuspectAction to "Quarantine". Contoso.com is specified as an allowed sender domain, and two specific allowed senders are listed.