2

Following Sending Mail

Since no credentials are given in this configuration, Emacs will look them up in $(HOME)/.authinfo or $(HOME)/.authinfo.gpg (encrypted). The content of this file should follow this scheme:

machine example.org login [your login name] password [your password]

After finished the configuration and send mail

From: abst.proc.do@qq.com (abst.proc.do)
To: igabriel_job@163.com
Subject: Testing
Date: Wed, 22 Jan 2020 07:56:03 +0800
Message-ID: <874kwo2wks.fsf@foxmail.com>
--text follows this line--
Testing

but got the error:

 gnutls-negotiate: GnuTLS error: #<process smtpmail<1>>, -15

What's the problem? I did not set gnus.

Ubuntu 19.10 emacs 26.3

AbstProcDo
  • 1,231
  • 5
  • 15

1 Answers1

1

Change your port to use 465 instead of 587

(setq message-send-mail-function 'smtpmail-send-it
      smtpmail-starttls-credentials
      '(("smtp.gmail.com" 465 nil nil))
      smtpmail-default-smtp-server "smtp.gmail.com"
      smtpmail-smtp-server "smtp.gmail.com"
      smtpmail-smtp-service 465
      smtpmail-debug-info t)
Lionel
  • 111
  • 2