[exim] Rate limiting CIDR networks

Página superior
Eliminar este mensaje
Responder a este mensaje
Autor: Darek M
Fecha:  
A: exim-users
Asunto: [exim] Rate limiting CIDR networks
Hi there, I'm completely new to Exim and trying to use it because it
appears to support rate limiting that would work for me.

I'm envisioning having a file in the form of
1.2.3.0/29 1000
...

which would mean that the /29 network can send 1000 messages per day.
Whatever messages 1.2.3.2 and 1.2.3.4 sent would count towards the
same daily limit.

I was following some of the documentation, but some of the examples
leave me with questions. For example
(http://gd.tuwien.ac.at/.vhost/exim.org/exim-html-current/doc/html/spec_html/ch40.html#useratlim)

     ratelimit = ${lookup {$sender_host_address} \
                   cdb {DB/ratelimits.cdb} \
                   {$value} {RATELIMIT} }


Looks like my ticket, but I don't know whether RATELIMIT is a
constant. Are $sender_host_address and $value returned from the
"lookup" search?

Though I think that I would need the iplsearch lookup type, as it
supports CIDR notation. So can I replace iplsearch in place of lookup
and use the same syntax? The docs say that iplsearch is a single key
lookup type, so I assume that when I run a lookup, the return value
will be a number for daily limit, and nothing if no match is found.

I'd appreciate any pointers.

- Darek