Bhagwan Gupta wrote:
Take three E-mail ids one(_at_)yahoo(_dot_)com
<http://mail.yahoo.com/config/login?/ym/Compose?To=one(_at_)yahoo(_dot_)com>,
two(_at_)consulting(_dot_)com
<http://mail.yahoo.com/config/login?/ym/Compose?To=two(_at_)consulting(_dot_)com>,
three(_at_)bullhorn(_dot_)com
<http://mail.yahoo.com/config/login?/ym/Compose?To=three(_at_)bullhorn(_dot_)com>.
Aim is, whatever mail is coming from one(_at_)yahoo(_dot_)com
<http://mail.yahoo.com/config/login?/ym/Compose?To=one(_at_)yahoo(_dot_)com> to
two(_at_)consulting(_dot_)com
<http://mail.yahoo.com/config/login?/ym/Compose?To=two(_at_)consulting(_dot_)com>
it will be redirected to three(_at_)bullhorn(_dot_)com
<http://mail.yahoo.com/config/login?/ym/Compose?To=three(_at_)bullhorn(_dot_)com>
(where the three(_at_)bullhorn(_dot_)com
<http://mail.yahoo.com/config/login?/ym/Compose?To=three(_at_)bullhorn(_dot_)com>
will see that the mail is coming to him only i,e in that mail "From"
field will have one(_at_)yahoo(_dot_)com
<http://mail.yahoo.com/config/login?/ym/Compose?To=one(_at_)yahoo(_dot_)com> and
"To" field will have three(_at_)bullhorn(_dot_)com
<http://mail.yahoo.com/config/login?/ym/Compose?To=three(_at_)bullhorn(_dot_)com>
*2)* As a Second solution Procmail was used and a script was written
in .procmailrc file,
:0
* !^X-Loop:two(_at_)consulting(_dot_)com
|formail -i "To:three(_at_)bullhorn(_dot_)com" | /usr/bin/sendmail -oi -t
also .qmail was configured to use procmailrc file, but now the problem
was, everything is done but the sender of the mail is getting a bounce
back message saying “This mail is looping so the delivery was
stopped”, though the receiver is getting the mail as per our
requirement.I dont want this bounce back message to go there.
Can you suggest any solution for my problem??
While you check for the X-Loop header, you do not actually add an X-Loop
header so the test never matches. From the description of your problem
it sounds like
:0
* ^From:(_dot_)*one(_at_)yahoo(_dot_)com
* ^TO(_dot_)*two(_at_)consulting(_dot_)com
! three(_at_)bullhorn(_dot_)com
should be sufficient, assuming that bullhorn.com accepts the mail
locally and does not send it back.
--
Klaus Johannes Rusch
KlausRusch(_at_)atmedia(_dot_)net
http://www.atmedia.net/KlausRusch/
____________________________________________________________
procmail mailing list Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail