Link to home
Start Free TrialLog in
Avatar of Svet Paperov
Svet PaperovFlag for Canada

asked on

Exchange 2010 Transport Rule BCC of message sent to specific accepted domain


I need some help with the transport rules.

We have Exchange 2010 (Hub, CAS, Mailbox on the same machine) with the following setup:
- Two accepted domains: and
- All users have addresses in, for example:
- Some users have addresses in and, for example and However, the Primary SMTP Address is always in, for example.

I am trying to configure a transport rule that does Bcc of all messages sent to regardless of the user but it doesn’t seem to work. For example:

New-TransportRule -Name "Bcc domain2" -RecipientAddressContainsWords '' -BlindCopyTo ''

will catch messages only if the Primary SMTP Address of the recipient is in But if is in, this transport rule will not catch the message.

I’ve also tried different variations of the same rule, with reg. expressions for example but it doesn’t seem possible.

Is there are any other way to achieve the same goal?
Avatar of Akhater
Flag of Lebanon image

another way to look at it is to add all these users to a distribution group and change your rule to sent to members of distribution group
of course the distribution group could be dynamic somehting like

New-DynamicDistributionGroup -Name "All domain2 Users" -Alias "AllDomain2Users" -RecipientFilter {((RecipientType -eq 'UserMailbox') -and (EmailAddresses -like 'smtp:*'))}

Open in new window

Avatar of Svet Paperov


Hello @Akhater,

Thanks for your help.

I’ve already thought about using a distribution group but it won’t work: it would catch messages sent to both domains and and not messages sent to only.

However, I gave a try of your second suggestion about using dynamic distribution group. The Cmdlet correctly populates (with a small modification) the group with users having as an address but the transport rule, created using this distribution group (condition: “Sent to a member of distribution list”) filters messages sent to both and domains.

I need to catch messages sent to only and not to

Thanks again  

The correct syntax for the cmdlet (skip smtp in EmailAddresses):
New-DynamicDistributionGroup -Name "All domain2 Users" -Alias "AllDomain2Users" -RecipientFilter {((RecipientType -eq 'UserMailbox') -and (EmailAddresses -like '*'))}

Open in new window

oh sorry you are perfectly that's the price of replying late at night !

do you have any kind of mail relay or anti-spam before your exchange box?
Yes, we have a hosted Google Postini but there is no much to do there and it does not rewrite the address.
well I was thinking maybe your antispam can add a custom header or something
Avatar of Svet Paperov
Svet Paperov
Flag of Canada image

Link to home
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
wow !

good to know there is a way for that

thanks for sharing
Found the answer myself