Export (0) Print
Expand All

How to Create an E-Mail Address Policy By Using Recipient Filters

 

Applies to: Exchange Server 2007 SP3, Exchange Server 2007 SP2, Exchange Server 2007 SP1, Exchange Server 2007

Topic Last Modified: 2007-01-30

This topic explains how to use the Exchange Management Shell to create an e-mail address policy by using recipient filters. To learn more about e-mail address policies, see Understanding E-Mail Address Policies.

noteNote:
You cannot use the Exchange Management Console to create an e-mail address policy by using recipient filters. You must use the Exchange Management Shell.

To perform this procedure, 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 this procedure, be aware of the following:

  • Before a Simple Mail Transfer Protocol (SMTP) address domain can be used in an e-mail address policy, you must configure an accepted domain. For information about configuring accepted domains, see Managing Accepted Domains.

  • To use the RecipientFilter parameter to create a custom filter, you must specify a string for the filter. The Exchange Management Shell uses OPath for the filtering syntax. OPath is a querying language designed to query object data sources. For more information about the OPath filtering syntax, see Creating Filters in Recipient Commands.

importantImportant:
If you use a recipient filter to create or edit an e-mail address policy, you cannot use the Exchange Management Console to edit the e-mail address policy. You must use the Set-EmailAddressPolicy in the Exchange Management Shell. For detailed syntax parameter information, see Set-EmailAddressPolicy.

  • Run the following command:

    New-EmailAddressPolicy -Name <String> -RecipientFilter <String>
    

    For example, to create an e-mail address policy that applies to all executives and for which the local part of the e-mail address consists of the first two letters of their first name and their entire last name, run the following command.

    New-EmailAddressPolicy -Name 'Execs' -EnabledEmailAddressTemplates 'SMTP:%2g%s@contoso.com' -RecipientFilter {((RecipientType -eq 'UserMailbox') -and (Title -like 'executive'))}
    

For detailed syntax and parameter information, see the New-EmailAddressPolicy reference topic.

To learn more about e-mail address policies, see Understanding E-Mail Address Policies.

For more information about managing e-mail address policies, see Managing E-Mail Address Policies.

For more information about accepted domains, see the following topics:

 
Was this page helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft