Gnus development mailing list
 help / color / mirror / Atom feed
* starttls for gmail SMTP doesn't start
@ 2012-03-16 21:34 Sebastian P. Luque
  2012-03-22 20:24 ` Lars Magne Ingebrigtsen
  0 siblings, 1 reply; 14+ messages in thread
From: Sebastian P. Luque @ 2012-03-16 21:34 UTC (permalink / raw)
  To: ding

Hi,

With GNU Emacs 23.3.1 (x86_64-pc-linux-gnu, GTK+ Version 2.24.8) of
2012-01-29 on trouble, modified by Debian, Gnus v5.13, and this set up
for sending mail via Gmail's SMTP server:

(setq nnimap-authinfo-file "~/.authinfo.gpg"
      send-mail-function 'smtpmail-send-it
      message-send-mail-function 'smtpmail-send-it
      smtpmail-auth-credentials nnimap-authinfo-file
      smtpmail-smtp-service 587
      smtpmail-default-smtp-server "smtp.gmail.com"
      smtpmail-starttls-credentials
      '((smtpmail-default-smtp-server smtpmail-smtp-service nil nil))
      smtpmail-debug-info t
      smtpmail-debug-verb t)

,-----[ C-h v starttls-use-gnutls RET ]
| starttls-use-gnutls is a variable defined in `starttls.el'.
| Its value is t
| 
| Documentation:
| *Whether to use GNUTLS instead of the `starttls' command.
| 
| You can customize this variable.
| 
| This variable was introduced, or its default value was changed, in
| version 22.1 of Emacs.
| 
| [back]
`-----

,-----[ C-h v starttls-gnutls-program RET ]
| starttls-gnutls-program is a variable defined in `starttls.el'.
| Its value is "gnutls-cli"
| 
|   This variable is potentially risky when used as a file local variable.
| 
| Documentation:
| Name of GNUTLS command line tool.
| This program is used when GNUTLS is used, i.e. when
| `starttls-use-gnutls' is non-nil.
| 
| You can customize this variable.
| 
| This variable was introduced, or its default value was changed, in
| version 22.1 of Emacs.
| 
| [back]
`-----

I get this in *Messages*:

---<--------------------cut here---------------start------------------->---
Sending...
Sending via mail...
220 mx.google.com ESMTP wf10sm476861igb.8
250-mx.google.com at your service, [50.71.33.126]
250-SIZE 35882577
250-8BITMIME
250-STARTTLS
250 ENHANCEDSTATUSCODES
530 5.7.0 Must issue a STARTTLS command first. wf10sm476861igb.8
smtpmail-send-it: Sending failed; SMTP protocol error
---<--------------------cut here---------------end--------------------->---

To investigate, I did 'M-x debug-on-entry starttls-open-stream', and
never got the debugger, so I assume the function never got called.  Any
idea what might be going on?

Cheers,

-- 
Seb



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: starttls for gmail SMTP doesn't start
  2012-03-16 21:34 starttls for gmail SMTP doesn't start Sebastian P. Luque
@ 2012-03-22 20:24 ` Lars Magne Ingebrigtsen
  2012-03-27 16:38   ` Seb
  0 siblings, 1 reply; 14+ messages in thread
From: Lars Magne Ingebrigtsen @ 2012-03-22 20:24 UTC (permalink / raw)
  To: ding

"Sebastian P. Luque" <spluque@gmail.com> writes:

> 530 5.7.0 Must issue a STARTTLS command first. wf10sm476861igb.8
> smtpmail-send-it: Sending failed; SMTP protocol error

Is your Emacs compiled with gnutls support, or do you have gnutls-cli
installed?

-- 
(domestic pets only, the antidote for overdose, milk.)
  bloggy blog http://lars.ingebrigtsen.no/



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: starttls for gmail SMTP doesn't start
  2012-03-22 20:24 ` Lars Magne Ingebrigtsen
