Skip to main content

Remote access tool via npoint.io - encrypted command relay using AES-256-GCM

Project description

gcli

Remote access tool via npoint.io — encrypted command relay using AES-256-GCM.

How It Works

┌──────────┐     commands     ┌─────────────┐     commands     ┌──────────┐
│ gcli ssh │ ───────────────> │ npoint.io   │ ───────────────> │gcli host │
│ (client) │ <─────────────── │ (JSON bin)  │ <─────────────── │ (daemon) │
└──────────┘     results      └─────────────┘     results      └──────────┘
  1. gcli host starts a background daemon that polls npoint.io for encrypted commands
  2. gcli ssh connects interactively, sends encrypted commands, and polls for results
  3. All payloads are encrypted with AES-256-GCM — the password never leaves your machine

Quick Start

Install

pip install cryptography

Host (on the remote machine)

# Start the daemon (runs in background)
python -m gcli host --password MySecret123

# Or run in foreground for debugging
python -m gcli host --password MySecret123 --foreground

Client (on your local machine)

# Connect to the host
python -m gcli ssh --password MySecret123

Stop the host

python -m gcli stop

SSH Commands

Once connected, you have a full interactive REPL:

Command Description
Any text Execute shell command on remote host
:help Show available commands
:info Show remote system info (hostname, OS, user, IP)
:ping Ping remote host and show latency
:upload <local> <remote> Upload a file to the remote host
:download <remote> <local> Download a file from the remote host
:timeout <seconds> Set exec command timeout
:history Show recent command history
:exit Disconnect and close session

Security

  • AES-256-GCM encryption with PBKDF2 key derivation (600K iterations)
  • Password is never transmitted — only encrypted payloads flow through npoint.io
  • Each message gets a unique random nonce (prevents identical plaintext detection)
  • Built-in tamper detection (GCM authentication tag)

Cross-Platform

Platform Background Detach Process Management
Windows CREATE_NO_WINDOW subprocess tasklist / taskkill
Linux Double-fork + setsid kill / os.kill
macOS Double-fork + setsid kill / os.kill

Configuration

# Custom npoint bin (both host and client must use the same bin)
python -m gcli host --password MySecret --bin YOUR_NPOINT_BIN_ID
python -m gcli ssh --password MySecret --bin YOUR_NPOINT_BIN_ID

# Adjust polling speed (default: 2s host, 1s client)
python -m gcli host --password MySecret --poll-interval 1.0

Architecture

gcli/
├── __main__.py      # CLI entry point (argparse)
├── __init__.py
├── crypto.py        # AES-256-GCM encrypt/decrypt (PBKDF2 key derivation)
├── npoint.py        # npoint.io API wrapper with retry logic
├── protocol.py      # Document structure, read/write, race-condition safe appends
├── host.py          # Daemon: poll → decrypt → execute → encrypt → respond
├── client.py        # SSH REPL: send → poll → display (tab completion)
├── utils.py         # PID management, process detach, command execution
└── colors.py        # Cross-platform terminal colours (Win/Linux/macOS)

Requirements

  • Python 3.8+
  • cryptography package
  • Internet connection (for npoint.io)

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gcli_control-0.2.0.tar.gz (59.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gcli_control-0.2.0-py3-none-any.whl (62.8 kB view details)

Uploaded Python 3

File details

Details for the file gcli_control-0.2.0.tar.gz.

File metadata

  • Download URL: gcli_control-0.2.0.tar.gz
  • Upload date:
  • Size: 59.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.13

File hashes

Hashes for gcli_control-0.2.0.tar.gz
Algorithm Hash digest
SHA256 72e62327af378564dc56d322f1f233ca62cc5ce78c94528683156bbe957a89a8
MD5 202ebd77946a6d098f752c22d5c8c600
BLAKE2b-256 2895d4eb2c1516b619787248f37fc41913c9bc8dddf78c8925538d87dce9b7ff

See more details on using hashes here.

File details

Details for the file gcli_control-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: gcli_control-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 62.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.13

File hashes

Hashes for gcli_control-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 327bae03ec22b566d6d0a21e679eeb61442954967bfe2d0c1b4fc64034e81a28
MD5 6cb24af3ebb6173015564873ee947204
BLAKE2b-256 63917243546b9f37a51bfe0fe2e370c5f3783a717bcc12757f2d149c46f5af4f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page