PHWinfo banniere

Titres
PORTAIL ANNUAIRE ARTICLES COMPARATEUR HÉBERGEURS DEVIS FORUMS RÉDUCTEUR D'URL
Précédent   PHWinfo > Forums Hébergement > Forum Logiciels d'hébergement > comp.mail.sendmail > OT: MIMEdefang and spamassassin/filter_end
S'inscrire FAQ Membres Recherche Messages du jour Marquer les forums comme lus
comp.mail.sendmail Configuring and using the BSD sendmail agent.

OT: MIMEdefang and spamassassin/filter_end

Réponse
 
LinkBack Outils de la discussion
Vieux 16/01/2007, 16h52   #1
J.O. Aho
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut OT: MIMEdefang and spamassassin/filter_end

There is a bit about mimedefang that I haven't got a grasp over and I haven't
managed to find an answer to what I'm trying to do, even if I have tried my
best at the mimedefang site and the wiki and of course google.com. Of course I
could join the maillist and ask there, but I'm all to lazy to join a maillist
for one question, so I hope someone here could push me in the right direction.

I have a somewhat modified filter_end which uses spamassassin to scan the mail
and I have added a check where I bounce the mail at once if the result is all
to high.

if ($hits >= 3 * $req) {
action_bounce("Sorry, we can't accept this spam.");
return;
}

This works fine, but there is a mailserver that forwards mail to me, there
aren't any spam prevention on the remote mailserver and I wish to have a lower
threshold on mails that are forwarded from that server

I would like to do something like this

if (($remote=="remote.example.net") && ($hits >= 2 * $req)) {
action_bounce("Sorry, we can't accept this spam.");
return;
}

But I'm not sure how I get the ip-name/ip-number of the remote server that
delivers the mail in the filter_end stage and I guess it won't just be to
modify the

sub filter_end {
my($entity) = @_;

to

sub filter_end {
my($entity,$ip) = @_;


Perl ain't my strong side and unsure about how everything works in mimedefang,
I would be happy if someone wrote a simple example how to do what I want, but
will be happy even with a link to a page that explains how to access different
values in filter_end.

Thanks in advance for your .


--

//Aho
  Réponse avec citation
Vieux 16/01/2007, 19h19   #2
Kees Theunissen
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: OT: MIMEdefang and spamassassin/filter_end

J.O. Aho wrote:
> I would like to do something like this
>
> if (($remote=="remote.example.net") && ($hits >= 2 * $req)) {
> action_bounce("Sorry, we can't accept this spam.");
> return;
> }
>



See the mimedefang-filter(5) manpage.


GLOBAL VARIABLES SET BY MIMEDEFANG.PL
The following global variables are set by mimedefang.pl and are
available for use in your filter. All of these variables are
always available to filter_begin, filter, filter_multipart
and filter_end. In addition, some of them are available in
filter_relay, filter_sender or filter_recipient. If this is
the case, it will be noted below.

[...]

$RelayHostname
The host name of the relay. This is the name of the host
which is attempting to send e-mail to your host. May
be "undef" if the host name could not be determined.
This variable is available in filter_relay, filter_sender
and filter_recipient.

$RelayAddr
The IP address of the sending relay (as a string consisting
of four dot-separated decimal numbers.) One potential use
of $RelayAddr is to limit mailing to certain lists to
people within your organization. This variable is available
in filter_relay, filter_sender and filter_recipient.




Regards,

Kees.


--
Kees Theunissen.
  Réponse avec citation
Vieux 16/01/2007, 20h03   #3
J.O. Aho
Aucun Avatar
 
Messages: n/a
Hébergeur:
Par défaut Re: OT: MIMEdefang and spamassassin/filter_end

Kees Theunissen wrote:
> J.O. Aho wrote:
>> I would like to do something like this
>>
>> if (($remote=="remote.example.net") && ($hits >= 2 * $req)) {
>> action_bounce("Sorry, we can't accept this spam.");
>> return;
>> }
>>

>
>
> See the mimedefang-filter(5) manpage.
>
> GLOBAL VARIABLES SET BY MIMEDEFANG.PL
> $RelayHostname
> $RelayAddr


Gosh, now I'm feeling stupid, thanks a lot for the .


--

//Aho
  Réponse avec citation
Réponse


Outils de la discussion

Règles de messages
Vous ne pouvez pas créer de nouvelles discussions
Vous ne pouvez pas envoyer des réponses
Vous ne pouvez pas envoyer des pièces jointes
Vous ne pouvez pas modifier vos messages

Les balises BB sont activées : oui
Les smileys sont activés : oui
La balise [IMG] est activée : oui
Le code HTML peut être employé : non
Trackbacks are oui
Pingbacks are oui
Refbacks are oui


Fuseau horaire GMT +1. Il est actuellement 02h01.


Édité par : vBulletin® version 3.7.3
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Friendly URLs by vBSEO 3.2.0 RC5 Tous droits réservés.
Version française #16 par l'association vBulletin francophone
PHWinfo est un site Éducation Sans Frontières ©2000-2008
Ad Management by RedTyger
©Tous droits réservés par les parties respectives
Page generated in 0,09661 seconds with 11 queries