@ 2012-03-27 16:38   ` Seb
  2012-03-27 19:37     ` Steinar Bang
  2012-04-10 19:08     ` Lars Magne Ingebrigtsen
  0 siblings, 2 replies; 14+ messages in thread
From: Seb @ 2012-03-27 16:38 UTC (permalink / raw)
  To: ding

On Thu, 22 Mar 2012 21:24:30 +0100,
Lars Magne Ingebrigtsen <larsi@gnus.org> wrote:

> "Sebastian P. Luque" <spluque@gmail.com> writes:
>> 530 5.7.0 Must issue a STARTTLS command first. wf10sm476861igb.8
>> smtpmail-send-it: Sending failed; SMTP protocol error

> Is your Emacs compiled with gnutls support, or do you have gnutls-cli
> installed?

I'm using Debian sid Emacs packages (GNU Emacs 23.4.1
(x86_64-pc-linux-gnu, GTK+ Version 2.24.10) of 2012-03-21 on trouble,
modified by Debian), but am not sure if this is compiled with gnutls
support.  I do have gnutls-cli installed from the gnutls-bin package,
which provides /usr/bin/gnutls-cli.

-- 
Seb



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: starttls for gmail SMTP doesn't start
  2012-03-27 16:38   ` Seb
@ 2012-03-27 19:37     ` Steinar Bang
  2012-10-10 19:39       ` Sebastian P. Luque
  2012-12-23 13:46       ` Ted Zlatanov
  2012-04-10 19:08     ` Lars Magne Ingebrigtsen
  1 sibling, 2 replies; 14+ messages in thread
From: Steinar Bang @ 2012-03-27 19:37 UTC (permalink / raw)
  To: ding

>>>>> Seb <spluque@gmail.com>:

> I'm using Debian sid Emacs packages (GNU Emacs 23.4.1
> (x86_64-pc-linux-gnu, GTK+ Version 2.24.10) of 2012-03-21 on trouble,
> modified by Debian), but am not sure if this is compiled with gnutls
> support.

I think gnutls support in emacs is emacs 24 only.

But I may be wrong...?




^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: starttls for gmail SMTP doesn't start
  2012-03-27 16:38   ` Seb
  2012-03-27 19:37     ` Steinar Bang
@ 2012-04-10 19:08     ` Lars Magne Ingebrigtsen
  2012-04-10 21:25       ` Reiner Steib
  1 sibling, 1 reply; 14+ messages in thread
From: Lars Magne Ingebrigtsen @ 2012-04-10 19:08 UTC (permalink / raw)
  To: ding

Seb <spluque@gmail.com> writes:

> I'm using Debian sid Emacs packages (GNU Emacs 23.4.1
> (x86_64-pc-linux-gnu, GTK+ Version 2.24.10) of 2012-03-21 on trouble,
> modified by Debian), but am not sure if this is compiled with gnutls
> support.

Right.  This isn't a Gnus issue at all, then, but an Emacs 23 bug.

> I do have gnutls-cli installed from the gnutls-bin package, which
> provides /usr/bin/gnutls-cli.

I think you have to configure smtpmail.el somehow to make it do STARTTLS
in Emacs 23.  This has all been fixed in Emacs 24 to work automatically,
but I don't recall what the magic was to make it work in Emacs 23.

-- 
(domestic pets only, the antidote for overdose, milk.)
  bloggy blog http://lars.ingebrigtsen.no/



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: starttls for gmail SMTP doesn't start
  2012-04-10 19:08     ` Lars Magne Ingebrigtsen
@ 2012-04-10 21:25       ` Reiner Steib
  0 siblings, 0 replies; 14+ messages in thread
From: Reiner Steib @ 2012-04-10 21:25 UTC (permalink / raw)
  To: ding

On Tue, Apr 10 2012, Lars Magne Ingebrigtsen wrote:

> Seb <spluque@gmail.com> writes:
>
>> I do have gnutls-cli installed from the gnutls-bin package, which
>> provides /usr/bin/gnutls-cli.
>
> I think you have to configure smtpmail.el somehow to make it do STARTTLS
> in Emacs 23.  

It should be sufficient to have gnutls-cli in PATH in Emacs 23.

