Send inn-workers mailing list submissions to
[email protected]
To subscribe or unsubscribe via the World Wide Web, visit
https://lists.isc.org/mailman/listinfo/inn-workers
or, via email, send a message with subject or body 'help' to
[email protected]
You can reach the person managing the list at
[email protected]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of inn-workers digest..."
Today's Topics:
1. Problems making local postings to inn2 (Jeffery Small)
2. Re: Problems making local postings to inn2 (Russ Allbery)
3. Re: Problems making local postings to inn2 (Jeffery Small)
4. Re: Problems making local postings to inn2 (Russ Allbery)
5. Re: Problems making local postings to inn2
(Kamil =?iso-8859-2?Q?Jo=F1ca?=)
----------------------------------------------------------------------
Message: 1
Date: Fri, 2 Jun 2017 13:23:00 -0700
From: Jeffery Small <[email protected]>
To: Inn Workers <[email protected]>
Subject: Problems making local postings to inn2
Message-ID: <[email protected]>
Content-Type: text/plain; charset=us-ascii
I recently upgraded from Ubuntu 16.10 to 17.04 and have been having many
problems making local postings to the news system. There was likely
an upgrade of inn2 to version 2.6.1-1 at this time.
For years I've been using the mailagent(1) program to filter various incoming
emails into the news service and posting still works in general, but I am now
seeing a LOT of the following new messages in my mailer log file:
inews: cannot send article to server: 441 Invalid syntax encountered \
in headers (unexpected byte, no colon-space, or empty content line)
inews: article not posted
Occasionally the messages refer specifically to the References: or Subject:
header lines. For example:
inews: cannot send article to server: 441 Invalid syntax encountered \
in References: header field body (unexpected byte or empty content line)
inews: article not posted
inews: cannot send article to server: 441 Invalid syntax encountered \
in Subject: header field body (unexpected byte or empty content line)
inews: article not posted
These messages get left in my inbox and I have investigated the headers of
these failed posts in great detail. I can find no instances of:
* A header that does not have a "Name:<space>" format
* A header with an empty field after the :<space>
* Any odd characters: e.g., no non-ascii-7 characters
Everything appears normal, so I am at a loss to see why these fail.
Any suggestions as to where to look for the problem?
Also, is there a way to get inn2 to generate better diagnostic output.
Despite all these (and other) problems, the log file /var/log/news/errlog
is always empty and the other news logs have little useful information
to help isolate a problem.
Thanks.
--
Jeff Small
------------------------------
Message: 2
Date: Fri, 02 Jun 2017 15:11:15 -0700
From: Russ Allbery <[email protected]>
To: [email protected]
Subject: Re: Problems making local postings to inn2
Message-ID: <[email protected]>
Content-Type: text/plain
Jeffery Small <[email protected]> writes:
> These messages get left in my inbox and I have investigated the headers of
> these failed posts in great detail. I can find no instances of:
> * A header that does not have a "Name:<space>" format
> * A header with an empty field after the :<space>
> * Any odd characters: e.g., no non-ascii-7 characters
> Everything appears normal, so I am at a loss to see why these fail.
> Any suggestions as to where to look for the problem?
Are you perhaps sending just CR and not CRLF at the end of lines? That's
the first thing that comes to mind here.
Is there any chance you could include the full headers of one of these
rejected messages?
> Also, is there a way to get inn2 to generate better diagnostic output.
> Despite all these (and other) problems, the log file /var/log/news/errlog
> is always empty and the other news logs have little useful information
> to help isolate a problem.
Well, this isn't an error from the INN perspective -- rejecting malformed
articles is just normal. I think the rejection may be logged to
news.notice by nnrpd, though. But it's not going to contain any more
information than the 411 error you already included, because that's all
the information there is.
if (hp->Value) {
hp->Len = TrimSpaces(hp->Value);
/* If the header is empty, we just remove it. We do not reject
* the article, contrary to what an injecting agent is supposed
* to do per Section 3.5 of RFC 5537. (A revision to RFC 5537
* may someday allow again that existing and useful feature.) */
if (hp->Len == 0) {
hp->Value = hp->Body = NULL;
} else if (!IsValidHeaderBody(hp->Value)) {
snprintf(Error, sizeof(Error),
"Invalid syntax encountered in %s: header field "
"body (unexpected byte or empty content line)",
hp->Name);
return Error;
}
}
The check is really pretty simple and very low-level: there has to be at
least one non-whitespace character in the field body, CR can't appear by
itself, LF or CRLF has to be followed by whitespace or another header, and
every character has to satisfy the C function isgraph() ("any printable
character except space") or be a space or tab.
--
Russ Allbery ([email protected]) <http://www.eyrie.org/~eagle/>
Please send questions to the list rather than mailing me directly.
<http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
------------------------------
Message: 3
Date: Fri, 2 Jun 2017 23:12:05 -0000 (UTC)
From: Jeffery Small <[email protected]>
To: [email protected]
Subject: Re: Problems making local postings to inn2
Message-ID: <[email protected]>
Russ Allbery <[email protected]> writes:
Russ, thanks for the reply:
>Are you perhaps sending just CR and not CRLF at the end of lines? That's
>the first thing that comes to mind here.
Well, this is a Linux system and I am filtering the email messages through
a perl script where I chomp the end of the lines and then print them all
out with just a newline. However, I'm doing this for every message received
and most of them post without problem, so I don't see how this could be
the problem.
>Is there any chance you could include the full headers of one of these
>rejected messages?
I'll monitor for one and post it soon. It's never clear which email relates
to which error message unless I'm monitoring closely.
Is there possibly some way to make inn2 less restrictive and go ahead and
post even if certain errors are detected? The code snipet below doesn't
show any method for this, but maybe elsewhere? (Unlikely, I know!)
Regards,
--
Jeff
>Jeffery Small <[email protected]> writes:
>> These messages get left in my inbox and I have investigated the headers of
>> these failed posts in great detail. I can find no instances of:
>> * A header that does not have a "Name:<space>" format
>> * A header with an empty field after the :<space>
>> * Any odd characters: e.g., no non-ascii-7 characters
>> Everything appears normal, so I am at a loss to see why these fail.
>> Any suggestions as to where to look for the problem?
>Are you perhaps sending just CR and not CRLF at the end of lines? That's
>the first thing that comes to mind here.
>Is there any chance you could include the full headers of one of these
>rejected messages?
>> Also, is there a way to get inn2 to generate better diagnostic output.
>> Despite all these (and other) problems, the log file /var/log/news/errlog
>> is always empty and the other news logs have little useful information
>> to help isolate a problem.
>Well, this isn't an error from the INN perspective -- rejecting malformed
>articles is just normal. I think the rejection may be logged to
>news.notice by nnrpd, though. But it's not going to contain any more
>information than the 411 error you already included, because that's all
>the information there is.
> if (hp->Value) {
> hp->Len = TrimSpaces(hp->Value);
> /* If the header is empty, we just remove it. We do not reject
> * the article, contrary to what an injecting agent is supposed
> * to do per Section 3.5 of RFC 5537. (A revision to RFC 5537
> * may someday allow again that existing and useful feature.) */
> if (hp->Len == 0) {
> hp->Value = hp->Body = NULL;
> } else if (!IsValidHeaderBody(hp->Value)) {
> snprintf(Error, sizeof(Error),
> "Invalid syntax encountered in %s: header field "
> "body (unexpected byte or empty content line)",
> hp->Name);
> return Error;
> }
> }
>The check is really pretty simple and very low-level: there has to be at
>least one non-whitespace character in the field body, CR can't appear by
>itself, LF or CRLF has to be followed by whitespace or another header, and
>every character has to satisfy the C function isgraph() ("any printable
>character except space") or be a space or tab.
>--
>Russ Allbery ([email protected]) <http://www.eyrie.org/~eagle/>
> Please send questions to the list rather than mailing me directly.
> <http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
>_______________________________________________
>inn-workers mailing list
>[email protected]
>https://lists.isc.org/mailman/listinfo/inn-workers
------------------------------
Message: 4
Date: Fri, 02 Jun 2017 18:02:10 -0700
From: Russ Allbery <[email protected]>
To: [email protected]
Subject: Re: Problems making local postings to inn2
Message-ID: <[email protected]>
Content-Type: text/plain
Jeffery Small <[email protected]> writes:
> Is there possibly some way to make inn2 less restrictive and go ahead
> and post even if certain errors are detected? The code snipet below
> doesn't show any method for this, but maybe elsewhere? (Unlikely, I
> know!)
It is possible to turn off various checks, but I think it's a fairly bad
idea to turn off this one because it indicates that the message is badly
malformed. I suspect that turning off this check would result in worse
failures later on, since the message probably can't be stored or retrieved
properly because the headers can't be parsed.
That possibly isn't the case if the problem is just a stray non-ASCII
character, but it sounded like you didn't think that was the case, and
it's the same check that catches completely malformed messages.
--
Russ Allbery ([email protected]) <http://www.eyrie.org/~eagle/>
Please send questions to the list rather than mailing me directly.
<http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
------------------------------
Message: 5
Date: Sat, 03 Jun 2017 06:29:21 +0200
From: [email protected] (Kamil =?iso-8859-2?Q?Jo=F1ca?=)
To: [email protected]
Subject: Re: Problems making local postings to inn2
Message-ID: <[email protected]>
Content-Type: text/plain; charset=iso-8859-2
Jeffery Small <[email protected]> writes:
> I recently upgraded from Ubuntu 16.10 to 17.04 and have been having many
> problems making local postings to the news system. There was likely
> an upgrade of inn2 to version 2.6.1-1 at this time.
>
> For years I've been using the mailagent(1) program to filter various incoming
> emails into the news service and posting still works in general, but I am now
> seeing a LOT of the following new messages in my mailer log file:
I suspect that you have emails with empty headers in them.
See discussion "relaxing a few checks" about mailpost :)
Do you have copy of rejected emails?
KJ
--
http://wolnelektury.pl/wesprzyj/teraz/
"Nie mo?na wlecie? w trzecie tysiaclecie
na drzwiach od stodo?y" - biskup polowy WP S?awoj Leszek G??d?.
------------------------------
Subject: Digest Footer
_______________________________________________
inn-workers mailing list
[email protected]
https://lists.isc.org/mailman/listinfo/inn-workers
------------------------------
End of inn-workers Digest, Vol 95, Issue 1
******************************************