ReK2 NNTP RFC4643 RFC3977 Library
This is a Rust library that provides a way to interact with NNTP servers, compliant with RFC 3977 and RFC 4643.
Features
- Article Posting
- Newsgroup Listing
- Article Reading from a Group
- Authentication (TLS/SSL)
Installation
Add the following to your Cargo.toml
:
[]
= "0.1.3" # Replace with the actual version
Run cargo build
to build the dependencies.
Usage
Importing the Library
First, add the following import to your code:
extern crate rek2_nntp;
Authentication
To authenticate, use the authenticate
function:
use authenticate;
// Example of how to authenticate using the library
let result = authenticate.await;
match result
Listing Newsgroups
To list newsgroups, use the list_newsgroups
function:
use list_newsgroups;
let result = list_newsgroups.await;
match result
Reading from a Group
To read articles from a newsgroup:
use read_from_group;
let result = read_from_group.await;
match result
Posting to a Group
To post an article to a newsgroup:
use post_to_group;
use Article;
let article = Article ;
let result = post_to_group.await;
match result
Contributing
Feel free to contribute to this project by creating issues, pull requests or improving the documentation.
License
This project is licensed under the GNU General Public License v3.0.