Bye, Reiner.
-- 
       ,,,
      (o o)
---ooO-(_)-Ooo---  |  PGP key available  |  http://rsteib.home.pages.de/




^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: starttls for gmail SMTP doesn't start
  2012-03-27 19:37     ` Steinar Bang
@ 2012-10-10 19:39       ` Sebastian P. Luque
  2012-10-18 15:35         ` Eric S Fraga
  2012-12-23 13:46       ` Ted Zlatanov
  1 sibling, 1 reply; 14+ messages in thread
From: Sebastian P. Luque @ 2012-10-10 19:39 UTC (permalink / raw)
  To: ding

On Tue, 27 Mar 2012 21:37:44 +0200,
Steinar Bang <sb@dod.no> wrote:

>>>>>> Seb <spluque@gmail.com>:
>> I'm using Debian sid Emacs packages (GNU Emacs 23.4.1
>> (x86_64-pc-linux-gnu, GTK+ Version 2.24.10) of 2012-03-21 on trouble,
>> modified by Debian), but am not sure if this is compiled with gnutls
>> support.

> I think gnutls support in emacs is emacs 24 only.

> But I may be wrong...?

Coming back to this as I'd really like to be able to use Gmail's SMTP
server and keep my sent emails there and accessible from anywhere.

It seems as though this works with Emacs < 24, as the article in
Emacswiki (http://www.emacswiki.org/emacs/GnusGmail) pre-dates Emacs 24.
Anybody having luck with using Gmail's SMTP server with Gnus?


-- 
Seb



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: starttls for gmail SMTP doesn't start
  2012-10-10 19:39       ` Sebastian P. Luque
@ 2012-10-18 15:35         ` Eric S Fraga
  2012-10-20 11:24           ` Sivaram Neelakantan
  0 siblings, 1 reply; 14+ messages in thread
From: Eric S Fraga @ 2012-10-18 15:35 UTC (permalink / raw)
  To: ding

"Sebastian P. Luque" <spluque@gmail.com> writes:

[...]

> It seems as though this works with Emacs < 24, as the article in
> Emacswiki (http://www.emacswiki.org/emacs/GnusGmail) pre-dates Emacs 24.
> Anybody having luck with using Gmail's SMTP server with Gnus?

Yes, but using an external (to emacs) SMTP mailer (msmtp on
Debian/Ubuntu).  Works perfectly.

-- 
: Eric S Fraga, GnuPG: 0xC89193D8FFFCF67D
: in Emacs 24.2.50.1 + Ma Gnus v0.6
: BBDB version 3.02 ($Date: 2012/09/15 14:41:47 $)




^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: starttls for gmail SMTP doesn't start
  2012-10-18 15:35         ` Eric S Fraga
@ 2012-10-20 11:24           ` Sivaram Neelakantan
  2012-10-25 18:32             ` Sebastian P. Luque
  0 siblings, 1 reply; 14+ messages in thread
From: Sivaram Neelakantan @ 2012-10-20 11:24 UTC (permalink / raw)
  To: ding

On Thu, Oct 18 2012,Eric S Fraga Eric S Fraga wrote:

> "Sebastian P. Luque" <spluque@gmail.com> writes:
>
> [...]
>
>> It seems as though this works with Emacs < 24, as the article in
>> Emacswiki (http://www.emacswiki.org/emacs/GnusGmail) pre-dates Emacs 24.
>> Anybody having luck with using Gmail's SMTP server with Gnus?
>
> Yes, but using an external (to emacs) SMTP mailer (msmtp on
> Debian/Ubuntu).  Works perfectly.

And you can find instructions here

http://emacswiki.org/emacs/GnusMSMTP


 sivaram
 -- 




^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: starttls for gmail SMTP doesn't start
  2012-10-20 11:24           ` Sivaram Neelakantan
@ 2012-10-25 18:32             ` Sebastian P. Luque
  2012-10-25 19:41               ` Eric S Fraga
  0 siblings, 1 reply; 14+ messages in thread
From: Sebastian P. Luque @ 2012-10-25 18:32 UTC (permalink / raw)
  To: ding; +Cc: Sivaram Neelakantan

On Sat, 20 Oct 2012 16:54:39 +0530,
Sivaram Neelakantan <nsivaram.net@gmail.com> wrote:

> On Thu, Oct 18 2012,Eric S Fraga Eric S Fraga wrote:
>> "Sebastian P. Luque" <spluque@gmail.com> writes:

>> [...]

>>> It seems as though this works with Emacs < 24, as the article in
>>> Emacswiki (http://www.emacswiki.org/emacs/GnusGmail) pre-dates Emacs
>>> 24.  Anybody having luck with using Gmail's SMTP server with Gnus?

>> Yes, but using an external (to emacs) SMTP mailer (msmtp on
>> Debian/Ubuntu).  Works perfectly.

> And you can find instructions here

> http://emacswiki.org/emacs/GnusMSMTP

Thanks so much.  For GNU/Linux users, is it really necessary to:

(setq message-send-mail-function 'message-send-mail-with-sendmail)
(setq sendmail-program "c:/gnu/bin/msmtp.exe")

The latter would obviously be different, but I'm not sure I understand
why the former is necessary anyway.

-- 
Seb



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: starttls for gmail SMTP doesn't start
  2012-10-25 18:32             ` Sebastian P. Luque
@ 2012-10-25 19:41               ` Eric S Fraga
  2012-10-25 20:38                 ` Sebastian P. Luque
  0 siblings, 1 reply; 14+ messages in thread
From: Eric S Fraga @ 2012-10-25 19:41 UTC (permalink / raw)
  To: ding

"Sebastian P. Luque" <spluque@gmail.com> writes:

> Thanks so much.  For GNU/Linux users, is it really necessary to:
>
> (setq message-send-mail-function 'message-send-mail-with-sendmail)
> (setq sendmail-program "c:/gnu/bin/msmtp.exe")
>
> The latter would obviously be different, but I'm not sure I understand
> why the former is necessary anyway.

The first is because the variable could be set to one of many different
options and this just makes sure sendmail.  It's probably not necessary
in that I think it's the default (or at least I cannot see where I have
set this in my configuration).

The second, by the way, is probably not at all necessary on some, maybe
all, GNU/Linux systems.  On Debian/Ubuntu, msmtp automatically links
/usr/lib/sendmail to /usr/bin/msmtp.

-- 
: Eric S Fraga, GnuPG: 0xC89193D8FFFCF67D
: in Emacs 24.1.1 + Ma Gnus v0.6
: BBDB version 3.02 ($Date: 2012/09/15 14:41:47 $)




^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: starttls for gmail SMTP doesn't start
  2012-10-25 19:41               ` Eric S Fraga
@ 2012-10-25 20:38                 ` Sebastian P. Luque
  2012-10-27 13:06                   ` Sivaram Neelakantan
  0 siblings, 1 reply; 14+ messages in thread
From: Sebastian P. Luque @ 2012-10-25 20:38 UTC (permalink / raw)
  To: ding

On Thu, 25 Oct 2012 20:41:19 +0100,
Eric S Fraga <e.fraga@ucl.ac.uk> wrote:

> "Sebastian P. Luque" <spluque@gmail.com> writes:
>> Thanks so much.  For GNU/Linux users, is it really necessary to:

>> (setq message-send-mail-function 'message-send-mail-with-sendmail)
>> (setq sendmail-program "c:/gnu/bin/msmtp.exe")

>> The latter would obviously be different, but I'm not sure I
>> understand why the former is necessary anyway.

> The first is because the variable could be set to one of many
> different options and this just makes sure sendmail.  It's probably
> not necessary in that I think it's the default (or at least I cannot
> see where I have set this in my configuration).

According to 'C-h v message-send-mail-function' the default is system
dependent, which for me it was 'smtpmail-send-it'.  It seems like this
automagically uses exim4 in my system, which in turn uses my default ISP
smtp server.


> The second, by the way, is probably not at all necessary on some,
> maybe all, GNU/Linux systems.  On Debian/Ubuntu, msmtp automatically
> links /usr/lib/sendmail to /usr/bin/msmtp.

In my Debian sid, I have:

,-----[ ls -alh /usr/lib/sendmail ]
| lrwxrwxrwx 1 root root 13 Sep 23 06:04 /usr/lib/sendmail -> ../sbin/exim4
`-----

Using:

(setq message-send-mail-function 'message-send-mail-with-sendmail
      sendmail-program "/usr/bin/msmtp"
      message-sendmail-extra-arguments '("-a" "gmail")
      mail-host-address "gmail.com")

works smoothly.

Thanks,

-- 
Seb



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: starttls for gmail SMTP doesn't start
  2012-10-25 20:38                 ` Sebastian P. Luque
@ 2012-10-27 13:06                   ` Sivaram Neelakantan
  0 siblings, 0 replies; 14+ messages in thread
From: Sivaram Neelakantan @ 2012-10-27 13:06 UTC (permalink / raw)
  To: ding

On Fri, Oct 26 2012,Sebastian P. Luque Sebastian P. Luque wrote:


[snipped 12 lines]

>> The first is because the variable could be set to one of many
>> different options and this just makes sure sendmail.  It's probably
>> not necessary in that I think it's the default (or at least I cannot
>> see where I have set this in my configuration).
>
> According to 'C-h v message-send-mail-function' the default is system
> dependent, which for me it was 'smtpmail-send-it'.  It seems like this
> automagically uses exim4 in my system, which in turn uses my default ISP
> smtp server.

"system dependent", that's the reason why.  I posted about this when
Emacs 23.1 was released, as on Windows, any arbitrary program can be
made as your mail client and it gets weird when Emacs launches Firefox
or Outlook when you least expect it.

http://lists.gnu.org/archive/html/info-gnus-english/2009-07/msg00126.html

 sivaram
 -- 




^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: starttls for gmail SMTP doesn't start
  2012-03-27 19:37     ` Steinar Bang
  2012-10-10 19:39       ` Sebastian P. Luque
@ 2012-12-23 13:46       ` Ted Zlatanov
  1 sibling, 0 replies; 14+ messages in thread
From: Ted Zlatanov @ 2012-12-23 13:46 UTC (permalink / raw)
  To: ding

On Tue, 27 Mar 2012 21:37:44 +0200 Steinar Bang <sb@dod.no> wrote: 

>>>>>> Seb <spluque@gmail.com>:
>> I'm using Debian sid Emacs packages (GNU Emacs 23.4.1
>> (x86_64-pc-linux-gnu, GTK+ Version 2.24.10) of 2012-03-21 on trouble,
>> modified by Debian), but am not sure if this is compiled with gnutls
>> support.

SB> I think gnutls support in emacs is emacs 24 only.

It showed up earlier.  I did the initial work towards the end of 2010.
Use the presence and return value of `gnutls-available-p' to be sure;
it's defined at the C level so it doesn't required gnutls.el to be
loaded.

There have been some important bug fixes to the GnuTLS integration since
then, though, so if GnuTLS support is important to you, please upgrade
to the latest Emacs.

Ted




^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2012-12-23 13:46 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-03-16 21:34 starttls for gmail SMTP doesn't start Sebastian P. Luque
2012-03-22 20:24 ` Lars Magne Ingebrigtsen
2012-03-27 16:38   ` Seb
2012-03-27 19:37     ` Steinar Bang
2012-10-10 19:39       ` Sebastian P. Luque
2012-10-18 15:35         ` Eric S Fraga
2012-10-20 11:24           ` Sivaram Neelakantan
2012-10-25 18:32             ` Sebastian P. Luque
2012-10-25 19:41               ` Eric S Fraga
2012-10-25 20:38                 ` Sebastian P. Luque
2012-10-27 13:06                   ` Sivaram Neelakantan
2012-12-23 13:46       ` Ted Zlatanov
2012-04-10 19:08     ` Lars Magne Ingebrigtsen
2012-04-10 21:25       ` Reiner Steib

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).