mbruel / ngPost

Command Line (or minimalist GUI) usenet poster for binaries developped in C++/QT designed to be as fast as possible and offer all the main features to post data easily and safely. Releases for Linux, Windows and MacOS are available.
GNU General Public License v3.0
172 stars 33 forks source link
cmd cpp11 gui multithread nntp nzb obfuscation qt5 usenet usenet-posters
ngPost

ngPost v4.16

Pour la version Française cliquez ici ;)

Here is an invite for the brand new discord server, feel free to join if you've questions or if interested in beta testing the new features before they're released ;)

Command Line and sexy GUI Usenet poster for binaries developped in C++11/Qt5
it is designed to be as fast as possible and offer ALL the main features to post data easily and safely.
it can compress (using your external rar binary) and generate the par2 before posting!
it has a posting queue to allow you to prepare several posts (especially using the GUI using Tabs).
it packs the next Post while uploading the current one (compression + par2 generation)
it can automate posts by scanning folder(s) and posting each file/folder individually after having them compressed (with a potential random archive name and password) and generated the par2!
it can monitor folder(s) to post each new file/folder individually after having them compressed.
it can auto delete files/folders once posted (only for monitoring with the HMI and with both --auto and --monitor in cmd)
it can execute a COMMAND or script after each Post (cf NZB_POST_CMD in the configuration file)
it can switch off the computer when all the posts are finished
it is translated in Chinese, Dutch, English, French, German, Portuguese and Spanish.

ngPost_v4.3

Releases are availables for: Linux 64bit, Windows (both 32bit and 64bit), MacOS and Raspbian (RPI 4). Soon for Android then iOS...

Here are the main features and advantages of ngPost:

How to build

Dependencies:

Build:

Easy! it should have generate the executable ngPost
you can copy it somewhere in your PATH so it will be accessible from anywhere

