🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: news.software.nntp
10 messages
10 total messages Started by Matthias Luedtke Sun, 17 Nov 2002 11:25
RFC 977 - General Responses
#62004
Author: Matthias Luedtke
Date: Sun, 17 Nov 2002 11:25
13 lines
1577 bytes
In RFC 977 (2.4.3) some 'General Responses' are mentioned which may be 
sent by the NNTP server. I do not exactly understand _when_ the server 
is allowed to sent these responses: Only in return to an command sent 
to the server or just when 'it wants to'.

(Im going to implement an NNTP API and I'm figuring out when to check 
for responses and how to react on them.)

TIA
  Matthias

matthias-luedtke at gmx dot de
Re: RFC 977 - General Responses
#62006
Author: Jeffrey M. Vinocur
Date: Sun, 17 Nov 2002 15:39
20 lines
1708 bytes
In article <Xns92C97E7576DE7matthiasluedtke@luedtke.my-fqdn.de>,
Matthias Luedtke  <mluedtke_expires311202@gmx.de> wrote:
>In RFC 977 (2.4.3) some 'General Responses' are mentioned which may be 
>sent by the NNTP server. I do not exactly understand _when_ the server 
>is allowed to sent these responses: Only in return to an command sent 
>to the server or just when 'it wants to'.

In principle, the server can only send a response following a
client command.

There is one exception in practice, which is that most servers
send a response before disconnecting the client due to an idle
timeout.  For example, INN sends:

503 Timeout after 600 seconds, closing connection.

-- 
Jeffrey M. Vinocur
jeff@litech.org
Re: RFC 977 - General Responses
#62007
Author: Andrew - Supernews
Date: Sun, 17 Nov 2002 15:51
18 lines
1541 bytes
In article <ar8d6m$ev6$2@puck.litech.org>, Jeffrey M. Vinocur wrote:
> In principle, the server can only send a response following a
> client command.
> 
> There is one exception in practice, which is that most servers
> send a response before disconnecting the client due to an idle
> timeout.  For example, INN sends:
> 
> 503 Timeout after 600 seconds, closing connection.

which, frankly, was never a good idea; the latest NNTP draft suggests that
the connection should be silently dropped in the event of a timeout, and in
fact that is what we do.

-- 
Andrew, Supernews
http://www.supernews.com - individual and corporate NNTP services
Re: RFC 977 - General Responses
#62008
Author: Matthias Luedtke
Date: Sun, 17 Nov 2002 16:20
31 lines
2295 bytes
Jeffrey M. Vinocur ( jeff@litech.org ) schrieb:

>In principle, the server can only send a response following a
>client command.
>
>There is one exception in practice, which is that most servers
>send a response before disconnecting the client due to an idle
>timeout.  For example, INN sends:
>
>503 Timeout after 600 seconds, closing connection.

If 503 is the only response not triggered by a client request that 
would not be much of a problem. I figured out that 

400 service discontinued

sounds quite similar to 503, whereas 503 is described as

503 program fault - command not performed.

It's quite hard to develop an error handling strategy when you do not 
know how to react to certain error codes - and when one response might 
be sent (e.g. In case of 503 it now seems not sure if the connection 
still exists or not.) How do the common NNTP servers around use the 
error codes usually? What would be a sensible way to deal with this?

TIA
  Matthias

matthias-luedtke at gmx dot de
Re: RFC 977 - General Responses
#62009
Author: Curt Welch
Date: Sun, 17 Nov 2002 16:25
23 lines
2096 bytes
andrew@supernews.com wrote:
> In article <ar8d6m$ev6$2@puck.litech.org>, Jeffrey M. Vinocur wrote:
> > In principle, the server can only send a response following a
> > client command.
> >
> > There is one exception in practice, which is that most servers
> > send a response before disconnecting the client due to an idle
> > timeout.  For example, INN sends:
> >
> > 503 Timeout after 600 seconds, closing connection.
>
> which, frankly, was never a good idea; the latest NNTP draft suggests
> that the connection should be silently dropped in the event of a timeout,
> and in fact that is what we do.

