0

I use Emacs and mu4e for email. I successfully set up Amazon WorkMail IMAP with Emacs and mu4e as a second account. My first account works with TLS:

(setq ; ...
      smtpmail-smtp-server         "smtp.server.com"
      message-send-mail-function   'smtpmail-send-it
      smtpmail-smtp-service 587
      smtpmail-stream-type 'starttls
      smtpmail-auth-credentials ; ...
)

I was unable to set up SMTP: Amazon's page mentions that STARTTLS is not supported. I followed this page on SSL:

(defvar my-mu4e-account-alist
  '(
    ("mainAccount" ; ...
     )
    ("AWS"
     (user-mail-address "me@domain.com")
     (smtpmail-smtp-server "smtp.mail.eu-west-1.awsapps.com")
     (smtpmail-stream-type 'ssl)
     (smtpmail-smtp-service 465)
     )
    ))

And I get this error:

open-network-stream: Invalid connection type ssl

How can I fix this?

0

I found this fix of removing the quote from 'ssl:

The actual problem is that the list of items in mu4e-account-alist is already quoted, so when one writes (smtpmail-stream-type 'ssl), what is actually being stored in smtpmail-stream-type is literally the value 'ssl, while it should simply be ssl. Remove the extraneous quote-mark and all is well.

So, in my case, this worked:

(defvar my-mu4e-account-alist
  '(
    ("mainAccount" ; ...
     )
    ("AWS"
     (user-mail-address "me@domain.com")
     (smtpmail-smtp-server "smtp.mail.eu-west-1.awsapps.com")
     (smtpmail-stream-type ssl)
     (smtpmail-smtp-service 465)
     )
    ))
| improve this answer | |

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.