MailScanner per user mail size limit

Brad Beckenhauer brad at beckenhauer.com
Fri Feb 24 03:13:32 GMT 2006


>>> Doron Shmaryahu<doron at crc.co.za> 2/23/2006 4:22:49 PM >>>

Hi,

I have MailScanner 4.50.15 running on a FreeBSD 4.11 machine. All is
working perfectly. I have read through the docs on creating per user
mail limits but until now I have still not been able to make it work. I
would like the rule file to control mail size limits for each user.

Are there any problems with this ?

Could someone provide me a example rule file or any hints/docs would be
appreciated.

Thanks in advance

Doron 
--

This shoudl work for you.
Create this file "MaximumAttachmentSize.rules" in your "rules" 
directory and modify your MailScanner.conf as noted.

#
# File Location/Name:
# %rules-dir%/MaximumAttachmentSize.rules
#
# This is where you can build a ruleslist
# that allows you to specify attachment size limits in bytes
#
# In MailScanner.conf change:
# "Maximum Attachment Size = -1"
# to
# "Maximum Attachment Size = %rules-dir%/MaximumAttachmentSize.rules"
#
# Example values, adjust as needed
# 1k    = 1024 bytes
# 10k   = 10240 bytes
# 100K  = 102400 bytes
# 1MB   = 1024000 bytes
# 10MB  = 10240000 bytes
# 100MB = 102400000 bytes
# 250MB = 256000000 bytes
# 500MB = 512000000 bytes
# 1GB   = 1024000000 bytes
#
# Size limits and Default should be smaller than the partition
# where they are temporarily stored. ;-)
#
# Set addresses/domains to be limited as follows:
# Direction     Pattern                   Size Limit
# From: user at good.domain.com   1024000  # Limit FROM specified user to 1MB
# From: *@friendly.domain.com    10240000 # Limit FROM specified domain to 10MB
# From: 123.234.567.2                  1024000  # Limit FROM IP address to 1MB
# From: 123.234.                          1024000  # Limit FROM IP range to 1MB
# From: /^192\.168\.13[4567]\./   1024000  # Limit FROM IP range to 1MB
# To:   abc at xyz.com                        0         # No Attachments allowed TO this user
# To:   *@yahoo.com                    1024000   # Limit all TO this Domain to 1MB
#
To: user1 at your.domain       102400   # Limit FROM specified user to 10Kbytes
To: user2 at your.domain     1024000   # Limit FROM specified user to 1MB
To: user3 at your.domain   10240000   # Limit FROM specified user to 10MB
FromOrTo:       default                -1   # Default, No attachment Size Checking.
-------------- next part --------------
Skipped content of type multipart/related


More information about the MailScanner mailing list