Re: [Exim] Max mail size per user?

Startseite
Nachricht löschen
Nachricht beantworten
Autor: Dave C.
Datum:  
To: Marc MERLIN
CC: Philip Hazel, 'exim-users@exim.org'
Betreff: Re: [Exim] Max mail size per user?
On Fri, 21 Jul 2000, Marc MERLIN wrote:

> On Fri, Jul 21, 2000 at 08:41:49PM +0100, Philip Hazel wrote:
> > On Thu, 20 Jul 2000, Marc MERLIN wrote:
> >
> > > I can set the maximum mail size with message_size_limit, but is there a way
> > > to disable it for a specific user or group of users?
> > > Better yet, a database of From emails and associated max allowable mail
> > > size to override the default.
> >
> > max_size_per_user:
> >   driver = smartuser
> >   condition = ${if >{$message_size}\
> >     {${lookup{$local_part}lsearch{/some/file}{$value}{5M}}}{yes}{no}} 
> >   new_address = :fail: Message too big for $local_part

> >
> > This does mean you have to accept the message, because this happens 
> > during delivery. The global message_size_limit will block mail from 
> > entering your host.    

>
> Thanks for this trick, I may end up using that too.
>
> I apologize for not being more specific, what I was initially trying to do
> was to prevent people from sending big Emails.
> I suppose I can hack something up in the remote_smtp transport, but I'm
> guessing that the message will be accepted and then bounced.
> It'd be better if I could reject a message that's too big while it's being
> sent to my SMTP server by the client (either by looking at SIZE if it's
> there, or after DATA has been transmitted) so that the offending user knows
> about the problem right away and doesn't leave and bitch the next day that
> his/her important Email didn't go through.


message_size_limit is the only way to do that - but obviously will not
do per-user..

How many different limits do you want? If there is one 'general limit'
and then a few specific users that have a higher limit, you could set
message_size_limit to the smaller size, and then run a seperate daemon
(with SMTP_AUTH to permit only specific users), wtih the large
message_size_limit...




>
> Thanks,
> Marc
>


--