Community Discussions and Support
N00b question: Outgoing mail size / filter

I see you have also had to avoid it.
I was hoping to set up this response :-

With reference to your message with the subject:
   "~S"
   that you attempted to send to : ~OR

 

<p>I see you have also had to avoid it. I was hoping to set up this response :-</p><p>With reference to your message with the subject:    "~S"    that you attempted to send to : ~OR </p><p> </p>

I see the help mentions

  • Supports ESMTP size restrictions

    for controlling the size of incoming mail

 I recently had cause to scour Help, Google etc looking for how to filter outgoing mail.
 ( A fool user sent a 24Mb attachment which bounced against some 15Mb limit)

1.  I could not find a setting in Mercury.  Is there one ?

2.  Can this be controlled by a filter or policy ?
     If so, some pointers would be good.
     All items spotted so far apply to header info.
     I'm looking for something to check attachments.

BTW:  A Google hit showed some old V1.4 setting called size (for MercuryS)

  # size:       1500000       #

Maximum message size to accept

  Not present in my V4.01 MERCURY.INI

 


I see the help mentions <ul><li><font color="#333399">Supports ESMTP <b style="color: black; background-color: rgb(255, 153, 153);">size</b> restrictions</font> for controlling the <b style="color: black; background-color: rgb(255, 153, 153);">size</b> of incoming <b style="color: black; background-color: rgb(160, 255, 255);">mail</b></li></ul><p> I recently had cause to scour Help, Google etc looking for how to filter outgoing mail.  ( A fool user sent a 24Mb attachment which bounced against some 15Mb limit)</p><p>1.  I could not find a setting in Mercury.  Is there one ?</p><p>2.  Can this be controlled by a filter or policy ?      If so, some pointers would be good.      All items spotted so far apply to header info.      I'm looking for something to check attachments.</p><p> BTW:  A Google hit showed some old V1.4 setting called size (for MercuryS)   # <b style="color: black; background-color: rgb(255, 153, 153);">size</b>:       1500000       # Maximum <b style="color: black; background-color: rgb(153, 255, 153);">message</b> <b style="color: black; background-color: rgb(255, 153, 153);">size</b> to accept </p><p>  Not present in my V4.01 MERCURY.INI</p><p> </p>

[quote user="Methuselah"]I see the help mentions

  • Supports ESMTP size restrictions

    for controlling the size of incoming mail

 I recently had cause to scour Help, Google etc looking for how to filter outgoing mail.
 ( A fool user sent a 24Mb attachment which bounced against some 15Mb limit)

1.  I could not find a setting in Mercury.  Is there one ?

 

Yes in the MercuryS configuration you'll find a ESMTP SIZE setting.  From the help:

ESMTP maximum size  If non-zero, the maximum size message MercuryS should accept from compliant ESMTP clients. MercuryS will advertise this via the ESMTP SIZE keyword. Not all clients, even ESMTP clients, will honour this setting.

2.  Can this be controlled by a filter or policy ?

 
There is a "Message size" type filter.


     If so, some pointers would be good.
     All items spotted so far apply to header info.
     I'm looking for something to check attachments.

BTW:  A Google hit showed some old V1.4 setting called size (for MercuryS)

  # size:       1500000       #

Maximum message size to accept

  Not present in my V4.01 MERCURY.INI

 Check the {MercuryS] section, this has been available since v3 at least and probably since the ESMTP SIZE came out.


 

 


[/quote]
[quote user="Methuselah"]I see the help mentions <ul><li><font color="#333399">Supports ESMTP <b style="color: black; background-color: rgb(255, 153, 153);">size</b> restrictions</font> for controlling the <b style="color: black; background-color: rgb(255, 153, 153);">size</b> of incoming <b style="color: black; background-color: rgb(160, 255, 255);">mail</b></li></ul><p> I recently had cause to scour Help, Google etc looking for how to filter outgoing mail.  ( A fool user sent a 24Mb attachment which bounced against some 15Mb limit)</p><p>1.  I could not find a setting in Mercury.  Is there one ?</p><p> </p><p>Yes in the MercuryS configuration you'll find a ESMTP SIZE setting.  From the help:</p><p>ESMTP maximum size  If non-zero, the maximum size message MercuryS should accept from compliant ESMTP clients. MercuryS will advertise this via the ESMTP SIZE keyword. Not all clients, even ESMTP clients, will honour this setting. </p><p>2.  Can this be controlled by a filter or policy ?</p><p>  There is a "Message size" type filter.</p><p>      If so, some pointers would be good.      All items spotted so far apply to header info.      I'm looking for something to check attachments.</p><p> BTW:  A Google hit showed some old V1.4 setting called size (for MercuryS)   # <b style="color: black; background-color: rgb(255, 153, 153);">size</b>:       1500000       # Maximum <b style="color: black; background-color: rgb(153, 255, 153);">message</b> <b style="color: black; background-color: rgb(255, 153, 153);">size</b> to accept </p><p>  Not present in my V4.01 MERCURY.INI</p><p> Check the {MercuryS] section, this has been available since v3 at least and probably since the ESMTP SIZE came out.</p><p>  </p><p> </p> [/quote]

