RCON client for Rust

Related tags

Utilities rcon-rs
Overview

rcon-rs

Simple implementation of a crate that allows you to work with the RCON protocol

To work with TCP, the TcpStream structure built into the std::net module is used

About RCON

Dependencies

  • rand for generate a random request ID
  • bytes for converting types to bytes, for subsequent transmission via tcp

Games that support this protocol

  • Minecraft
  • Counter Strike
  • ARK
  • Rust
  • SAMP
  • MTA
  • etc

Example

use rcon::{AuthRequest, RCONClient, RCONError, RCONRequest};

fn main() -> Result<(), RCONError> {
    let server_url = String::from("donkey-engine.host");
    let mut client = rcon::RCONClient::new(server_url)?;
    let auth_result = client.auth(AuthRequest::new(String::from("RCON_SECRET")))?;
    assert!(auth_result.is_success());
    let version = client.execute(RCONRequest {
        id: 228,
        request_type: 2,
        body: String::from("VERSION"),
    })?;
    assert_eq!(version.body, "1.0.0");
    Ok(())
}
You might also like...
Flexcord! A custom Discord client to allow you to do what you want!

Disclaimer Flexcord is NO WHERE near done. Flexcord What is it? Flexcord is a Discord client that flexes for your needs, it allows you to do exactly w

OpenAI chat client desktop app (Windows, MacOS, Linux)
OpenAI chat client desktop app (Windows, MacOS, Linux)

ChatWizard OpenAI chat client Desktop Application (Windows, MacOS, Linux) Declaration This project is currently undergoing active development and has

An open-source Windows client for Twitch.tv
An open-source Windows client for Twitch.tv

TwitchBox is a lightweight Windows client created to enhance the Twitch.tv experience. The app uses the Tauri framework, which includes a combination

A swc plugin that automatically converts React component libraries into "React Client Component"

A swc plugin that automatically converts React component libraries into "React Client Component". For example, you can automatically convert components from @mui into "React Client Component" without having to wrap a component that uses "use client".

Unofficial cross-platform Microsoft To Do client

WIP Dev Setup dev env Compile for dev Compile for production Todos (how ironicall to keep them in README xd) Implement task search Implement ability t

Command palette-style Git client for blazing-fast commits.
Command palette-style Git client for blazing-fast commits.

🔎 About Commit Commit is the world's simplest Git client. Open it with a keyboard shortcut, write your commit, and you're done! Commit will automatic

🚧 WIP: API client crate for Bambu Lab printers

Bambulab API 🚧 WORK IN PROGRESS 🚧 This crate is still in development and not ready for production use. Breaking changes may occur at any time. bambu

k-mer counter in Rust using the rust-bio and rayon crates

krust is a k-mer counter written in Rust and run from the command line that will output canonical k-mers and their frequency across the records in a f

Experimental Rust tool for generating FFI definitions allowing many other languages to call Rust code

Diplomat is an experimental Rust tool for generating FFI definitions allowing many other languages to call Rust code. With Diplomat, you can simply define Rust APIs to be exposed over FFI and get high-level C, C++, and JavaScript bindings automatically!

Releases(0.1.2)
  • 0.1.2(Nov 24, 2021)

    What's Changed

    • Add socket timeout by @BehindLoader in https://github.com/donkey-engine/rcon-rs/pull/4

    Full Changelog: https://github.com/donkey-engine/rcon-rs/compare/0.1.1...0.1.2

    Source code(tar.gz)
    Source code(zip)
  • 0.1.1(Nov 24, 2021)

    What's Changed

    • Add Display to structs by @BehindLoader in https://github.com/donkey-engine/rcon-rs/pull/3

    Full Changelog: https://github.com/donkey-engine/rcon-rs/compare/0.1.0...0.1.1

    Source code(tar.gz)
    Source code(zip)
  • 0.1.0(Nov 24, 2021)

Owner
Donkey Engine
Game servers builder and hosting
Donkey Engine
Supernova client in Rust

What is this? A client library for the Supernova REST API. Usage use iron_planet::{Supernova, RequestConfig}; fn main() { // Instantiate an unpri

Nova Universidade Nova de Lisboa 1 Dec 29, 2021
A Diablo II library for core and simple client functionality, written in Rust for performance, safety and re-usability

A Diablo II library for core and simple client functionality, written in Rust for performance, safety and re-usability

null 4 Nov 30, 2022
A random.org client library for Rust

random.org A https://random.org client library. The randomness comes from atmospheric noise, which for many purposes is better than the pseudo-random

Victor Polevoy 7 Mar 10, 2022
TaurApp is a WhatsApp desktop client powered by Tauri and Rust.

TaurApp TaurApp is a WhatsApp desktop client powered by Tauri and Rust. TaurApp is an experimental client and is initially created to test out Tauri i

Eray Erdin (&mut self) 22 Mar 19, 2023
Simple git/hg tui client focused on keyboard shortcuts

verco A simple Git/Hg tui client focused on keyboard shortcuts Screenshots Platforms This project uses Cargo and pure Rust stable and works on latest

Matheus Lessa Rodrigues 214 Dec 26, 2022
client-server notification center for dbus desktop notifications

tsuchita A client-server notification center for dbus desktop notifications. Specifically org.freedesktop.Notifications dbus messages. Motivation I ju

Jeff Zhao 7 Oct 9, 2022
This is an implementation defining standard for client-side-validation

Client-side-validation Foundation Libraries This is an implementation defining standard of client-side-validation representing a set of its Foundation

LNP/BP Association 8 Dec 3, 2022
Rusty NuGet client

turron It's a NuGet client built in Rust. It's not really meant to replace existing nuget clients. It's more of a playground for experimenting with re

Kat Marchán 18 Feb 2, 2022
FerrisChat's Client

egui template This is a template repo for egui. The goal is for this to be the simplest way to get started writing a GUI app in Rust. You can compile

FerrisChat 5 Nov 23, 2022
A gitmoji interactive client for using gitmojis on commit messages.

gitmoji in Rust This is just an opinionated version of gitmoji-cli written in Rust . A gitmoji interactive client for using gitmojis on commit message

igor 2 Aug 16, 2022