www.elbiah.de

Home Tools

nntpx - NNTP communication tool - Vr. 1.0

Content

Introduction

nntpx is a commandline utility for NNTP communication, mostly intended to be used for testing purposes:

Download

nntpx.zip (100 KB)

Note 1: This HTML file and the Delphi5 sourcecode is also included in the .zip-file.
Note 2: To compile the sourcecode, the "Indy" components (http://www.nevrona.com/indy/) are required.

Options

-s (server/port)

   -s server[:port]

   -s 127.0.0.1:119
   -s news.provid.er

Select newsserver and port to connect to (default: 127.0.0.1:119).

-u (username/password)

   -u user:password

   -u username:secret

Select username and password for AUTHINFO USER/PASS (default: none).

-g (newsgroup name)

   -g newsgroup

   -g misc.test

Select newsgroup from which articles are loaded (-a). It is also selected when sending commands (-c).

-a (articles)

   -a number

   -a 123

Load article with the given number from the group selected by "-g". Output is converted to mbox-format.

   -a [low]-[high][:[-]limit]

   -a 100-200
   -a 100-
   -a -200
   -a -
   -a -:-10

Load articles numbered from "low" to "high" from the group selected by "-g". If "low" or "high" is missing, it is replaced by available article numbers reported by the newsserver.
If a "limit" is given, the number of loaded articles is limited to this value (>0:newest, <0:oldest, =0/omitted:no limit).
Output of all loaded articles is converted to mbox-format.

-p (post article)

   -p filename

   -p test.msg
   -p "test 2.msg"

Post single (!) article contained in the given file. It has to be exactly in the format ready to be posted (i.e. no mbox-format here, required header lines have to be present etc.).
Some basic checks are made before sending to prevent from posting b*llsh*t: no mbox-format, presence of header/body separator and Newsgroups:, Subject: and From: header.

-c (command)

   -c command+parameters

   -c list
   -c "list newsgroups"
   -c "article <example@news.serv.er>"

NNTP-command and parameters to send (default: none).

-m (multiline response)

   -m (+|-)

   -m +
   -m -

Expected -c respone, +=multiline/-=singleline, default: autodetect.

Examples

Load the list of newsgroups descriptions ("LIST NEWSGROUPS") and save it in file "descriptions.txt":


   nntpx -s news.provid.er -u myname:mypass -c "list newsgroups" > descriptions.txt

Load article with Message-ID "<example@news.serv.er>":


   nntpx -s news.provid.er -u myname:mypass -c "article <example@news.serv.er>"

Load all articles of newsgroup "de.newusers.infos" and save them in file "dni.txt":


   nntpx -s news.provid.er -u myname:mypass -g de.newusers.infos -a - > dni.txt

License

 

============================================================================
nntpx, a free commandline utility for NNTP communication
Copyright (c) 2001, Juergen Haible. All Rights Reserved.

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to
deal in the Software without restriction, including without limitation the
rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
sell copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in
all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
IN THE SOFTWARE.
============================================================================

 

Copyright © 2003 by Jürgen Haible - Impressum