Page MenuHomePhabricator

Inbound Email Reply-to not set correctly
Closed, InvalidPublic

Description

Phabricator Version:

phabricator 8640ab5fc3e450efdbca4adb3601c7e60f048e36 (Tue, Dec 20) 
arcanist  fad85844314b151994769a461825c90f7400c145 (Oct 22 2016) 
phutil 5ac2ca1214890d865bc57fab2715a322fdf02ab6 (Tue, Dec 6)

The tasks or replys that are created by inbound email have wrong reply-to address, when the are received:

./bin/mail show-outbound --id xxx

PROPERTIES
ID: 3377
Status: sent
Related PHID: PHID-TASK-ng3rpl2sfgeaoxfvxo7b
Message: 

PARAMETERS
sensitive: 
subject: T130: Allow inbound emails in Phabriactor
from: PHID-USER-dlohd2f75zs42yh4lgev
subject-prefix: [Maniphest]
vary-subject-prefix: [Commented On]
thread-id: maniphest-task-PHID-TASK-ng3rpl2sfgeaoxfvxo7b
is-first-message: 
exclude: []
herald-force-recipients: []
mailtags: ["maniphest-comment"]
is-bulk: 1
parent-message-id: <1473d325-aa3b-fbd0-6322-5442ed1473b9@xxxx>
reply-to: T130+4+7d1cacf6ca5a006f@xxxxx
cc: ["PHID-USER-xiuxd5sm6x6vkaoo2s4x"]
actors.sent: {"PHID-USER-dlohd2f75zs42yh4lgev":{"deliverable":true,"reasons":[]},"PHID-USER-xiuxd5sm6x6vkaoo2s4x":{"deliverable":true,"reasons":[]}}
routing.sent: null
routingmap.sent: []

Shows the right reply-to but the email received as a reply from Phabaricator server has wrong reply to "phabricator@xxxx".

Event Timeline

pouyana renamed this task from Inbound Email ReplayTo not set correctly to Inbound Email Replay-to not set correctly.Jan 5 2017, 1:52 PM
pouyana created this task.

So, just some insight, I use postfix as mail server and for catch all mail (@domain) I used the canonical approach. This results the error above. Using virtual as described here will solve this problem.

Please read Contributing Bug Reports carefully, specifically we require a complete, easy to follow and under.stand, set of steps to reproduce the problem. I also don't understand what you're saying the bug in Phabricator is.

pouyana renamed this task from Inbound Email Replay-to not set correctly to Inbound Email Reply-to not set correctly.Jan 5 2017, 3:54 PM
pouyana updated the task description. (Show Details)

Sorry for the typos :D, Step by Step Guide:
Follow this: https://secure.phabricator.com/book/phabricator/article/configuring_inbound_email/#local-mta-installing-mai (Local MTA Section)

  1. Using postfix instead of sendmail
  2. To have the last part (Forward all mail to @yourdomain.com to the Phabricator processing script.) I used the canonical method by postfix. This will rewrite the sent email address to phabricator@yourdomain.com
  3. Send an email to the T130+4+7d1cacf6ca5a006f@yourdomain.
  4. Phabricator outbound email reply-to (reply to an email from inbound) is rewritten as phabricator@yourdomain. So T130+4+7d1cacf6ca5a006f@yourdomain is not used.

I suspect that phabricator uses the inbound email address to set the reply-to field instead of any internal function. I don't know if it is bug or feature.
Using virtual addresses instead of canonical in postfix solve this problem. With virtual addresses the email will be only forwarded to phabricator@domain without any changes in header. As a result the inbound email address stays the T130+4+7d1cacf6ca5a006f@yourdomain.

This is very complex and explaining it, is a little bit hard. Hopefully there is enough information here.

Using postfix instead of sendmail

Can you point out where we have instructions for postfix support? I can't immediately find "postfix" anywhere in that document.

Yeah, There is no postfix, but my distro (SUSE Linux Enterprise) sendmail is a postfix variant. I have to match your sendmail config to my postfix. The last part was done with the help of canonical which is wrong way to do it probably. If it is too much work to debug this just drop it. It seems to be a very special case of configuration, server variant.

This is far afield from an actionable bug report.