Hi,

Dovecot has a new feature that can set a flag in the userdb "quota_over_flag"

http://wiki2.dovecot.org/Quota/Configuration#Overquota-flag_.28v2.2.16.2B-.29

I want to use this to reject messages during SMTP conversation for users that
are over quota. I keep this flag in MySQL. I could very easy add it to my
virtual_mailbox_maps sql lookup query but rejection would be something
like "no such user acccount" which is misleading.

If possible would like to avoid two database lookups but in postfix I don't
know of a way to change reject message based on this flag or make postfix
remember this flag's value for later. Only way I can think to implement this
is a separate smtpd restriction class that makes another sql lookup to
check the quota_over_flag value(?)

Has anyone tried this yet or can anyone provide an example? 

by the way, I won't care about aliases, they will still attempt delivery
and cause a bounce if over quota.

TIA, ed

Reply via email to