SOLVED
Home

Transport rule for encrypted messages

%3CLINGO-SUB%20id%3D%22lingo-sub-787528%22%20slang%3D%22en-US%22%3ETransport%20rule%20for%20encrypted%20messages%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-787528%22%20slang%3D%22en-US%22%3E%3CP%3EI'm%20trying%20to%20configure%20a%20mail%20flow%2Ftransport%20rule%20in%20Exchange%20Online%20to%20add%20a%20banner%20to%20incoming%20messages%20that%20are%20encrypted.%20During%20testing%2C%20the%20rule%20does%20not%20get%20triggered%2C%20even%20though%20the%20received%20message%20has%20an%20Outlook%20notification%20that%20the%20message%20is%20encrypted.%20My%20rule%20is%20using%20the%20%22if%20message%20type%20is%20encrypted%22%20condition%20to%20add%20a%20disclaimer%20(prepend).%20Does%20anyone%20know%20how%20this%20can%20successfully%20be%20achieved%3F%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-787528%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EExchange%20Online%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E%3CLINGO-SUB%20id%3D%22lingo-sub-787675%22%20slang%3D%22en-US%22%3ERe%3A%20Transport%20rule%20for%20encrypted%20messages%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-787675%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F3348%22%20target%3D%22_blank%22%3E%40Dan%20Snape%3C%2FA%3E%26nbsp%3BHi%20Dan%2C%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ECan%20you%20Run%20Get-TransportRule%20-Identity%20%22name%20of%20transport%20rule%22%20%7C%20FL%20and%20share%20here%20(pls%20hide%20sensitive%20or%20confidential%20information%20including%20domain%20name.%26nbsp%3B%3C%2FP%3E%3CP%3EAlso%20%2C%20have%20you%20enforced%20the%20Transport%20Rule%20at%20the%20end%20of%20Transport%20rule.%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3ECheers%20!%3C%2FP%3E%3CP%3EAnkit%20Shukla%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-788503%22%20slang%3D%22en-US%22%3ERe%3A%20Transport%20rule%20for%20encrypted%20messages%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-788503%22%20slang%3D%22en-US%22%3E%3CP%3EModifying%20the%20content%20on%20an%20encrypted%20message%20is%20not%20supported%2C%20as%20detailed%20for%20example%20here%3A%26nbsp%3B%3CA%20href%3D%22https%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fprevious-versions%2Foffice%2Fexchange-server-2010%2Fbb124703(v%3Dexchg.141)%23message-types%22%20target%3D%22_blank%22%20rel%3D%22noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%20noopener%20noreferrer%22%3Ehttps%3A%2F%2Fdocs.microsoft.com%2Fen-us%2Fprevious-versions%2Foffice%2Fexchange-server-2010%2Fbb124703(v%3Dexchg.141)%23message-types%3C%2FA%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-789452%22%20slang%3D%22en-US%22%3ERe%3A%20Transport%20rule%20for%20encrypted%20messages%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-789452%22%20slang%3D%22en-US%22%3E%3CP%3EThanks%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F58%22%20target%3D%22_blank%22%3E%40Vasil%20Michev%3C%2FA%3E%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-796479%22%20slang%3D%22en-US%22%3ERe%3A%20Transport%20rule%20for%20encrypted%20messages%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-796479%22%20slang%3D%22en-US%22%3E%3CP%3EWe%20currently%20have%20a%20rule%20that%20is%20prepending%20%22EXT%3A%22%20to%20the%20subject%20line%20of%20all%20messages%20from%20outside%20the%20organisation%20via%20an%20Exchange%20Online%20transport%20rule.%20This%20is%20also%20occurring%20on%20encrypted%20messages%20(coming%20from%20an%20external%20recipient%20also%20in%20Exchange%20Online).%20Is%20there%20any%20way%20I%20can%20create%20a%20condition%20to%20detect%20these%20encrypted%20messages%20and%20use%20this%20as%20an%20exclusion%20for%20this%20transport%20rule%3F%20I've%20tried%20using%20%22if%20message%20type%20is%20encrypted%22%20and%20if%20%22X-MS-Exchange-CrossTenant-TransportEncryption-OmeV2LinkUrl'%20header%20contains%20%22.%22%22%20but%20with%20no%20success.%3C%2FP%3E%3CP%3EEven%20better%20I%20could%20create%20a%20separate%20rule%20to%20tag%20these%20messages%20with%20%22Encrypted%3A%22%20and%20bypass%20the%20above%20rule.%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-796547%22%20slang%3D%22en-US%22%3ERe%3A%20Transport%20rule%20for%20encrypted%20messages%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-796547%22%20slang%3D%22en-US%22%3E%3CP%3EDepends%20on%20the%20type%20of%20encryption%2C%20how%20exactly%20are%20the%20messages%20being%20generated%3F%20RMS%3F%20OME%3F%20S%2FMIME%3F%26nbsp%3B%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-797061%22%20slang%3D%22en-US%22%3ERe%3A%20Transport%20rule%20for%20encrypted%20messages%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-797061%22%20slang%3D%22en-US%22%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fuser%2Fviewprofilepage%2Fuser-id%2F58%22%20target%3D%22_blank%22%3E%40Vasil%20Michev%3C%2FA%3EDoing%20some%20more%20digging%20into%20this%2C%20transport%20decryption%20is%20enabled%20by%20default%20in%20Exchange%20Online%20and%20set%20to%20%22Optional%22%20so%20transport%20rules%20can%20in%20fact%20read%20messages%20protected%20using%20AAD%20RMS.%20I've%20tested%20and%20this%20works%20fine%20(a%20disclaimer%20is%20added%20successfully%20to%20these%20messages).%20So%20my%20mistake%20was%20thinking%20that%20the%20%22encrypted%22%20message%20type%20also%20referred%20to%20these%20types%20of%20messages%2C%20when%20in%20fact%20it%20only%20refers%20to%20S%2FMIME%20protected%20messages.%3C%2FP%3E%3CP%3EI%20now%20need%20to%20find%20a%20condition%20I%20can%20use%20in%20a%20transport%20rule%20that%20can%20detect%20messages%20that%20have%20AAD%20RMS%20protection%20applied%20to%20it.%20We%20are%20using%20the%20%22Encrypt%22%20option%20in%20Outlook%20to%20do%20the%20protection%20which%20I%20understand%20uses%20the%20new%20OME%2C%20which%20uses%20AAD%20RMS%20(but%20I%20may%20be%20wrong)%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-797126%22%20slang%3D%22en-US%22%3ERe%3A%20Transport%20rule%20for%20encrypted%20messages%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-797126%22%20slang%3D%22en-US%22%3E%3CP%3EI%20think%20I've%20figured%20it%20out.%20Looks%20like%20the%20message%20type%26nbsp%3B'Permission%20controlled'%20deals%20with%20these%20type%20of%20messages%2C%20and%20I'm%20able%20to%20do%20exactly%20what%20I%20need%20using%20this%20as%20a%20condition%20in%20the%20transport%20rule.%3C%2FP%3E%3C%2FLINGO-BODY%3E
Highlighted
Dan Snape
Contributor

