Bug#871473: logwatch: Logwatch email messages fail with vanilla exim4 install: message is too big (transport limit = 1)

2018-10-02 Thread Willi Mann
Hi Peter,

Am 08.08.17 um 11:41 schrieb Peter Collinson:
>  Alternative and better solution: I added --encode=base64 to
>  00logwatch in cron.daily, after ensuring that libmime-tools-perl
>  was installed. Line wrapping is no longer a problem.

the problem with the base64 option is that it bloats the e-mail in size
(factor 1.33), so I don't think that this is a general solution. I think
I will solve this problem by documenting it in README.Debian.

Willi



Bug#871473: logwatch: Logwatch email messages fail with vanilla exim4 install: message is too big (transport limit = 1)

2017-08-08 Thread Peter Collinson
Package: logwatch
Version: 7.4.3+git20161207-2
Severity: important
Tags: newcomer

Dear Maintainer,

   * What led up to the situation?
 logwatch was examining logs after I had installed a lot of
 iptables system logging to see whether my firewall was working while I
 poked from outside.

 It tried to send a line in the report that was very long - 2048
 characters or so. It linewrapped this line down somewhat randomly
 adding ! to the end of the line to show this and one of the lines
 was 1040 characters long.

 However, exim4 has a line length check and refuses to send mail
 which it gets from SMTP with lines longer than 998 octets. It fails to
 send the mail somewhat incomprehensively with the error message that I 
include in the
 title of this report. Lines longer than 998 are apparently
 prohibited by the standard.

 The user gets a bounce message which is completely enigmatic and
 gives no real hint what the problem is. (The exim4 config script
 admits that what is done there is a hack).

   * What exactly did you do (or not do) that was effective (or
 ineffective)?

 First, while trying to find out what was happening, I disabled
 the line length restriction in exim4 (having first found out how
 to do this). This worked and allowed me to get the mail - and the sample 
lines below.

 Alternative and better solution: I added --encode=base64 to
 00logwatch in cron.daily, after ensuring that libmime-tools-perl
 was installed. Line wrapping is no longer a problem.
 
   * What was the outcome of this action?
 Both solutions worked and allowed the mail to be sent.

 I think that logwatch should be distributed with --encode=base64
 selected to avoid this problem.

 section from log that logwatch tried to send
This is linewrapped as it came out of logwatch. Perhaps the line
wrapping code should be improved? However my first attempt to send this fell 
over the
same linelength restriction in exim4. So I've base64'd the source lines.

- cut and run base64 -d file --
dGNwKDEsMyw0LDYsNyw5LDEzLDE3L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