Re[2]: [Exim] Rejectin' mail a-la postfix header_checks rege…

Top Pagina
Delete this message
Reply to this message
Auteur: Philip Hazel
Datum:  
Aan: Sharun
CC: exim-users
Onderwerp: Re[2]: [Exim] Rejectin' mail a-la postfix header_checks regexp
On Tue, 6 Nov 2001 Sharun@??? wrote:

> Timeout between errored input (like rcpt to: <uknown@???>) and
> 4xx or 5xx error message to stdout. Main goal is slow down "bad"
> clients


Exim 4 allows delays between multiple MAIL and RCPT commands, whether
they are good or bad. I would like to see how this works before adding
anything else.

> You mean i can say:
> if dst_domain matches local_domain then max_recipients++ ?


More or less. What you can say is "if domain is in this list and number
of recipients is greater than x, reject this RCPT". However, what you
cannot test is "number of recipients _in this domain_". The only count
available is the total number of recipients of the message.

> if ( strstr(receiver,"@ukr.net") != NULL )
>     {
>         if ( strlen(strstr(receiver,"@ukr.net")) == 8 ) rcpts_local_count++;
>     }


In other words, you can't do that. In Exim 4, there is no built-in
concept of "local_domains" any more.

However, you can add this kind of code without patching Exim 4. It has
the ability for you to link in a C function of your own that is run
after the message has been received, just before the final response.

But then you can only accept or reject the entire message, not
individual recipients.


-- 
Philip Hazel            University of Cambridge Computing Service,
ph10@???      Cambridge, England. Phone: +44 1223 334714.