I put these rules in my OUTGOING rule filter.

 

Label "CHECK_SIZE"
# General Limit
If header "S" contains "OVERSIZE" Return ""       => This provides a means to override the filter if required
If size > 10000000 Call "OVERSIZE"               => This is my arbitrary limit that works with most servers now
# Special Limits
If header "CT" contains "mail.small.limit.server.com" LogicalAnd ""         => This is a specific server we send to that has a 4MB limit
If size > 4194304 Call "OVERSIZE"
Always Return ""
#
Label "OVERSIZE"
Always Dialog "OVERSIZE - moved to BLACKHOLE"                 =>  This puts a msg in the system log telling me what has happened
Always SendTemplate "C:\\MERCURY\\MERCURY\\oversize.mer"    => This replies to the sender informing them that they are stupid [6]
                                                                                                  (and how to get around the limit if they know the recieving server will accept.)
Always Move "blackhole"                            =>  This moves the mail to a suspence account for review / forwarding
Always Return ""
 

<p>I put these rules in my OUTGOING rule filter.</p><p> </p><p>Label "CHECK_SIZE" # General Limit If header "S" contains "OVERSIZE" Return ""       => This provides a means to override the filter if required If size > 10000000 Call "OVERSIZE"               => This is my arbitrary limit that works with most servers now # Special Limits If header "CT" contains "mail.small.limit.server.com" LogicalAnd ""         => This is a specific server we send to that has a 4MB limit If size > 4194304 Call "OVERSIZE" Always Return "" # Label "OVERSIZE" Always Dialog "OVERSIZE - moved to BLACKHOLE"                 =>  This puts a msg in the system log telling me what has happened Always SendTemplate "C:\\MERCURY\\MERCURY\\oversize.mer"    => This replies to the sender informing them that they are stupid [6]                                                                                                   (and how to get around the limit if they know the recieving server will accept.) Always Move "blackhole"                            =>  This moves the mail to a suspence account for review / forwarding Always Return ""  </p>

Hey DLN.

  "C:\\MERCURY\\MERCURY\\oversize.mer"

Under 4.51, are you able to respond with the original, intended recipient?
I find that the "~T" value is the sender to respond to, and "~R" is blank.

Best I could come up with was to reflect "~M", the whole message.

 

 

<p>Hey DLN.</p><p>  "C:\\MERCURY\\MERCURY\\oversize.mer"</p><p>Under 4.51, are you able to respond with the original, intended recipient? I find that the "~T" value is the sender to respond to, and "~R" is blank.</p><p>Best I could come up with was to reflect "~M", the whole message.</p><p> </p><p> </p>

This is the content of my template 'oversize.mer'

I used 'oversize' in the subject as an override b/c it is hard to add special headers in Outlook [8o|]

 

 

From: Mail Delivery System <postmaster@~n>
To: ~T
Date: ~D
Subject: Delivery failure notification
MIME-Version: 1.0
Content-Type: Multipart/Report; boundary=~Y

--~Y
Content-type: Text/plain; charset=US-ASCII
Content-description: Mail delivery failure report
Content-disposition: Inline

With reference to your message with the subject:
   "~S"

The local mail transport system has reported the following problems
it encountered while trying to deliver your message:

-------------------------------------------------------------------
The Message is too large. Please reduce the size of the mail and try again.
-------------------------------------------------------------------
If you know the receiving server will accept the mail
put 'OVERSIZE' in the SUBJECT Line to override restriction.
-------------------------------------------------------------------

 
 

&lt;p&gt;This is the content of my template &#039;oversize.mer&#039;&lt;/p&gt;&lt;p&gt;I used &#039;oversize&#039; in the subject as an override b/c it is hard to add special headers in Outlook&amp;nbsp;[8o|]&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;p&gt;From: Mail Delivery System &amp;lt;postmaster@~n&amp;gt; To: ~T Date: ~D Subject: Delivery failure notification MIME-Version: 1.0 Content-Type: Multipart/Report; boundary=~Y --~Y Content-type: Text/plain; charset=US-ASCII Content-description: Mail delivery failure report Content-disposition: Inline With reference to your message with the subject: &amp;nbsp;&amp;nbsp; &quot;~S&quot; The local mail transport system has reported the following problems it encountered while trying to deliver your message: ------------------------------------------------------------------- The Message is too large. Please reduce the size of the mail and try again. ------------------------------------------------------------------- If you know the receiving server will accept the mail put &#039;OVERSIZE&#039; in the SUBJECT Line to override restriction. ------------------------------------------------------------------- &lt;/p&gt;&lt;p&gt;&amp;nbsp; &amp;nbsp;&lt;/p&gt;
live preview
enter atleast 10 characters
WARNING: You mentioned %MENTIONS%, but they cannot see this message and will not be notified
Saving...
Saved
With selected deselect posts show selected posts
All posts under this topic will be deleted ?
Pending draft ... Click to resume editing
Discard draft