2011-06-16 403 views
1

我在写一个订阅列表程序,它将电子邮件发送到大量地址列表。我已设法设置传出消息与自定义“答复”字段,如下所示:如何使电子邮件直接自动回复到不同的电子邮件地址?

mail.ReplyToList.Add("[email protected]"); 

而且工作正常。但是我也想处理的是人们设置休假消息或其他自动回复的人。现在,这些回应将转到“回复”地址。我想为autoresponders设置一个不同的地址,例如“[email protected]”。我知道这是可能的,因为像Yahoo Groups这样的讨论列表提供商能够很好地拦截那些人。但是如何?

编辑:这里是雅虎邮件标题(编辑)的样本。这封电子邮件来自雅虎服务器,发送到[email protected],并回复到[email protected] ...但自动回复/外出消息做去发件人@域。 COM;我的猜测是他们去了标题顶部附近的“返回路径”地址(发送到[email protected]hoo.com)。但是,如何在发送邮件时将该行添加到SMTP标头?

Delivered-To: [email protected] 
Received: by 10.52.161.7 with SMTP id xo7cs8544vdb; 
    Mon, 20 Jun 2011 01:25:51 -0700 (PDT) 
Received: by 10.236.184.134 with SMTP id s6mr5686752yhm.271.1308558351152; 
    Mon, 20 Jun 2011 01:25:51 -0700 (PDT) 
Return-Path: <[email protected]ps.yahoo.com> 
Received: from n40a.bullet.mail.sp1.yahoo.com (n40a.bullet.mail.sp1.yahoo.com [66.163.168.134]) 
    by mx.google.com with SMTP id bd10si13985607icb.130.2011.06.20.01.25.49; 
    Mon, 20 Jun 2011 01:25:50 -0700 (PDT) 
Received-SPF: pass (google.com: manual fallback record for domain of [email protected]ps.yahoo.com designates 66.163.168.134 as permitted sender) client-ip=66.163.168.134; 
Authentication-Results: mx.google.com; spf=pass (google.com: manual fallback record for domain of [email protected]ps.yahoo.com designates 66.163.168.134 as permitted sender) [email protected]turns.groups.yahoo.com; dkim=pass [email protected] 
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoogroups.com; s=lima; t=1308558349; bh=TWS7oJzaM8D+kqiNOGoc7ZTZZzJdtRBkRQUFvR4cPoc=; h=Received:Received:X-Yahoo-Newman-Id:Received:Received:Received:DKIM-Signature:Received:Received:Received:X-Sender:X-Apparently-To:X-Received:X-Received:X-Received:X-Received:Message-Id:To:X-Greylist:X-Originating-IP:From:X-eGroups-Approved-By:Sender:MIME-Version:Mailing-List:Delivered-To:List-Id:Precedence:List-Unsubscribe:Date:Subject:X-Yahoo-Newman-Property:Content-Type; b=GjEw2xlAEtRGKcvQgr/KBi86murpN1CfuR3ZQn3hGVnZuNPkbME1cshBe6d/nAnDZvIaynA5uIY+COQ65K6va21b/EP3CZV3HxqBXL68z+NqLeQ2wZekRxxHmqr3QtKw 
DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=lima; d=yahoogroups.com; 
b=DuQiSLNxiatDQUGAPVdsPchkteO8MLqgI77xHN/YVtZjwF2CuHpEI2jOaqIfrYRuNHyoLdB1tdux09ne3g3kOgxuUJzKDuVTveJX1thZAh85zm+nY4Yfi9Jk2XTvxKCM; 
Received: from [69.147.65.150] by n40.bullet.mail.sp1.yahoo.com with NNFMP; 20 Jun 2011 08:25:49 -0000 
Received: from [66.196.94.60] by t7.bullet.mail.sp1.yahoo.com with NNFMP; 20 Jun 2011 08:25:49 -0000 
X-Yahoo-Newman-Id: 74624151-m351 
Received: (qmail 4862 invoked from network); 20 Jun 2011 08:25:43 -0000 
Received: from unknown (66.196.94.106) 
by m10.grp.re1.yahoo.com with QMQP; 20 Jun 2011 08:25:43 -0000 
Received: from unknown (HELO ng5-ip2.bullet.mail.bf1.yahoo.com) (98.139.165.28) 
by mta2.grp.re1.yahoo.com with SMTP; 20 Jun 2011 08:25:43 -0000 
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoogroups.com; s=lima; t=1308558343; bh=LLk0YVSQWNR1bJTbWtNZJr/n97ny4ZS2B4qKl82nrPg=; h=Received:Received:Received:X-Sender:X-Apparently-To:X-Received:X-Received:X-Received:X-Received:Message-Id:MIME-Version:To:Date:Content-Type:X-Greylist:X-Originating-IP:From:Subject:X-Yahoo-Group-Post:X-YGroups-SubInfo:Sender:X-Yahoo-Newman-Property:X-eGroups-Approved-By:X-eGroups-Auth; b=m0Z2uG7aoojJE9tTdpY/zABz5r0QhXhwFAIghnFAqMqHqeC7QRUqV18xpxsJ0S/W1ZB3/+5vjPaTsWLWNoUTtmzYiq8LIyikU7nMnu94f6xtGoC3BkJjDuwxJNlx+pyk 
Received: from [98.139.164.124] by ng5.bullet.mail.bf1.yahoo.com with NNFMP; 20 Jun 2011 08:25:43 -0000 
Received: from [69.147.65.150] by tg5.bullet.mail.bf1.yahoo.com with NNFMP; 20 Jun 2011 08:25:43 -0000 
Received: from [98.137.34.155] by t7.bullet.mail.sp1.yahoo.com with NNFMP; 20 Jun 2011 08:25:43 -0000 
X-Sender: [email protected] 
X-Apparently-To: [email protected] 
X-Received: (qmail 91008 invoked from network); 20 Jun 2011 08:19:21 -0000 
X-Received: from unknown (66.196.94.106) 
by m17.grp.re1.yahoo.com with QMQP; 20 Jun 2011 08:19:21 -0000 
X-Received: from unknown (HELO server.somedomain.com) (1.2.3.4) 
by mta2.grp.re1.yahoo.com with SMTP; 20 Jun 2011 08:19:21 -0000 
X-Received: from anotherserver (4.3.2.1) 
(authenticated bits=0) 
by server.somedomain.com (1.2.3.4) with ESMTP id p5K8JKjq020377 
for <[email protected]>; Mon, 20 Jun 2011 03:19:21 -0500 
Message-Id: <[email protected]> 
To: [email protected] 
X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.2.3 (someserver.somedomain.com [6.5.4.3]); Mon, 20 Jun 2011 03:19:21 -0500 (CDT) 
X-Originating-IP: 8.7.6.5 
From: "Mr Sender" <[email protected]> 
Sender: [email protected] 
MIME-Version: 1.0 
Mailing-List: list [email protected]; contact [email protected] 
Delivered-To: mailing list [email protected] 
List-Id: <listname.yahoogroups.com> 
Precedence: bulk 
List-Unsubscribe: <[email protected]> 
Date: 20 Jun 2011 11:19:23 +0300 
Subject: [Listname] test 
+3

