[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: smtpmail.el, user-mail-address and posting styles
From: |
Simon Josefsson |
Subject: |
Re: smtpmail.el, user-mail-address and posting styles |
Date: |
Fri, 25 Jun 2004 13:02:10 +0200 |
User-agent: |
Gnus/5.110003 (No Gnus v0.3) Emacs/21.3.50 (gnu/linux) |
Matthias Riese <mri.news200406@rieseIT.de> writes:
> Hi,
>
> It seems smtpmail.el ignores the posting styles when issuing the "MAIL FROM:"
> and uses the global value of user-mail-address instead of the address set via
> posting styles.
>
> This is a problem because AFAICS the Return-Path is set to the
> address from the "MAIL FROM:".
>
> I use something like this:
>
> (setq gnus-posting-styles
> '(
> ; Default style for mail
> ("^nnml:"
> (address "email@address.de")
> (signature-file "~/Mail/signature.default"))))
>
> When I try to send mail, smtpmail generates the address of MAIL FROM
> from my login name and local host name. When I
>
> (setq user-mail-address "email@address2.de")
>
> smtpmail.el always uses "email@address2.de" and never "email@address.de".
>
> Something wrong with my posting styles or is it a bug in smtpmail.el?
You could try setting the smtpmail variable in the posting style:
(setq gnus-posting-styles
'(
; Default style for mail
("^nnml:"
(address "email@address.de")
(user-mail-address "email@address.de")
(signature-file "~/Mail/signature.default"))))
Emacs smtpmail.el in CVS can be configured to use the From: line in
MAIL FROM, try:
(setq mail-specify-envelope-from t
mail-envelope-from 'header)
The reason this isn't the default is that MAIL FROM and From: really
are distinct things, and it isn't clear whether which approach is more
common. E.g., either MAIL FROM needs to be user-mail-address for
authentication purposes etc and From: can be anything, or that MAIL
FROM should be the same as the From: line, for privacy reasons etc.
In this case, backwards compatibility was the deciding factor.