[Mimedefang] Re: $CcAdministrator
Mickey Hill
mickey at rudolphtire.com
Mon Apr 29 14:28:12 EDT 2002
> Well, you could do this in your filter:
>
> if ($something) {
> action_notify_sender("You bad person, you!");
> action_notify_administrator("I told sender: You bad
> person, you!");
> }
I knew you would have a better way to do it. :)
Here's another request along the same lines: How about a way to
customize the subject and the prepended text in the email that
action_notify_sender sends? Something similar to $GeneralWarning that
has a default value, but can be changed in mimedefang-filter. Again,
maybe you've got a better idea, but I'm thinking about something in
mimedefang.pl like:
use vars qw($NotifySenderSubject $NotifySenderWarning);
if (!defined($NotifySenderSubject)) {
$NotifySenderSubject = 'MIMEDefang Notification.';
}
if (!defined($NotifySenderWarning)) {
$NotifySenderWarning =
"An e-mail you sent with message-id $MessageID\n" .
"was modified by MIMEDefang. ($URL).\n\n" .
"The recipients were:";
my($recip);
foreach $recip (@Recipients) {
$NotifySenderWarning .= " $recip";
}
$NotifySenderWarning .= "\n\n";
if (-r "NOTIFICATION") {
$NotifySenderWarning .= "Here are the details of the
modification:\n\n";
}
}
# Send notification to sender, if required
if ($Sender ne '<>' && -r "NOTIFICATION") {
my($body);
$body = "From: $DaemonName <$DaemonAddress>\n";
$body .= "To: $Sender\n";
$body .= "Subject: $NotifySenderSubject\n\n";
$body .= $NotifySenderWarning;
if (open(FILE, "<NOTIFICATION")) {
while(<FILE>) {
$body .= $_;
}
close(FILE);
}
sendmail($DaemonAddress, $DaemonName, $Sender, $body);
}
-------------------------
Mickey Hill
Rudolph's Inc
2021 Rob Mason Rd
PO Box 69
Murray KY 42071 USA
Phone (270) 753-0686 x124
Fax (270) 753-0753
mickey at rudolphtire.com
www.rudolphtire.com
More information about the MIMEDefang
mailing list