Long before the World Wide Web, a worldwide platform emerged in the early 80s for the exchange of in­for­ma­tion. It was called Usenet (orig­i­nal­ly UNIX User Network) and still co-exists with the web today as an in­de­pen­dent Internet service. However, the news­groups, as the separate Usenet topics were named, have become con­sid­er­ably less important over the past decades. This is due to new, digital exchange mediums such as forums and social networks.

However, the his­tor­i­cal value of the hi­er­ar­chi­cal­ly-struc­tured Usenet, which relies on the classic client-server message exchange, is beyond question. It is def­i­nite­ly still worth taking a look at the NNTP (Network News Transfer Protocol) behind the in­for­ma­tion network, which is in­dis­pens­able in the com­mu­ni­ca­tion between in­di­vid­ual news servers and clients.

What is NNTP (Network News Transfer Protocol)?

The Network News Transfer Protocol, NNTP for short, is es­sen­tial­ly a TCP/IP transfer protocol for messages within news­groups. These news­groups are mainly utilized as part of the Usenet, where they offer, as a type of precursor of modern internet forums, space for the exchange of an unlimited number of text messages on the most diverse topics. The first spec­i­fi­ca­tion of the NNTP, which was recorded in RFC 977, dates back to 1986. Since then, the protocol has been revised several times – the current version can be found in RFC 3977. Fur­ther­more, since RFC 5536 appeared in 2009, a Request for Comments has existed, which also specifies more precisely the NNTP transfer’s message format.

Note

Up until the de­vel­op­ment and release of NNTP, the exchange of data in Usenet occurred via telephone lines with the UUCP (Unix to Unix copy).

Where is NNTP Utilized?

Nowadays, NTTP no longer has an important role in digital com­mu­ni­ca­tion, which can primarily be at­trib­ut­able to the fact that Usenet is now only used in isolated cases and among spe­cial­ist groups. Since 1986, the Network News Transfer Protocol has been in­dis­pens­able for the in­for­ma­tion network and is used both on server and client pages. Apart from the exchange of personal direct messages, Usenet stands out in par­tic­u­lar because of the news­groups mentioned above, which thanks to the protocol can be created and ad­min­is­tered sep­a­rate­ly. In this way, numerous sub-news­groups have been in­te­grat­ed into Usenet’s existing base hierarchy over the course of time.

Note

The eight main topic cat­e­gories for Usenet, which are also referred to as the “Big Eight” or “Big 8”, are the following:

- comp: Computers

- sci: Science and Tech­nol­o­gy

- soc: Society

- talk: general subjects

- rec: topics ad­dress­ing recre­ation, re­lax­ation, art and culture

- news: in­for­ma­tion and news about Usenet itself

- misc: mixed

- hu­man­i­ties: Hu­man­i­ties, Culture.

How Does the Network News Transfer Protocol Work?

NNTP is a text-based protocol and allows for the al­ter­nat­ing exchange between client and server: Therefore, for every NNTP inquiry, an NNTP reply is expected. For this com­mu­ni­ca­tion the IANA (Internet Assigned Numbers Authority) has provided TCP-Port 119, which in this case is solely reserved for the transfer protocol – a TCP/IP network such as the Internet is as a result the un­der­ly­ing basis for the in­for­ma­tion platform. The NNTP itself has access to the ap­pli­ca­tion layer and for this relies directly on the TCP protocol, which has the advantage of ensuring both a secure and reliable transfer of data.

The basic concept of Usenet allows for a new message that is sent from an NNTP Client to any NNTP server to be stored on this same server. All the other clients who would like to par­tic­i­pate in the par­tic­u­lar con­ver­sa­tion can download this message or article at any time in order to establish the current status of the newsgroup. As a result, this means that after the es­tab­lish­ment of the con­nec­tion to an NNTP server, a client first downloads all messages that were published since the last con­nec­tion to the server. As a result, the longer a client was “offline”, the more time the updating process utilizes after the con­nec­tion has been es­tab­lished.

