[Valvula] sql default limit per domain user in mquota

Kapetanakis Giannis bilias en edu.physics.uoc.gr
Lun Mar 26 13:30:17 CEST 2018


Hi,

I was wondering if the following change (not yet done) is interesting to your project.

Right now mod-mquota uses same limits for all domains.

I think it might be easy to make a change and add separate sql configuration per domain or even per user (in a domain).

I'm not talking about domain limits (all users) but specific user limits per domain or per user.

user1 at domain1.com: minute-limit=2, hour-limit=10, global-limit=100, etc
domain1.com: minute-limit=10, hour-limit=100, global-limit=1000, etc
domain2.com: minute-limit=20, hour-limit=200, global-limit=2000, etc

the plugin will check in a specific db table if the following exists:

a) check for user specific limits: db_sasl_user='user1 at domain1.com' -> return limits
b) check for global domain limits: db_sasl_user='%GLOBAL%@domain1.com' -> return limits
c) if nothing is found use default limits from config file

In advance the db limits can use the same label as in <limit label=/> to differentiate limits per time of day as in config.

If you agree on this I might find some time to do it since I need it in my setup.

Regards,

Giannis


Más información sobre la lista de distribución Valvula