The UXSP package includes a built-in terminal CLI (uxsp). You can run it directly from your command line to manage cryptographic identities, issue Trust Anchor certificates, send/receive encrypted files, stream multi-gigabyte media, and test API endpoints with autonomous protocol switching.
flowchart TD
CLI["uxsp (Terminal CLI)"]
CLI --> ID["Identity Management<br/>keygen | pubcard | info | rotate | revoke"]
CLI --> ANCHOR["Trust Anchor PKI<br/>anchor create | anchor issue"]
CLI --> SECURE["1-Line File/Text Encryption<br/>secure send | secure receive"]
CLI --> STREAM["Low-Memory Streaming<br/>stream send | stream receive"]
CLI --> CLIENT["Protocol-Switching Client<br/>client probe | client GET/POST"]
When you install uxsp via pip, the uxsp executable is registered automatically in your PATH:
pip install uxspVerify your installation:
uxsp versionExpected Output:
uxsp 1.3.2
Every machine, service, or client interacting with UXSP requires an Identity (holding private keys) and an exportable PublicCard (holding public keys).
To generate an identity keypair containing all 4 hybrid algorithms (X25519, Ed25519, ML-KEM-768, ML-DSA-65):
uxsp keygen --name "Alice" --role "CLIENT" --out alice.uxspYou will be interactively prompted to enter and confirm a password:
Enter password to encrypt key: ********
Confirm password: ********
Identity created: 8f24a180-2a7e-4001-9c62-d278074d284f
Saved to: alice.uxsp
The resulting .uxsp file is encrypted on disk with Argon2id key derivation and AES-256-GCM, making it secure even if copied from your machine.
You should never share your .uxsp identity file with peers. Instead, extract the public card:
uxsp pubcard --key alice.uxsp --out alice.card.jsonPassword: ********
Public card for 'Alice' (CLIENT)
Entity ID : 8f24a180-2a7e-4001-9c62-d278074d284f
Saved to : alice.card.json
Share alice.card.json with the backend server or your communication partners.
To view the metadata, creation timestamp, and key versions without exposing private keys:
uxsp info --key alice.uxspPassword: ********
Entity ID : 8f24a180-2a7e-4001-9c62-d278074d284f
Name : Alice
Role : CLIENT
Created : 2026-09-13T10:15:30Z
If a key needs to be cycled according to security policy:
uxsp rotate --key alice.uxspPassword: ********
Rotated keys for 'Alice' (new key_version: 2).
Saved to: alice.uxsp
Export a new public card with uxsp pubcard after rotation.
If a private key or laptop was compromised:
uxsp revoke --key alice.uxsp --reason "Device lost in transit"Password: ********
Identity 8f24a180-2a7e-4001-9c62-d278074d284f marked REVOKED.
Reason: Device lost in transit
In enterprise or zero-trust deployments, you can create a local Root CA (Trust Anchor) to cryptographically sign public cards and enforce validity windows.
uxsp anchor create --name "Corp-Root-CA" --out root_ca.uxspEnter password to encrypt anchor key: ********
Confirm password: ********
Trust Anchor created: 04e3b1c2-1234-4567-89ab-cdef01234567
Saved to: root_ca.uxsp
Sign Alice's public card with the Trust Anchor for 90 days:
uxsp anchor issue --anchor root_ca.uxsp --card alice.card.json --days 90 --out alice.signed.card.jsonAnchor password: ********
Signed card created for 'Alice'.
Valid until: 2026-12-12T10:15:30Z
Saved to: alice.signed.card.json
You can use the CLI to securely transfer files between servers, backup encrypted databases, or test encryption pipelines.
Let's encrypt a confidential file database_dump.sql for Bob using Bob's public card bob.card.json:
uxsp secure send \
--sender alice.uxsp \
--receiver-card bob.card.json \
--type file \
--file database_dump.sql \
--out backup.encSender key password: ********
Encrypted 1,482,900 bytes as type 'file'
Package written to: backup.enc
Bob receives backup.enc and decrypts it with his private key:
uxsp secure receive \
--receiver bob.uxsp \
--package backup.enc \
--out restored_dump.sqlReceiver key password: ********
Sender verified : Alice (8f24a180-2a7e-4001-9c62-d278074d284f)
Payload type : file
Restored to : restored_dump.sql
For files larger than 1GB (up to 100GB+), use uxsp stream send and uxsp stream receive. These commands process data in 64KB chunks with constant memory usage.
# Encrypt and stream large VM image or archive
uxsp stream send \
--sender alice.uxsp \
--receiver-card bob.card.json \
--file ubuntu_server.iso \
--out stream.enc
# Receive and decrypt chunk-by-chunk on destination server
uxsp stream receive \
--receiver bob.uxsp \
--package stream.enc \
--out restored_ubuntu.isoThe CLI includes an autonomous HTTP client capable of protocol negotiation and post-quantum encryption:
Test if a remote endpoint supports UXSP without sending any secret data:
uxsp client https://api.example.com/health --verbose[uxsp] Probing https://api.example.com/health...
[uxsp] Server supports UXSP (version UXSP/1.3).
HTTP/1.1 200 OK
Content-Type: application/json
{"status": "ok", "uxsp_active": true}
Send an authenticated JSON payload to a protected endpoint:
uxsp client https://api.example.com/secure-data \
--method POST \
--data '{"account": "1001", "amount": 500}' \
--sender alice.uxsp \
--peer bob.card.json \
--header "Authorization: Bearer token123"The CLI transparently:
- Negotiates protocol support with the server.
- Encapsulates ML-KEM-768 and X25519 keys.
- Signs the request with Ed25519 and ML-DSA-65.
- Encrypts the body with AES-256-GCM.
- Receives and decrypts the response.
To avoid interactive password prompts in bash scripts, cron jobs, or CI/CD pipelines, set the UXSP_PASSWORD environment variable:
export UXSP_PASSWORD="MySuperSecretPassword"
uxsp info --key alice.uxsp| Command | Action | Key Flags |
|---|---|---|
uxsp keygen |
Generate hybrid identity | --name, --role, --out |
uxsp pubcard |
Export shareable public card | --key, --out |
uxsp info |
View identity metadata | --key |
uxsp rotate |
Cycle keys to new version | --key |
uxsp revoke |
Revoke compromised identity | --key, --reason |
uxsp anchor create |
Initialize root CA | --name, --out |
uxsp anchor issue |
Sign public card with CA | --anchor, --card, --days, --out |
uxsp secure send |
Encrypt payload/file | --sender, --receiver-card, --type, --data/--file, --out |
uxsp secure receive |
Decrypt payload/file | --receiver, --package, --out |
uxsp stream send |
Stream large file chunk-by-chunk | --sender, --receiver-card, --file, --out |
uxsp stream receive |
Receive streamed file | --receiver, --package, --out |
uxsp client |
Autonomous HTTP request | <url>, --method, --data, --sender, --peer, --verbose |