[email protected] wrote:
> Hi, although I don't have a pressing need at the moment, I was thinking 
> this morning about how to send mail to an account and have a script run 
> and take an action automatically. The trigger for this was that I get a 
> mail from time to time which needs me to confirm a valid email address by 
> following an html link.
> I would like to have this processed automatically, but I am unsure of the 
> best way to proceed. I could have a script run periodically and look at 
> the mail box designated for this and strip out the html link and follow it 
> with wget, or maybe to try and set up a pipe which mail can be delivered 
> to so a script would see the mail as input on std input.
> 
> Are either of these a good approach or is there a better way? My methods 
> are not exim specific I think, but maybe exim can handle things directly?
> 
> 
> Regards,
> Andrew.
> 
> Windows, for life without walls.
> Linux, for life without Windows.
> 
> 

Just use a filter. For example, I used to use this in system_filter for
Sophos alerts/updates (when they were sent out individually):

if $h_from: contains "Sophos Alert System" and
   $h_to: contains "[email protected]" and
   $h_subject: contains "Sophos Anti-Virus IDE alert" then
  unseen noerror pipe "/etc/exim/sophos_update"
endif

/etc/exim/sophos_update was a script which parsed the email message and
downloaded a file from the URL contained in the message.

-- 
Nigel Wade, System Administrator, Space Plasma Physics Group,
            University of Leicester, Leicester, LE1 7RH, UK
E-mail :    [email protected]
Phone :     +44 (0)116 2523548, Fax : +44 (0)116 2523555

-- 
## List details at http://lists.exim.org/mailman/listinfo/exim-users 
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/

Reply via email to