• Stars
    star
    3,519
  • Rank 12,170 (Top 0.3 %)
  • Language
    C
  • License
    MIT License
  • Created about 7 years ago
  • Updated 3 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

🐛 Access your terminal from anywhere via the web.

rtty(中文)

This project is officially supported by GL.iNet.

license PRs Welcome Issue Welcome Release Version Build Status visitors Support rtty

It is composed of a client and a server. The client is written in pure C. The server is written in go language and the front-end is written in Vue.

You can access your device's terminal from anywhere via the web. Differentiate your different device by device ID.

rtty is very suitable for remote maintenance your or your company's thousands of Linux devices deployed around the world.

Features

  • The client is writen in C language, very small, suitable for embedded Linux
    • No SSL: rtty(32K) + libev(56K)
    • Support SSL: + libmbedtls(88K) + libmbedcrypto(241K) + libmbedx509(48k)
  • Execute command remotely in a batch of devices
  • SSL support: openssl, mbedtls, CyaSSl(wolfssl)
  • mTLS
  • Very convenient to upload and download files
  • Access different devices based on device ID
  • Support HTTP Proxy - Access your device's Web
  • Fully-featured terminal based on Xterm.js
  • Simple to deployment and easy to use

Who's using rtty

Dependencies of the Client side

Deploying the server side

How to install rtty

For Linux distribution

Install Dependencies

sudo apt install -y libev-dev libssl-dev      # Ubuntu, Debian
sudo pacman -S --noconfirm libev openssl      # ArchLinux
sudo yum install -y libev-devel openssl-devel # Centos

Clone the code of rtty

git clone --recursive https://github.com/zhaojh329/rtty.git

Build

cd rtty && mkdir build && cd build
cmake .. && make install

For Buildroot

Select rtty in menuconfig and compile it

Target packages  --->
    Shell and utilities  --->
        [*] rtty

For OpenWRT

For Other Embedded Linux Platform

Command-line Options

Usage: rtty [option]
    -I, --id=string          Set an ID for the device(Maximum 63 bytes, valid
                             character:letter, number, underline and short line)
    -h, --host=string        Server's host or ipaddr(Default is localhost)
    -p, --port=number        Server port(Default is 5912)
    -d, --description=string Add a description to the device(Maximum 126 bytes)
    -a                       Auto reconnect to the server
    -s                       SSL on
    -C, --cacert             CA certificate to verify peer against
    -x, --insecure           Allow insecure server connections when using SSL
    -c, --cert               Certificate file to use"
    -k, --key                Private key file to use"
    -D                       Run in the background
    -t, --token=string       Authorization token
    -f username              Skip a second login authentication. See man login(1) about the details
    -R                       Receive file
    -S file                  Send file
    -v, --verbose            verbose
    -V, --version            Show version
    --help                   Show usage

How to run rtty

Replace the following parameters with your own parameters

sudo rtty -I 'My-device-ID' -h 'your-server' -p 5912 -a -v -d 'My Device Description'

If your rttys is configured with mTLS enabled (device key and certificate required), add the following parameters(Replace the following with valid paths to your own)

-k /etc/ssl/private/abc.pem -c /etc/ssl/certs/abc.pem

You can generate them e.g. via openssl tool openssl req -x509 -newkey ec -pkeyopt ec_paramgen_curve:secp521r1 -keyout /tmp/key.pem -out /tmp/cert.pem -days 18262 -nodes -subj "/C=CZ/O=Acme Inc./OU=ACME/CN=ACME-DEV-123"

If your rttys is configured with a token, add the following parameter(Replace the following token with your own)

-t 34762d07637276694b938d23f10d7164

Usage

Use your web browser to access your server: http://your-server-host:5913, then click the connection button

connect devices with no web login required(you need to configure the device white list on the server)

http://your-server-host:5913/connect/devid1

http://your-server-host:5913/connect/devid2

Transfer file

Transfer file from local to remote device

rtty -R

Transfer file from remote device to the local

rtty -S test.txt

Execute command remotely

Contributing

If you would like to help making rtty better, see the CONTRIBUTING.md file.

Donation

If this project does help you, please consider donating to support the development of this project.

More Repositories

1

oui

🐛 A framework used to develop Web interface for OpenWrt. Use Lua-eco + Vue3 + Vite + Element Plus.
C
1,004
star
2

rttys

Access your device's terminal from anywhere via the web.
Go
636
star
3

libuhttpd

A very flexible, lightweight and high performance HTTP server library based on libev and http-parser for Embedded Linux.
C
375
star
4

libuwsc

A Lightweight and fully asynchronous WebSocket client library based on libev
C
287
star
5

wifidog-ng

Next generation WifiDog implemented in Lua.
Lua
223
star
6

evmongoose

DEPRECATED. Evmongoose is an asynchronous, event(libev) based multi-protocol embedded networking library with functions including TCP, HTTP, WebSocket, MQTT and much more. It's based on mongoose and libev implementation and it's support Lua API.
C
211
star
7

libumqtt

A Lightweight and fully asynchronous MQTT client C library based on libev
C
189
star
8

xluci2

DEPRECATED. xLuCI2 is a JavaScript Webgui for embedded devices running OpenWRT or LEDE
JavaScript
151
star
9

U-boot-1

U-boot学习笔记
86
star
10

lua-eco

🐛Lua-eco is a Lua interpreter with a built-in event loop for scheduling lightweight coroutines automatically, enabling efficient concurrency in Lua. Build high-performance, scalable applications.
C
57
star
11

wifidog-ng-authserver

A simple auth server for wifidog-ng to test
Go
22
star
12

buffer

A buffer similar to the skbuff in the kernel, but more suitable for application.
C
14
star
13

barebox

Better barebox. Support AR9331, AR9344 and more...
C
13
star
14

ssl

The encapsulation of OpenSSL, WolfSSL, and MBEDTLS aims to make usage easy.
C
6
star
15

log

C
3
star