我在猜测雅虎等人通过扫描邮件中的“不在办公室”,“在度假”,“当我回来时”这样的短语来做到这一点......这将使它类似于垃圾邮件过滤(来自技术视角)。 – David 2011-06-16 19:30:35

+0

@David - 但是当您发送到雅虎列表时,电子邮件将以“回复”地址作为原始发件人到达,而不是[email protected]地址。他们是如何让自动回复器将其自动回复发送回yahoogroups.com而不是发送给原始邮件发件人的? – 2011-06-16 19:44:55

+0

我不知道可以在你的(外发)电子邮件中设置它 - 或者我应该说我不知道​​如何去做。 我假设雅虎,Google等做的是有一个过程来监控*回复地址的消息,并且这些(入站)消息根据其内容处理不同。我刚刚意识到的是@ButFinder的回应。 (注意自我:滚动前打字:) – David 2011-06-17 02:21:12

回答

0

对不起,朋友。我不认为SMTP支持这种类型的请求。正如评论中指出的,雅虎很可能通过过滤器在他们的电子邮件服务器中实现这一点

+0

请参阅我的编辑 - 雅虎成功;我只需要重复他们的工作。 – 2011-06-20 12:23:50

+0

我不太确定,但看看这是否有帮助:http://stackoverflow.com/questions/464876/sending-an-email-with-the-header-return-path-using-windows-virtual邮件服务器 – mtazva 2011-06-20 21:21:46

3

通常,这是通过处理返回的邮件完成的 - 例如,Outlook规则或其他什么,SMTP不区分自动回复和正确的电子邮件。

+0

请参阅我的编辑 - 雅虎成功;我只需要重复他们的工作。 – 2011-06-20 12:23:36

+0

你试过把它作为头添加吗? – BugFinder 2011-06-20 12:59:08

+0

这是我的问题 - 你怎么做? – 2011-06-20 13:53:45