procmail
[Top] [All Lists]

Re: force maximum mailbox size limit

2000-11-09 18:02:00
Philip offered some tweaks:

| The 'standard' way of hashing spool directories repeats the last letter
| if the username is too short ...

Oh!  I'd never heard that.  This matter has come up before, and I've sug-
gested padding with colons before, and nobody had corrected that until you
did now, Philip.  Thanks for the enlightenment.

| For the obnoxiously picky: under the assumption that the message is
| being delivered to an mbox-style mailspool, you need to add 1 to the
| message length for each line beginning with "From " as they'll be
| changed into ">From ".

Ah; you see, I was thinking in terms of their already being that way, but
of course they wouldn't be (or a raw-mode write would be impossible).

|       # positive difference means box would get bigger than
|       # forty million bytes
|       :0
|       * $ $MAILBOX_SIZE_^0
|       * 1^1 >1
|       * 1^1 ^From( )

Well, let's make that

        * 1^1 B ?? ^From( )

or add a `B' flag to the colon line (it won't affect the size condition).

|       * -40000000^0
|       { rejection routine goes here }

because of what Philip brought up here:

| That's actually off by one because it counts the "From " at the top of
| the header, so you should increase the constant in the last condition
| by one if you're feeling fanatical...

I'd rather restrict the ^From( ) condition to the body than adjust the
constant; it makes more sense that way.

_______________________________________________
procmail mailing list
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

<Prev in Thread] Current Thread [Next in Thread>