# External mail system replis with S/MIME encrypted responses to our pgp signed mail.

**URL:** <https://community.ciphermail.com/t/external-mail-system-replis-with-s-mime-encrypted-responses-to-our-pgp-signed-mail/513>\
**Category:** Gateway\
**Created:** [July 28, 2016, 3:04pm UTC](https://community.ciphermail.com/t/external-mail-system-replis-with-s-mime-encrypted-responses-to-our-pgp-signed-mail/513 "2016-07-28T15:04:57Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![mots](https://avatars.discourse-cdn.com/v4/letter/m/fbc32d/32.png) [@mots](https://community.ciphermail.com/u/mots)\
**Post date:** [July 28, 2016, 3:04pm UTC](https://community.ciphermail.com/t/external-mail-system-replis-with-s-mime-encrypted-responses-to-our-pgp-signed-mail/513/1 "2016-07-28T15:04:57Z")

</div>

Hello,

We use PGP based email encryption using the gateway and the customer uses tobit david as their mail server with S/MIME. Our public key is installed on their mail system.

When they reply to one of our emails we get it S/MIME encrypted, with their certificate attached. Email that aren't a reply to one of ours work fine.

The following is in djigzo.log (Personal information redacted):

25 Jul 2016 09:35:00 | INFO incoming; MailID: 9ccd7fb6-05db-4fe9-a683-50102d194a64; Recipients: [local\_user(a)company.com]; Originator: remote\_user(a)customer.com; Sender: remote\_user(a)customer.com; Remote address: 1.2.3.4; Subject: Redacted; Message-ID: \<something(a)isp.com\>; (mitm.application.djigzo.james.mailets.Log) [Spool Thread #2]  
25 Jul 2016 09:35:00 | INFO Subject filter is disabled for the sender; MailID: 9ccd7fb6-05db-4fe9-a683-50102d194a64; Recipients: [local\_user(a)company.com] (mitm.application.djigzo.james.mailets.Default) [Spool Thread #2]  
25 Jul 2016 09:35:00 | INFO To internal recipient(s); MailID: 9ccd7fb6-05db-4fe9-a683-50102d194a64; Recipients: [local\_user(a)company.com] (mitm.application.djigzo.james.mailets.Default) [Spool Thread #2]  
25 Jul 2016 09:35:00 | WARN S/MIME decryption key not found; MailID: 9ccd7fb6-05db-4fe9-a683-50102d194a64; Message: A suitable decryption key could not be found. CMS Recipients: Redacted (mitm.common.security.smime.handler.SMIMEHandler) [Spool Thread #2]  
25 Jul 2016 09:35:00 | INFO Message handling is finished. Sending to final recipient(s); MailID: 9ccd7fb6-05db-4fe9-a683-50102d194a64; Recipients: [local\_user(a)company.com]; Originator: remote\_user(a)customer.com; Sender: remote\_user(a)customer.com; Remote address: 1.2.3.4; Subject: Redacted; Message-ID: \<something(a)isp.com\>; (mitm.application.djigzo.james.mailets.Log) [Spool Thread #0]

Is there anything we can do on our side to fix this?

Regards,

mots

---

<div class="post-metadata">

**Author:** ![martijn](https://dub1.discourse-cdn.com/flex017/user_avatar/community.ciphermail.com/martijn/32/127_2.png) [@martijn](https://community.ciphermail.com/u/martijn)\
**Post date:** [July 28, 2016, 9:31pm UTC](https://community.ciphermail.com/t/external-mail-system-replis-with-s-mime-encrypted-responses-to-our-pgp-signed-mail/513/2 "2016-07-28T21:31:03Z")

</div>

> Hello,
> 
> We use PGP based email encryption using the gateway and the customer  
> uses tobit david as their mail server with S/MIME. Our public key is  
> installed on their mail system.
> 
> When they reply to one of our emails we get it S/MIME encrypted, with  
> their certificate attached. Email that aren't a reply to one of ours  
> work fine.

Not sure whether I fully understand the problem.

So if you send a message signed with PGP/MIME and the recipient replies,  
the reply is S/MIME encrypted with a certificate for which you do not  
have the private key? But if they send you a message which is not a  
reply, the message is not encrypted?

Kind regards,

Martijn Brinkers

> **···**
>
> On 07/28/2016 05:04 PM, mots wrote:
> 
> > The following is in djigzo.log (Personal information redacted):
> > 
> > 25 Jul 2016 09:35:00 | INFO incoming; MailID:  
> > 9ccd7fb6-05db-4fe9-a683-50102d194a64; Recipients:  
> > [local\_user(a)company.com]; Originator: remote\_user(a)customer.com;  
> > Sender: remote\_user(a)customer.com; Remote address: 1.2.3.4; Subject:  
> > Redacted; Message-ID: \<something(a)isp.com\>;  
> > (mitm.application.djigzo.james.mailets.Log) [Spool Thread #2] 25 Jul  
> > 2016 09:35:00 | INFO Subject filter is disabled for the sender;  
> > MailID: 9ccd7fb6-05db-4fe9-a683-50102d194a64; Recipients:  
> > [local\_user(a)company.com]  
> > (mitm.application.djigzo.james.mailets.Default) [Spool Thread #2] 25  
> > Jul 2016 09:35:00 | INFO To internal recipient(s); MailID:  
> > 9ccd7fb6-05db-4fe9-a683-50102d194a64; Recipients:  
> > [local\_user(a)company.com]  
> > (mitm.application.djigzo.james.mailets.Default) [Spool Thread #2] 25  
> > Jul 2016 09:35:00 | WARN S/MIME decryption key not found; MailID:  
> > 9ccd7fb6-05db-4fe9-a683-50102d194a64; Message: A suitable decryption  
> > key could not be found. CMS Recipients: Redacted  
> > (mitm.common.security.smime.handler.SMIMEHandler) [Spool Thread #2]  
> > 25 Jul 2016 09:35:00 | INFO Message handling is finished. Sending to  
> > final recipient(s); MailID: 9ccd7fb6-05db-4fe9-a683-50102d194a64;  
> > Recipients: [local\_user(a)company.com]; Originator:  
> > remote\_user(a)customer.com; Sender: remote\_user(a)customer.com; Remote  
> > address: 1.2.3.4; Subject: Redacted; Message-ID: \<something(a)isp.com\>;  
> > (mitm.application.djigzo.james.mailets.Log) [Spool Thread #0]
> > 
> > Is there anything we can do on our side to fix this?
> > 
> > Regards,
> > 
> > mots
> > 
> > \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ Users mailing list  
> > Users(a)lists.djigzo.com [https://lists.djigzo.com/lists/listinfo/users](https://lists.djigzo.com/lists/listinfo/users)
> 
> --  
> CipherMail email encryption
> 
> Email encryption with support for S/MIME, OpenPGP, PDF encryption and  
> secure webmail pull.
> 
> > **[CipherMail email encryption and digital signatures](https://www.ciphermail.com)**
> >
> > Easy to use server-side email encryption for automatic encryption and digital signing of email.
> 
> Twitter: [http://twitter.com/CipherMail](http://twitter.com/CipherMail)
> 
> --  
> CipherMail email encryption
> 
> Email encryption with support for S/MIME, OpenPGP, PDF encryption and  
> secure webmail pull.
> 
> > **[CipherMail email encryption and digital signatures](https://www.ciphermail.com)**
> >
> > Easy to use server-side email encryption for automatic encryption and digital signing of email.
> 
> Twitter: [http://twitter.com/CipherMail](http://twitter.com/CipherMail)

---

<div class="post-metadata">

**Author:** ![mots](https://avatars.discourse-cdn.com/v4/letter/m/fbc32d/32.png) [@mots](https://community.ciphermail.com/u/mots)\
**Post date:** [July 29, 2016, 12:44pm UTC](https://community.ciphermail.com/t/external-mail-system-replis-with-s-mime-encrypted-responses-to-our-pgp-signed-mail/513/3 "2016-07-29T12:44:15Z")

</div>

That's exactly what's happening.

> **···**
>
> -----Ursprüngliche Nachricht-----
> 
> > Von:Martijn Brinkers \<martijn(a)ciphermail.com\>  
> > Gesendet: Don 28 Juli 2016 23:31  
> > An: users(a)lists.djigzo.com  
> > Betreff: Re: External mail system replis with S/MIME encrypted responses to our pgp signed mail.
> > 
> > On 07/28/2016 05:04 PM, mots wrote:  
> > \> Hello,  
> > \>  
> > \> We use PGP based email encryption using the gateway and the customer  
> > \> uses tobit david as their mail server with S/MIME. Our public key is  
> > \> installed on their mail system.  
> > \>  
> > \> When they reply to one of our emails we get it S/MIME encrypted, with  
> > \> their certificate attached. Email that aren't a reply to one of ours  
> > \> work fine.
> > 
> > Not sure whether I fully understand the problem.
> > 
> > So if you send a message signed with PGP/MIME and the recipient replies,  
> > the reply is S/MIME encrypted with a certificate for which you do not  
> > have the private key? But if they send you a message which is not a  
> > reply, the message is not encrypted?
> > 
> > Kind regards,
> > 
> > Martijn Brinkers
> > 
> > \>  
> > \> The following is in djigzo.log (Personal information redacted):  
> > \>  
> > \> 25 Jul 2016 09:35:00 | INFO incoming; MailID:  
> > \> 9ccd7fb6-05db-4fe9-a683-50102d194a64; Recipients:  
> > \> [local\_user(a)company.com]; Originator: remote\_user(a)customer.com;  
> > \> Sender: remote\_user(a)customer.com; Remote address: 1.2.3.4; Subject:  
> > \> Redacted; Message-ID: \<something(a)isp.com\>;  
> > \> (mitm.application.djigzo.james.mailets.Log) [Spool Thread #2] 25 Jul  
> > \> 2016 09:35:00 | INFO Subject filter is disabled for the sender;  
> > \> MailID: 9ccd7fb6-05db-4fe9-a683-50102d194a64; Recipients:  
> > \> [local\_user(a)company.com]  
> > \> (mitm.application.djigzo.james.mailets.Default) [Spool Thread #2] 25  
> > \> Jul 2016 09:35:00 | INFO To internal recipient(s); MailID:  
> > \> 9ccd7fb6-05db-4fe9-a683-50102d194a64; Recipients:  
> > \> [local\_user(a)company.com]  
> > \> (mitm.application.djigzo.james.mailets.Default) [Spool Thread #2] 25  
> > \> Jul 2016 09:35:00 | WARN S/MIME decryption key not found; MailID:  
> > \> 9ccd7fb6-05db-4fe9-a683-50102d194a64; Message: A suitable decryption  
> > \> key could not be found. CMS Recipients: Redacted  
> > \> (mitm.common.security.smime.handler.SMIMEHandler) [Spool Thread #2]  
> > \> 25 Jul 2016 09:35:00 | INFO Message handling is finished. Sending to  
> > \> final recipient(s); MailID: 9ccd7fb6-05db-4fe9-a683-50102d194a64;  
> > \> Recipients: [local\_user(a)company.com]; Originator:  
> > \> remote\_user(a)customer.com; Sender: remote\_user(a)customer.com; Remote  
> > \> address: 1.2.3.4; Subject: Redacted; Message-ID: \<something(a)isp.com\>;  
> > \> (mitm.application.djigzo.james.mailets.Log) [Spool Thread #0]  
> > \>  
> > \> Is there anything we can do on our side to fix this?  
> > \>  
> > \> Regards,  
> > \>  
> > \> mots  
> > \>  
> > \>  
> > \>  
> > \> \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ Users mailing list  
> > \> Users(a)lists.djigzo.com [https://lists.djigzo.com/lists/listinfo/users](https://lists.djigzo.com/lists/listinfo/users)  
> > \>
> > 
> > --  
> > CipherMail email encryption
> > 
> > Email encryption with support for S/MIME, OpenPGP, PDF encryption and  
> > secure webmail pull.
> > 
> > [https://www.ciphermail.com](https://www.ciphermail.com)
> > 
> > Twitter: [http://twitter.com/CipherMail](http://twitter.com/CipherMail)
> > 
> > --  
> > CipherMail email encryption
> > 
> > Email encryption with support for S/MIME, OpenPGP, PDF encryption and  
> > secure webmail pull.
> > 
> > [https://www.ciphermail.com](https://www.ciphermail.com)
> > 
> > Twitter: [http://twitter.com/CipherMail](http://twitter.com/CipherMail)  
> > \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_  
> > Users mailing list  
> > Users(a)lists.djigzo.com  
> > [https://lists.djigzo.com/lists/listinfo/users](https://lists.djigzo.com/lists/listinfo/users)

---

<div class="post-metadata">

**Author:** ![martijn](https://dub1.discourse-cdn.com/flex017/user_avatar/community.ciphermail.com/martijn/32/127_2.png) [@martijn](https://community.ciphermail.com/u/martijn)\
**Post date:** [July 29, 2016, 1:23pm UTC](https://community.ciphermail.com/t/external-mail-system-replis-with-s-mime-encrypted-responses-to-our-pgp-signed-mail/513/4 "2016-07-29T13:23:44Z")

</div>

> That's exactly what's happening.

Since I do not know any details about the product they are using, I am  
just guessing. Perhaps their gateway fails to make a distinction between  
a PGP/MIME and S/MIME signed message.

A PGP/MIME signed message has the content type

Content-Type: multipart/signed; protocol="application/pgp-signature"

and an S/MIME message has the content type

Content-Type: multipart/signed; protocol="application/pkcs7-signature";

Perhaps their solution does not take the protocol into account and only  
looks at the main part of the content type and therefore mixes up  
PGP/MIME and S/MIME.

Another option might be that the mail client of the person replying  
encrypts the message and not their gateway.

You might try to see whether the same problem occurs of you change the  
"PGP encoding to external" for their domain from PGP/MIME to PGP/INLINE.

Can you forward a faulty encrypted message (with full MIME content) to  
my personal email address (i.e., off-list) so I can see how the message  
looks like?

Kind regards,

Martijn Brinkers

> **···**
>
> On 07/29/2016 02:44 PM, mots wrote:
> 
> > -----Ursprüngliche Nachricht-----
> > 
> > > Von:Martijn Brinkers \<martijn(a)ciphermail.com\>  
> > > Gesendet: Don 28 Juli 2016 23:31  
> > > An: users(a)lists.djigzo.com  
> > > Betreff: Re: External mail system replis with S/MIME encrypted responses to our pgp signed mail.
> > > 
> > > On 07/28/2016 05:04 PM, mots wrote:
> > > 
> > > > Hello,
> > > > 
> > > > We use PGP based email encryption using the gateway and the customer  
> > > > uses tobit david as their mail server with S/MIME. Our public key is  
> > > > installed on their mail system.
> > > > 
> > > > When they reply to one of our emails we get it S/MIME encrypted, with  
> > > > their certificate attached. Email that aren't a reply to one of ours  
> > > > work fine.
> > > 
> > > Not sure whether I fully understand the problem.
> > > 
> > > So if you send a message signed with PGP/MIME and the recipient replies,  
> > > the reply is S/MIME encrypted with a certificate for which you do not  
> > > have the private key? But if they send you a message which is not a  
> > > reply, the message is not encrypted?
> > > 
> > > Kind regards,
> > > 
> > > Martijn Brinkers
> > > 
> > > > The following is in djigzo.log (Personal information redacted):
> > > > 
> > > > 25 Jul 2016 09:35:00 | INFO incoming; MailID:  
> > > > 9ccd7fb6-05db-4fe9-a683-50102d194a64; Recipients:  
> > > > [local\_user(a)company.com]; Originator: remote\_user(a)customer.com;  
> > > > Sender: remote\_user(a)customer.com; Remote address: 1.2.3.4; Subject:  
> > > > Redacted; Message-ID: \<something(a)isp.com\>;  
> > > > (mitm.application.djigzo.james.mailets.Log) [Spool Thread #2] 25 Jul  
> > > > 2016 09:35:00 | INFO Subject filter is disabled for the sender;  
> > > > MailID: 9ccd7fb6-05db-4fe9-a683-50102d194a64; Recipients:  
> > > > [local\_user(a)company.com]  
> > > > (mitm.application.djigzo.james.mailets.Default) [Spool Thread #2] 25  
> > > > Jul 2016 09:35:00 | INFO To internal recipient(s); MailID:  
> > > > 9ccd7fb6-05db-4fe9-a683-50102d194a64; Recipients:  
> > > > [local\_user(a)company.com]  
> > > > (mitm.application.djigzo.james.mailets.Default) [Spool Thread #2] 25  
> > > > Jul 2016 09:35:00 | WARN S/MIME decryption key not found; MailID:  
> > > > 9ccd7fb6-05db-4fe9-a683-50102d194a64; Message: A suitable decryption  
> > > > key could not be found. CMS Recipients: Redacted  
> > > > (mitm.common.security.smime.handler.SMIMEHandler) [Spool Thread #2]  
> > > > 25 Jul 2016 09:35:00 | INFO Message handling is finished. Sending to  
> > > > final recipient(s); MailID: 9ccd7fb6-05db-4fe9-a683-50102d194a64;  
> > > > Recipients: [local\_user(a)company.com]; Originator:  
> > > > remote\_user(a)customer.com; Sender: remote\_user(a)customer.com; Remote  
> > > > address: 1.2.3.4; Subject: Redacted; Message-ID: \<something(a)isp.com\>;  
> > > > (mitm.application.djigzo.james.mailets.Log) [Spool Thread #0]
> > > > 
> > > > Is there anything we can do on our side to fix this?
> > > > 
> > > > Regards,
> > > > 
> > > > mots
> > > > 
> > > > \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_ Users mailing list  
> > > > Users(a)lists.djigzo.com [https://lists.djigzo.com/lists/listinfo/users](https://lists.djigzo.com/lists/listinfo/users)
> > > 
> > > --  
> > > CipherMail email encryption
> > > 
> > > Email encryption with support for S/MIME, OpenPGP, PDF encryption and  
> > > secure webmail pull.
> > > 
> > > [https://www.ciphermail.com](https://www.ciphermail.com)
> > > 
> > > Twitter: [http://twitter.com/CipherMail](http://twitter.com/CipherMail)
> > > 
> > > --  
> > > CipherMail email encryption
> > > 
> > > Email encryption with support for S/MIME, OpenPGP, PDF encryption and  
> > > secure webmail pull.
> > > 
> > > [https://www.ciphermail.com](https://www.ciphermail.com)
> > > 
> > > Twitter: [http://twitter.com/CipherMail](http://twitter.com/CipherMail)  
> > > \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_  
> > > Users mailing list  
> > > Users(a)lists.djigzo.com  
> > > [https://lists.djigzo.com/lists/listinfo/users](https://lists.djigzo.com/lists/listinfo/users)
> > > 
> > > \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_  
> > > Users mailing list  
> > > Users(a)lists.djigzo.com  
> > > [https://lists.djigzo.com/lists/listinfo/users](https://lists.djigzo.com/lists/listinfo/users)
> 
> --  
> CipherMail email encryption
> 
> Email encryption with support for S/MIME, OpenPGP, PDF encryption and  
> secure webmail pull.
> 
> > **[CipherMail email encryption and digital signatures](https://www.ciphermail.com)**
> >
> > Easy to use server-side email encryption for automatic encryption and digital signing of email.
> 
> Twitter: [http://twitter.com/CipherMail](http://twitter.com/CipherMail)
