SkillAgentSearch skills...

Portal

A Secure file transfer utility & library. The library utilizes SPAKE2 for key negotiation over an insecure channel, and ChaCha20Poly1305 Authenticated Encryption to encrypt the file with the derived shared symmetric key. This enables two peers to transfer a file over any channel without needing to trust the intermediary relay.

Install / Use

/learn @landhb/Portal
About this skill

Quality Score

0/100

Supported Platforms

Universal

README

Portal

cargo-badge-lib docs-badge-lib license-badge rust-version-badge build codecov

Securely & quickly transport your files.

Client Install

cargo-badge-client

The client binary can be installed via Cargo:

cargo install portal-client

On the first run, a configuration file will be created in:

|Platform | Value | Example | | ------- | ------------------------------------- | ---------------------------------------- | | Linux | $XDG_CONFIG_HOME or $HOME/.config | /home/alice/.config/portal | | macOS | $HOME/Library/Application Support | /Users/Alice/Library/Application Support/portal | | Windows | {FOLDERID_RoamingAppData} | C:\Users\Alice\AppData\Roaming\portal |

Note: The default relay is portal-relay.landhb.dev. Your peer must connect to the same portal-relay as you. You can also host your own relay and change the value to any domain/IP address in your config.

To send a file:

portal send /path/to/file

To receive a file:

portal recv

Relay Install

cargo-badge-relay

If you wish to run your own relay, you can install the binary on a server with:

cargo install portal-relay

Note: An example service file is included in the relay/ directory.

Development:

The repo is a cargo workspace with the following directory structure:

lib/        # implementation of the protocol
relay/      # relay server source
client/     # client source

You can run the binaries individually with:

# window 1
cargo run --bin portal-relay

# window 2
cargo run --bin portal -- recv

# window 3
cargo run --bin portal -- send [FILE]

Acknowledgements:

This tool was a quick early pandemic project to learn rust, and has similar ideas/functionality to Wormhole written by Brian Warner, he actually also contributed a large amount to the RustCrypto project's SPAKE2 implementation that Portal uses.

View on GitHub
GitHub Stars25
CategoryDevelopment
Updated4mo ago
Forks3

Languages

Rust

Security Score

92/100

Audited on Nov 15, 2025

No findings