Same here.  Sending an unexpected response is just wrong - and not having a
uniqe and well defined response for "timeout" makes it even more dangerous.
My server as well just closes the connection on an idle timeout.

-- 
Curt Welch                                            http://CurtWelch.Com/
curt@kcwc.com                          Webmaster for http://NewsReader.Com/
Re: RFC 977 - General Responses
#62010
Author: Matthias Luedtke
Date: Sun, 17 Nov 2002 16:41
22 lines
2141 bytes
Curt Welch ( curt@kcwc.com ) wrote:

>>>503 Timeout after 600 seconds, closing connection.
>>
>>which, frankly, was never a good idea; the latest NNTP draft suggests
>>that the connection should be silently dropped in the event of a
>>timeout, and in fact that is what we do.
>
>Same here.  Sending an unexpected response is just wrong - and not
>having a uniqe and well defined response for "timeout" makes it even
>more dangerous. My server as well just closes the connection on an
>idle timeout. 

That sounds quite strict. May I rely on the fact that the 'General 
Responses' are normally sent as reponses to clients commands and never 
'in between'? How do other servers manage this issue?

TIA
  Matthias

matthias-luedtke at gmx dot de
Re: RFC 977 - General Responses
#62011
Author: Russ Allbery
Date: Sun, 17 Nov 2002 19:33
25 lines
2024 bytes
Andrew <- Supernews <andrew+nonews@supernews.com>> writes:
> Jeffrey M. Vinocur wrote:

>> In principle, the server can only send a response following a
>> client command.

>> There is one exception in practice, which is that most servers
>> send a response before disconnecting the client due to an idle
>> timeout.  For example, INN sends:

>> 503 Timeout after 600 seconds, closing connection.

> which, frankly, was never a good idea; the latest NNTP draft suggests
> that the connection should be silently dropped in the event of a
> timeout, and in fact that is what we do.

Yeah, that's one of the compliance bugs that I identified a while back in
INN but haven't gotten around to fixing yet.

-- 
Russ Allbery (rra@stanford.edu)             <http://www.eyrie.org/~eagle/>

          Please post questions rather than mailing me directly.
     <http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
Re: RFC 977 - General Responses
#62014
Author: Russ Allbery
Date: Sun, 17 Nov 2002 19:34
18 lines
1870 bytes
Matthias Luedtke <mluedtke_expires311202@gmx.de> writes:

> It's quite hard to develop an error handling strategy when you do not
> know how to react to certain error codes - and when one response might
> be sent (e.g. In case of 503 it now seems not sure if the connection
> still exists or not.)

The latest NNTP draft is, I believe, pretty specific about when
connections should be closed by the server, but of course not all servers
always follow it.  You can always try sending a no-op command like DATE
and seeing if the connection is still there.

-- 
Russ Allbery (rra@stanford.edu)             <http://www.eyrie.org/~eagle/>

          Please post questions rather than mailing me directly.
     <http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
Re: RFC 977 - General Responses
#62017
Author: those who know me have no need o...
Date: Sun, 17 Nov 2002 23:41
10 lines
1370 bytes
in news.software.nntp i read:

>You can always try sending a no-op command like DATE
>and seeing if the connection is still there.

yeah, then there's only that pesky tcp retry to wait out.

-- 
bringing you boring signatures for 17 years
Re: RFC 977 - General Responses
#62019
Author: Russ Allbery
Date: Mon, 18 Nov 2002 00:19
17 lines
1751 bytes
those who know me have no need of my name <not-a-real-address@usa.net> writes:
> in news.software.nntp i read:

>> You can always try sending a no-op command like DATE and seeing if the
>> connection is still there.

> yeah, then there's only that pesky tcp retry to wait out.

If the remote end has closed the connection, you get an immediate reset
and there's no wait.

-- 
Russ Allbery (rra@stanford.edu)             <http://www.eyrie.org/~eagle/>

          Please post questions rather than mailing me directly.
     <http://www.eyrie.org/~eagle/faqs/questions.html> explains why.
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads