<?xml version="1.0" encoding="utf-8"?>
<feed xml:lang="en" xmlns="http://www.w3.org/2005/Atom"><title>Recent changes to 193:  Prevent auto reply to alias forwarded messages</title><link href="https://sourceforge.net/p/webadmin/feature-requests/193/" rel="alternate"/><link href="https://sourceforge.net/p/webadmin/feature-requests/193/feed.atom" rel="self"/><id>https://sourceforge.net/p/webadmin/feature-requests/193/</id><updated>2012-08-06T16:35:44Z</updated><subtitle>Recent changes to 193:  Prevent auto reply to alias forwarded messages</subtitle><entry><title> Prevent auto reply to alias forwarded messages</title><link href="https://sourceforge.net/p/webadmin/feature-requests/193/" rel="alternate"/><published>2012-08-06T16:35:44Z</published><updated>2012-08-06T16:35:44Z</updated><author><name>Anonymous</name><uri>https://sourceforge.net/u/userid-None/</uri></author><id>https://sourceforge.netf1365faf95382c208ae2efc90bf6aff3773313fc</id><summary type="html">&lt;div class="markdown_content"&gt;&lt;p&gt;Auto reply is not always a good idea when the message was sent to an alias address and forwarded to some mailbox.&lt;br /&gt;
For instance, one sends an email to dep@mycompany.com. It's not desirable that it receives a reply from guyinvactions@mycompany.com&lt;/p&gt;
&lt;p&gt;I achieved that editing&lt;br /&gt;
/etc/webmin/virtual-server/autoreply.pl&lt;br /&gt;
and writing the folowing code:&lt;br /&gt;
79,87d78&lt;br /&gt;
&amp;lt; # v v algol 2012-08-01 v v #&lt;br /&gt;
&amp;lt; # If it's a forwared message&lt;br /&gt;
&amp;lt; if ( not ($header{'x-original-to'} eq $ARGV[1] ||&lt;br /&gt;
&amp;lt;           $header{'x-original-to'} =~ /^([_a-zA-Z0-9-]+(\.[_a-zA-Z0-9-]+)*@[a-zA-Z0-9-]+(\.[a-zA-Z0-9-]+)*\.(([0-9]{1,3})|([a-zA-Z]{2,3})|(aero|coop|info|museum|name)))$/ &amp;amp;&amp;amp; $1 eq $ARGV[1]) ) {&lt;br /&gt;
&amp;lt;       # Do nothing if not for me&lt;br /&gt;
&amp;lt;       print STDERR "Not autoreplying to forwarded message\n";&lt;br /&gt;
&amp;lt;       exit 0;&lt;br /&gt;
&amp;lt;       }&lt;br /&gt;
&amp;lt; # ^ ^ algol ^ ^ #&lt;/p&gt;
&lt;p&gt;But that file is rewritten every time virtualmin is restarted and maybe it would be a good feature to have a configuration option.&lt;/p&gt;&lt;/div&gt;</summary></entry></feed>