Relaxing a few checks

Julien ÉLIE julien at trigofacile.com
Wed Mar 22 13:44:34 UTC 2017


Hi Kamil,

>> More generally, does anyone have in mind other checks that INN
>> currently performs but you find annoying? And on the contrary,
>> checks that INN currently does not perform but you would like to?
>
> Recently innd/nnrpd has been more restrict about empty headers. I
> have some mail grops that I fed to inn with mailpost. And I got a
> lot of errors. I know that proper way is to change mailpost, but this
> relax check would be a nice workaround.

Thanks for the suggestion of a new relaxed check.

It is of course also a mailpost bug that should be fixed.
Could you please try the following patch for mailpost?

--- mailpost    2017-03-20 15:26:45.000000000 +0100
+++ mailpost    2017-03-20 16:02:52.000000000 +0100
@@ -213,6 +213,9 @@
      next if /^Approved:\s/sio && defined($approved);
      next if /^Distribution:\s/sio && defined($distribution);

+    # Remove empty header field bodies.
+    next if /^[^:]+:\s*$/;
+
      if (/^($exclude):\s*/sio) {
      $real_news_hdrs .= "$_\n";
      next;




I've tested it and made sure it correctly removes empty header fields like:

Test:    \t   \r\n

or multi-line like:

Test:  \r\n
    \r\n

-- 
Julien ÉLIE

« PowerPoint allows speakers to pretend that they are giving a real
   talk, and audiences to pretend that they are listening. » (Edward R.
   Tufte, _The Cognitive Style of PowerPoint_)


More information about the inn-workers mailing list