[Mimedefang] Still outbound messages are getting blocked by spamassassin

Jeff Rife mimedefang at nabs.net
Fri Jul 9 13:53:03 EDT 2004


On 9 Jul 2004 at 10:41, Vivek Kumar wrote:

> sub filter_relay($$$){
>   my ($hostip,$hostname,$helo) = @_;
>   my $internal_net1 = "191.0.0";
>   my $internal_net2 = "191.0.1";
>   $hostip=~  /^(\d+\.\d+\.\d+)./ ;
>   my $mailip = $1;
>   if($mailip eq $internal_net1 || $mailip eq $internal_net2) {
>                 return("ACCEPT_AND_NO_MORE_FILTERING","It's from us it
> gotta
> be good");
>                 }
>   return("CONTINUE","");  
> }                                                                                 

I'm not a Perl guru, so I'm probably wrong, but wouldn't the following be 
a lot cleaner:

sub filter_relay($$$)
{
my ($hostip, $hostname, $helo) = @_;

if ($hostip =~ /^191\.0\.[01]\./)
  {
  return('ACCEPT_AND_NO_MORE_FILTERING', "It's from us");
  }

return('CONTINUE', "");
}


--
Jeff Rife        | "When I first heard that Marge was joining the 
SPAM bait:       |  police academy, I thought it would be fun and 
AskDOJ at usdoj.gov |  zany, like that movie: Spaceballs.  But instead 
uce at ftc.gov      |  it was dark and disturbing, like that movie: 
                 |  Police Academy." 
                 |         -- Homer Simpson 




More information about the MIMEDefang mailing list