Create an Exchange rule

Posted on 2014-08-22
Last Modified: 2014-09-05
I think what I want to do is quite straightforward but I can't see the how to implement it.

We have some emails coming in to our exchange server from an external source that are duplicates of messages we already have, these are generated from a server outside our control so we can't stop them but they all have INTERNAL at the start of the subject line.

Quite simply what I want to do is get exchange to not delivery / delete any messages where the subject line starts INTERNAL but not any message that contain INTERNAL. So for example 'INTERNAL abc' would be deleted but 're: INTERNAL abc' wouldn't.

I thought I could implement this as a hub transport rule but I can only get that to work when the whole subject line matches, how do I enter INTERNAL followed by a wildcard?
Question by:Dave Robinson
    LVL 35

    Accepted Solution

    You should be able to accomplish this task using the transport rule called

    "When the subject field matches text pattern"

    This option allows you to use a regular expression to create the filter which is used to bounce back the message. I have done this in the past however I did have to reach out for help with the regular expression creation.
    LVL 34

    Assisted Solution

    by:Terry Woods
    The regular expression pattern will likely work is:

    Open in new window

    The ^ matches the start of the string.

    If you also require a space character after the word, you can append that onto the end of the pattern.

    This advice is based on my experience with regular expressions; not on any experience working with Exchange. However, that pattern syntax is very standardised between languages and tools, so you're unlikely to have trouble with it.
    LVL 2

    Author Comment

    by:Dave Robinson
    Sorry for the delay in responding, everything went pretty crazy and I didn't have chance to test out the solution. Have given it a try now and it looks like its working so thank you to both of you for your help.

    Featured Post

    What Security Threats Are You Missing?

    Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

    Join & Write a Comment

    Find out how to use dynamic social media in email signatures with this top 10 DOs & DON’Ts.
    Granting full access permission allows users to access mailboxes present in their database. By giving full access permission one can open and read the content of any mailbox but cannot send emails from that mailbox.
    In this video we show how to create a User Mailbox in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Recipients >> Mailb…
    In this video we show how to create a Resource Mailbox in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: Navigate to the Recipients >> Resources tab.: "Recipients" is our default selection …

    728 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    24 Experts available now in Live!

    Get 1:1 Help Now