Note

As soon as a server receives a new message via Network News Transfer Protocol, it adds an in­di­vid­ual message ID to this message or article. This has the format “<se­quen­tial number@News-Server>” and is conducive to clear labeling, retrieval and ref­er­ences in case other clients or users would like to react or respond with their own message.

In order to dis­sem­i­nate new messages within the entire Usenet network, the in­di­vid­ual servers also send the received messages to all the other NNTP servers known to them. Before doing this, they add their own names to the NNTP message’s path header so that these are not received again.

NNTP: Example for Message Exchanges

After having explained the basics of the Network News Transfer Protocol in the previous section, we will now il­lus­trate the com­mu­ni­ca­tion between clients and servers using a specific example. The starting point is Client 1, which feeds a message or a new article into Usenet:

The in­di­vid­ual messaging steps that are depicted in this diagram can be sum­ma­rized as follows:

  1. The user behind NNTP Client 1 writes a new message (or new article) and sends this data to NNTP Server 1.
  2. NNTP Server 1 provides the message with a unique message ID and adds its name to the header. It rec­og­nizes NNTP Server 2 and NNTP Server 3, and forwards the message onto both.
  3. NNTP Server 2 receives the message and inserts its name into the header. NNTP Server 3 receives the message as well, extends the header with its name and forwards the message to the NNTP Server 4 (which it knows).
  4. The message is also received at NNTP Server 4 and processed: The header is enlarged around its name. It then contacts NNTP Server 5, which it knows, and provides it with the data.
  5. NNTP Server 5 adds its iden­ti­fi­ca­tion to the header. It evaluates the entries in the header and for this reason does not try, in turn, to forward the message to Servers 2 und 3, which it knows (the red arrows are thus for un-attempted for­ward­ing).
  6. In the meantime, the clients retrieve the message from their personal news server as soon as they are online. NNTP Client 2 receives the in­for­ma­tion, for example, directly from Server 1; Client 6, in contrast, from Server 4.

An Overview of NNTP Commands and Status Codes

For com­mu­ni­cat­ing with the NNTP, clients and servers have recourse to ASCII commands. With every NNTP inquiry a client thus au­to­mat­i­cal­ly sends one of these commands as well. The server then responds with a status message and sends the client the requested data. The most important commands in NNTP com­mu­ni­ca­tion are sum­ma­rized in the following tables:

NNTP Command Function
LIST Requests a list of the available news­groups (including the first and last article number)
NEWGROUPS Asks for all newly-available groups
NEWNEWS Asks for all newly-available articles that were created as of a specific date
GROUP Specifies the group to which an inquiry applies
ARTICLE Enables the request of a specific article with regard to its number in the group or its message ID
HEADER Requests solely the header of an article
BODY Requests solely the body of an article
STAT Is needed for spec­i­fy­ing an article’s message ID
NEXT Selects the next article in the newsgroup
POST Informs the server that a new message or article is being trans­ferred
QUIT Ter­mi­nates the con­nec­tion to the NNTP server

The status message that the server sends back as an NNTP response (including the requested data), is a three three-digit numeric code. The first position can be trans­lat­ed as follows:

NNTP Server Status Code Meaning
1xx General in­for­ma­tion
2xx Message received, execution suc­cess­ful
3xx Message received, further in­for­ma­tion is required
4xx Message received, execution un­suc­cess­ful
5xx Invalid command

Meanwhile, the server passes along the following in­for­ma­tion via the numerical code’s second position:

NNTP Server Status Code Meaning
x0x In­for­ma­tion about the con­nec­tion, setup or something else
x1x In­for­ma­tion about the selected newsgroup
x2x In­for­ma­tion about the selected article
x3x In­for­ma­tion about the message transfer
x4x In­for­ma­tion about the sent article
x5x Au­then­ti­ca­tion response
x8x Message for extended non-standard commands
x9x Debugging message
Go to Main Menu