As it is made in C++/QT, you can build it and run it on any OS (Linux / Windows / MacOS / Android)
releases have only been made for Linux x64 and Windows x64 (for 7 and above) and MacOS (
in order to build on other OS, the easiest way would be to install QT and load the project in QtCreator

How to use it in command line

Syntax: ngPost (options)* (-i  | --auto  | --monitor )+
    --help             : Help: display syntax
    -v or --version    : app version
    -c or --conf       : use configuration file (if not provided, we try to load $HOME/.ngPost)
    --disp_progress    : display cmd progressbar: NONE (default), BAR or FILES
    -d or --debug      : display extra information
    --fulldebug        : display full debug information
    -l or --lang       : application language
    --check            : check nzb file (if articles are available on Usenet) cf https://github.com/mbruel/nzbCheck
    -q or --quiet      : quiet mode (no output on stdout)

// automated posting (scanning and/or monitoring)
    --auto             : parse directory and post every file/folder separately. You must use --compress, should add --gen_par2, --gen_name and --gen_pass
    --monitor          : monitor directory and post every new file/folder. You must use --compress, should add --gen_par2, --gen_name and --gen_pass
    --rm_posted        : delete file/folder once posted. You must use --auto or --monitor with this option.

// quick posting (several files/folders)
    -i or --input      : input file to upload (single file or directory), you can use it multiple times
    -o or --output     : output file path (nzb)
    -x or --obfuscate  : obfuscate the subjects of the articles (CAREFUL you won't find your post if you lose the nzb file)
    -g or --groups     : newsgroups where to post the files (coma separated without space)
    -m or --meta       : extra meta data in header (typically "password=qwerty42")
    -f or --from       : poster email (random one if not provided)
    -a or --article_size: article size (default one: 716800)
    -z or --msg_id     : msg id signature, after the @ (default one: ngPost)
    -r or --retry      : number of time we retry to an Article that failed (default: 5)
    -t or --thread     : number of Threads (the connections will be distributed amongs them)
    --gen_from         : generate a new random email for each Post (--auto or --monitor)

// for compression and par2 support
    --tmp_dir          : temporary folder where the compressed files and par2 will be stored
    --rar_path         : RAR absolute file path (external application)
    --rar_size         : size in MB of the RAR volumes (0 by default meaning NO split)
    --rar_max          : maximum number of archive volumes
    --par2_pct         : par2 redundancy percentage (0 by default meaning NO par2 generation)
    --par2_path        : par2 absolute file path (in case of self compilation of ngPost)
    --auto_compress    : compress inputs with random name and password and generate par2 (equivalent of --compress --gen_name --gen_pass --gen_par2)
    --compress         : compress inputs using RAR or 7z
    --gen_par2         : generate par2 (to be used with --compress)
    --rar_name         : provide the RAR file name (to be used with --compress)
    --rar_pass         : provide the RAR password (to be used with --compress)
    --gen_name         : generate random RAR name (to be used with --compress)
    --gen_pass         : generate random RAR password (to be used with --compress)
    --length_name      : length of the random RAR name (to be used with --gen_name), default: 17
    --length_pass      : length of the random RAR password (to be used with --gen_pass), default: 13
    --rar_no_root_folder: Remove root (parent) folder when compressing Folders using RAR

// you can provide servers in one string using -S and/or split the parameters for ONE SINGLE server (this will overwrite the configuration file)
    -S or --server     : NNTP server following the format (<user>:<pass>@@@)?<host>:<port>:<nbCons>:(no)?ssl
    -h or --host       : NNTP server hostname (or IP)
    -P or --port       : NNTP server port
    -s or --ssl        : use SSL
    -u or --user       : NNTP server username
    -p or --pass       : NNTP server password
    -n or --connection : number of NNTP connections

Examples:
  - with monitoring: ngPost_v4.16_cmd-x86_64.AppImage --monitor /data/folder1 --monitor /data/folder2 --auto_compress --rm_posted --disp_progress files
  - with auto post: ngPost_v4.16_cmd-x86_64.AppImage --auto /data/folder1 --auto /data/folder2 --compress --gen_par2 --gen_name --gen_pass --rar_size 42 --disp_progress files
  - with compression, filename obfuscation, random password and par2: ngPost_v4.16_cmd-x86_64.AppImage -i /tmp/file1 -i /tmp/folder1 -o /nzb/myPost.nzb --compress --gen_name --gen_pass --gen_par2
  - with config file: ngPost_v4.16_cmd-x86_64.AppImage -c ~/.ngPost -m "password=qwerty42" -f ngPost@nowhere.com -i /tmp/file1 -i /tmp/file2 -i /tmp/folderToPost1 -i /tmp/folderToPost2
  - with all params:  ngPost_v4.16_cmd-x86_64.AppImage -t 1 -m "password=qwerty42" -m "metaKey=someValue" -h news.newshosting.com -P 443 -s -u user -p pass -n 30 -f ngPost@nowhere.com  -g "alt.binaries.test,alt.binaries.test2" -a 64000 -i /tmp/folderToPost -o /tmp/folderToPost.nzb

If you don't provide the output file (nzb file), we will create it in the nzbPath with the name of the first file or folder given in the command line.
so in the second example above, the nzb would be: /tmp/file1.nzb

Configuration file and keywords that are only in config

The default configuration file for Linux and Mac environment is: ~/.ngPost (no conf extension)
If you wish, you can use another one in command line with the -c option.
Here the example to follow.

Most configuration keywords can be used in command line but few of them, are only in the config file:

The following ones are for experimented posters:

Linux 64bit portable release (compiled with Qt v5.12.6)

if you don't want to build it and install the dependencies, you can also the portable release that includes everything.

PS: for older system with GLIBC < 2.24, here is a version compiled on Debian8 with GLIBC 2.19 and Qt v5.8.0: ngPost_v4.16-x86_64_debian8.AppImage

Raspbian release (armhf for Raspberry PI)

As rar is not available on RPI, 7zip support has been added. Use RAR_PATH to point on the 7z and RAR_EXTRA to have 7zip options. You should have something like this:

## RAR or 7zip absolute file path (external application)
## /!\ The file MUST EXIST and BE EXECUTABLE /!\
## this is set for Linux environment, Windows users MUST change it
#RAR_PATH = /usr/bin/rar
RAR_PATH = /usr/bin/7z

## RAR EXTRA options (the first 'a' and '-idp' will be added automatically)
## -hp will be added if you use a password with --gen_pass, --rar_pass or using the HMI
## -v42m will be added with --rar_size or using the HMI
## you could change the compression level, lock the archive, add redundancy...
#RAR_EXTRA = -ep1 -m0 -k -rr5p
RAR_EXTRA = -mx0 -mhe=on

Windows installer

if you prefer, you can give all the server parameters in the command line (cf the above section)
By default:

Know Issue with non SSL support: you may need to install msvc2015 redistribuables as libssl depends on its APIs

MacOS release built on High Sierra (v10.13)

Alternatives

A list of Usenet posters from Nyuu github can be found here.

Licence

ngPost is published under licence GPL v3

//========================================================================
//
// Copyright (C) 2020 Matthieu Bruel 
// This file is a part of ngPost : https://github.com/mbruel/ngPost
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU General Public License as published by
// the Free Software Foundation, version 3..
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU General Public License for more details.
//
// You should have received a copy of the GNU General Public License
// along with this program. If not, see 
//
//========================================================================

Questions / Issues / Requests

Here is my email: Matthieu.Bruel@gmail.com

Supported Languages

For now, ngPost is translated in Chinese, English, French, German, Portuguese and Spanish.
If you'd like to translate ngPost in your language, it's easy to do (there is a nice GUI for that: QtLinguist), please get in touch with me (Matthieu.Bruel@gmail.com)

Thanks

Donations

I'm Freelance nowadays, working on several personal projects, so if you use the app and would like to contribute to the effort, feel free to donate what you can.

ex0days or in Bitcoin at this address: 3BGbnvnnBCCqrGuq1ytRqUMciAyMXjXAv6

ngPost_QR