Lets say Alice@gmail.com wants to send message to Bob@secureMail.com

Alice <--> gmail.com <--> secureMail.com <--> Bob

We know gmail.com can read the unencrypted message. Is it possible for secureMail.com to receive the message such that only Bob can decrypt the message?

If my understanding is correct, secureMail.com will have a ssl certificate and gmail.com will encrypt using secureMail's public key so that the communication is secure. So secureMail.com can read unencrypted message. It can however re-encrypt with Bob's public key before persisting on disk.

Does email protocol allow secureMail.com to present different certificate/publicKey for each user to gmail.com so that it never gets to read unencrypted message?


This website claims emails are end to end encrypted and even the server cannot access decrypted data. Did i miss something? site: https://protonmail.ch/


ProtonMail's segregated authentication and decryption system means logging into a ProtonMail account that requires two passwords. The first password is used to authenticate the user and retrieve the correct account. After that, encrypted data is sent to the user. The second password is a decryption password which is never sent to us. It is used to decrypt data on your device so we do not have access to the decrypted data, or the decryption password. For this reason, we are also unable to do password recovery. If you forget your decryption password, we cannot recover your data.

  • There are two widely used de-facto standards for real end-to-end encryption: S/MIME and decentralized PGP/OpenPGP/GnuPG. The former is more or less part of e-mail itself and supported by classic client software out of the box, the latter is usually implemented as an add-on. However, it's up to the issuer to support user-generated keys for S/MIME, where trust is cert-based like HTTPS/SSL. I don't know about ProtonMail's implementation, but it seems it's based on PGP but proprietary still and only between ProtonMail users. SSL/TLS are between two servers or client/server. Not end to end. – Archimedix May 28 '15 at 15:38

Unless you're doing end-to-end encryption (where the servers only see encrypted messages, other than the recipient's name), there's no real security, so having something like this in the mail submission or transport protocols isn't going to be useful.

The receiving server could certainly encrypt incoming (unencrypted) messages with the recipient's public key, then securely erase the unencrypted message and transient key, which would make it somewhat more secure, but you still have to trust all intermediate servers. You can't even force them to use a secure transport from server to server!

Even if there was an extension to the mail transport protocol for the receiving server to send a public key of the recipient, you're still trusting that the receiving server is sending the correct key. It could easily send a false key, decrypt and save it, then re-encrypt with the correct key. If you CAN trust the server, you might as well have it just get the unencrypted message (using secure transport) and encrypt the message itself.

Having an e-mail client with built in support for encryption and authentication/key management is really the only secure way of doing it. There's no reason you should have to trust the mail servers.


Regular email provides no support for encryption from the mail servers. This includes Gmail.com, securemail.com, and intermediary servers in your example. But PGP extends mail to secure the email body though not the headers. As with much of PKI, managing keys can be difficult. PGP leaves key management to sneakernet.

There are more private solutions but PGP is widely available.

  • I thought email did support ssl/tls – balki May 28 '15 at 4:52
  • 1
    That is when in transit. Every mail server sees the message in clear-text – Neil Smithline May 28 '15 at 4:54
  • This website claims even they cannot read the emails and decrypting key is with the user. Am I missing something? protonmail.ch – balki May 28 '15 at 4:57
  • 1
    Yeah, some proprietary solution. They only claim that mail is secure between two of their users. I saw no claims about email going to or coming from other services "Your emails are automatically end-to-end encrypted inside our email service." – Neil Smithline May 28 '15 at 5:08
  • @balki javascript cryptography. Which they can modify, so no there's no real guarantee. – Natanael May 28 '15 at 10:59


The way end-to-end email encryption works is this:

  1. You use a mail client like Outlook or Thunderbird or Mail or Claws to write a message. You encrypt the message using a local tool such as GPG, then send it. The encryption key and the email address are unrelated.
  2. Your mail server sends the encrypted message to my mail server. Hopefully it uses SSL but it isn't necessary for this!
  3. I receive the mail in my client and use GPG (or whatever) to decrypt the message.

The servers in between don't matter, and the domains of the email addresses don't matter. Someone watching the traffic can see we're talking, and even the subject line, but not the contents of the message body.

So yes, this works now, and it has worked this way for decades. :-)


As far as I know, there are two ways to secure email communication: PGP and S/MIME. http://www.techrepublic.com/blog/it-security/email-encryption-using-pgp-and-s-mime/

In your example, develop a customized email gateway using PGP is feasible.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.