cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Did you know you can set a signature that will be added to all your posts? Set it here! X

Mail-Trigger: Confidential Flag for Outlook

JensN.
14-Alexandrite

Mail-Trigger: Confidential Flag for Outlook

Hi @all,

we're working intensively with trigger-generated mail-notifications for our users. Since some time more and more of the users are working at external suppliers and there is a company-directive, that we have to encrypt mails which are adressed to external persons. Our mail-gateway has an option to encrypt outgoing mails autmatically, if they have a confidential flag (in outlook-mails). Is it possible to set this flag from within (per example) the javamail-triggerscript? Thanks for your input...

regards, Jens

3 REPLIES 3

Hello Jens-Uwe,

From the documentation of the javamail.js trigger script, I see it is based on the JavaMail API. I found documentation for it here.

The question on ServerFault (part of StackExchange, so the same family as StackOverflow) was asked in this question Which mail header does Outlook 2003+ use to indicate confidentiality? The answer seems to be one of:

  • Sensitivity: company-confidential
  • Sensitivity: personal
  • Sensitivity: private

Given that these are Microsoft standards, you will probably have to do a little header inspection to figure out which applies in your organization.

Assuming you want to mark every email as company-confidential, in the JavaMail.js function sendMail, add a block of code that looks something like this after the var msg = new MimeMessage(session) line, but before the Transport.send(msg) line:

msg.addHeader( new java.lang.String("Sensitivity"), new java.lang.String("company-confidential"));

I have not tested this out, and I don't normally modify trigger scripts (that is outside of the scope of Support), but that should get you going in the right general direction. In particular, you may want to use the method msg.setHeader instead. setHeader replaces all existing values for this header_name, while addHeader just adds to the existing header_name.

Also be aware that "RFC 822 headers must contain only US-ASCII characters, so a header that contains non US-ASCII characters must have been encoded by the caller as per the rules of RFC 2047." Those are IETF RFCs, not PTC RFCs.

I know that's not quite an example, but that's all I have at the moment.

Regards,
Kael


Kind Regards,
Kael Lizak

Senior Technical Support Engineer
PTC Integrity Lifecycle Manager
JensN.
14-Alexandrite
(To:KaelLizak)

Hi Kael,

this looks very interesting, thank you. I'll have to make some tests now...

kind regards, Jens

JensN.
14-Alexandrite
(To:KaelLizak)

Hi Kael,

thanks, works exactly as you wrote.

kind regards, Jens

Announcements


Top Tags