I'm trying to configure a mail flow/transport rule in Exchange Online to add a banner to incoming messages that are encrypted. During testing, the rule does not get triggered, even though the received message has an Outlook notification that the message is encrypted. My rule is using the "if message type is encrypted" condition to add a disclaimer (prepend). Does anyone know how this can successfully be achieved?

7 Replies
Highlighted

@Dan Snape Hi Dan,

 

Can you Run Get-TransportRule -Identity "name of transport rule" | FL and share here (pls hide sensitive or confidential information including domain name. 

Also , have you enforced the Transport Rule at the end of Transport rule.

 

Cheers !

Ankit Shukla

 

Highlighted
Solution

Modifying the content on an encrypted message is not supported, as detailed for example here: https://docs.microsoft.com/en-us/previous-versions/office/exchange-server-2010/bb124703(v=exchg.141)...

Highlighted
Highlighted

We currently have a rule that is prepending "EXT:" to the subject line of all messages from outside the organisation via an Exchange Online transport rule. This is also occurring on encrypted messages (coming from an external recipient also in Exchange Online). Is there any way I can create a condition to detect these encrypted messages and use this as an exclusion for this transport rule? I've tried using "if message type is encrypted" and if "X-MS-Exchange-CrossTenant-TransportEncryption-OmeV2LinkUrl' header contains "."" but with no success.

Even better I could create a separate rule to tag these messages with "Encrypted:" and bypass the above rule.

Highlighted

Depends on the type of encryption, how exactly are the messages being generated? RMS? OME? S/MIME? 

@Vasil MichevDoing some more digging into this, transport decryption is enabled by default in Exchange Online and set to "Optional" so transport rules can in fact read messages protected using AAD RMS. I've tested and this works fine (a disclaimer is added successfully to these messages). So my mistake was thinking that the "encrypted" message type also referred to these types of messages, when in fact it only refers to S/MIME protected messages.

I now need to find a condition I can use in a transport rule that can detect messages that have AAD RMS protection applied to it. We are using the "Encrypt" option in Outlook to do the protection which I understand uses the new OME, which uses AAD RMS (but I may be wrong)

Highlighted

I think I've figured it out. Looks like the message type 'Permission controlled' deals with these type of messages, and I'm able to do exactly what I need using this as a condition in the transport rule.

Related Conversations
Hide tasks from task board when parent item is blocked
gresdawg in Azure on
0 Replies