akashcli 4.6.9__tar.gz → 4.7.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- akashcli-4.7.0/PKG-INFO +272 -0
- akashcli-4.7.0/README.md +253 -0
- akashcli-4.7.0/akashcli/__init__.py +26 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/cli.py +1380 -407
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/client.py +2 -2
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/config.py +23 -0
- akashcli-4.7.0/akashcli/crypto.py +63 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/exec.py +2 -2
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/p2p.py +1 -1
- akashcli-4.7.0/akashcli/packages.py +688 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/relay.py +1 -1
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/restore.py +127 -61
- akashcli-4.7.0/akashcli/storage.py +490 -0
- akashcli-4.7.0/akashcli/terminal.py +660 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/uploader.py +11 -3
- akashcli-4.7.0/akashcli.egg-info/PKG-INFO +272 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/pyproject.toml +1 -1
- akashcli-4.6.9/PKG-INFO +0 -145
- akashcli-4.6.9/README.md +0 -126
- akashcli-4.6.9/akashcli/__init__.py +0 -7
- akashcli-4.6.9/akashcli/crypto.py +0 -42
- akashcli-4.6.9/akashcli/packages.py +0 -315
- akashcli-4.6.9/akashcli/storage.py +0 -328
- akashcli-4.6.9/akashcli/terminal.py +0 -527
- akashcli-4.6.9/akashcli.egg-info/PKG-INFO +0 -145
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/_net.py +0 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/auth.py +0 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/env_manager.py +0 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/exceptions.py +0 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/integrity.py +0 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/logger.py +0 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/models.py +0 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/snapshot_crypto.py +0 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli/utils.py +0 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli.egg-info/SOURCES.txt +0 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli.egg-info/dependency_links.txt +0 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli.egg-info/entry_points.txt +0 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli.egg-info/requires.txt +0 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/akashcli.egg-info/top_level.txt +0 -0
- {akashcli-4.6.9 → akashcli-4.7.0}/setup.cfg +0 -0
akashcli-4.7.0/PKG-INFO
ADDED
|
@@ -0,0 +1,272 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: akashcli
|
|
3
|
+
Version: 4.7.0
|
|
4
|
+
Summary: Akash CLI — secure remote shell relay, file vault, and device management
|
|
5
|
+
License-Expression: MIT
|
|
6
|
+
Keywords: akash,cli,relay,remote-shell,vault
|
|
7
|
+
Classifier: Programming Language :: Python :: 3
|
|
8
|
+
Classifier: Operating System :: OS Independent
|
|
9
|
+
Classifier: Environment :: Console
|
|
10
|
+
Classifier: Topic :: Utilities
|
|
11
|
+
Requires-Python: >=3.9
|
|
12
|
+
Description-Content-Type: text/markdown
|
|
13
|
+
Requires-Dist: httpx
|
|
14
|
+
Requires-Dist: certifi
|
|
15
|
+
Requires-Dist: typer
|
|
16
|
+
Requires-Dist: cryptography
|
|
17
|
+
Requires-Dist: pydantic
|
|
18
|
+
Requires-Dist: websockets
|
|
19
|
+
|
|
20
|
+
<div align="center">
|
|
21
|
+
|
|
22
|
+
# ⚡ Akash CLI (`akash`)
|
|
23
|
+
### Encrypted Cloud Vault · Remote Terminal Relay · AI Agent Tool Bridge
|
|
24
|
+
|
|
25
|
+
[](https://python.org)
|
|
26
|
+
[](https://cryptography.io)
|
|
27
|
+
[](https://modelcontextprotocol.io)
|
|
28
|
+
[](LICENSE)
|
|
29
|
+
|
|
30
|
+
*The developer-first CLI for instant environment backups, zero-setup remote terminals, encrypted peer-to-peer file transfers, and safe AI agent execution.*
|
|
31
|
+
|
|
32
|
+
---
|
|
33
|
+
|
|
34
|
+
[📖 Easy Master Guide](GUIDE.md) •
|
|
35
|
+
[Quickstart](#-quickstart-in-60-seconds) •
|
|
36
|
+
[Core Features](#-core-features) •
|
|
37
|
+
[Zero-Login Guest Mode](#-zero-login-guest-mode) •
|
|
38
|
+
[Documentation](#-in-depth-documentation-guides) •
|
|
39
|
+
[Command Matrix](#-command-matrix)
|
|
40
|
+
|
|
41
|
+
---
|
|
42
|
+
|
|
43
|
+
</div>
|
|
44
|
+
|
|
45
|
+
## 🌟 Why Akash CLI?
|
|
46
|
+
|
|
47
|
+
Modern developer workflows demand flexibility across multiple machines — laptops, cloud servers, and mobile environments like Android Termux. Akash CLI solves daily pain points with a unified, secure toolkit:
|
|
48
|
+
|
|
49
|
+
* 🖥️ **Remote Shell Anywhere**: Connect to any remote device or share an interactive terminal session in seconds across firewalls and NATs.
|
|
50
|
+
* 💾 **Instant Environment Snapshots**: Backup dotfiles, shell configs, and package inventories with automated secret scrubbing and 1-click restore.
|
|
51
|
+
* ☁️ **Encrypted Cloud Vault**: Store files, stream video directly into VLC, and pipe shell outputs without writing to disk.
|
|
52
|
+
* 🔐 **P2P Zero-Knowledge Transfers**: Send end-to-end encrypted files to other users using X25519 ECDH — even the storage server cannot inspect them.
|
|
53
|
+
* 🔒 **Hardware-Bound .env Store**: Manage local and cloud-synced environment variables encrypted with machine-specific seeds.
|
|
54
|
+
* 🤖 **AI Agent Gateway (MCP)**: Safely expose local tools to Cursor IDE and Claude Desktop with real-time terminal approval guards and auto-undo checkpoints.
|
|
55
|
+
|
|
56
|
+
---
|
|
57
|
+
|
|
58
|
+
## 🚀 Quickstart in 60 Seconds
|
|
59
|
+
|
|
60
|
+
### 1. Installation
|
|
61
|
+
```bash
|
|
62
|
+
# Clone and install in editable mode:
|
|
63
|
+
git clone https://github.com/juniorsir/akashcli.git
|
|
64
|
+
cd akashcli
|
|
65
|
+
pip install -e . --break-system-packages
|
|
66
|
+
```
|
|
67
|
+
|
|
68
|
+
### 2. Connect Your Machine
|
|
69
|
+
Obtain an API key from the [Akash Telegram Bot](https://t.me/EveryDL_bot) (go to **👤 My Account** ➔ **🔑 Generate API Key**), then run:
|
|
70
|
+
```bash
|
|
71
|
+
akash login --label "laptop"
|
|
72
|
+
```
|
|
73
|
+
*(Alternatively, explore without logging in using [Guest Mode](#-zero-login-guest-mode)!)*
|
|
74
|
+
|
|
75
|
+
### 3. Check Account Status
|
|
76
|
+
```bash
|
|
77
|
+
akash whoami
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
---
|
|
81
|
+
|
|
82
|
+
## 🤝 Zero-Login Guest Mode
|
|
83
|
+
|
|
84
|
+
Need to pair two machines instantly without an account or API key?
|
|
85
|
+
|
|
86
|
+
```bash
|
|
87
|
+
# On Machine A (Host):
|
|
88
|
+
akash serve --share
|
|
89
|
+
# ➔ Generates pairing code: A3F7B2
|
|
90
|
+
|
|
91
|
+
# On Machine B (Client):
|
|
92
|
+
akash shell --code A3F7B2
|
|
93
|
+
# ➔ Instantly connected to Host's interactive terminal!
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
---
|
|
97
|
+
|
|
98
|
+
## ⚡ Core Features
|
|
99
|
+
|
|
100
|
+
### 1. 💾 Environment Backups & Disaster Recovery
|
|
101
|
+
Capture your entire shell setup and restore it on any machine in seconds:
|
|
102
|
+
```bash
|
|
103
|
+
# Save your terminal configuration to cloud (or local file with -o):
|
|
104
|
+
akash backup --label "workstation"
|
|
105
|
+
|
|
106
|
+
# Restore on a new computer (zero login required):
|
|
107
|
+
akash pull 8k9F2a
|
|
108
|
+
|
|
109
|
+
# Restore from cloud code or local archive:
|
|
110
|
+
akash restore 8k9F2a
|
|
111
|
+
akash restore ~/my_backup.tar.gz
|
|
112
|
+
|
|
113
|
+
# Preview what will be extracted before touching disk:
|
|
114
|
+
akash restore 8k9F2a --dry-run
|
|
115
|
+
akash restore 8k9F2a --tree
|
|
116
|
+
```
|
|
117
|
+
* **Auto Secret Scrubbing**: Redacts tokens, passwords, and private keys from history files.
|
|
118
|
+
* **Bloat Pruning**: Skips `node_modules`, `__pycache__`, and `.venv`.
|
|
119
|
+
* **Package Manifests**: Inventories `apt`, `brew`, `pip`, `npm`, `cargo` for auto-reinstallation.
|
|
120
|
+
|
|
121
|
+
### 2. 🖥️ Remote Shells & Persistent Devices
|
|
122
|
+
Manage your fleet of servers and workstations:
|
|
123
|
+
```bash
|
|
124
|
+
# Run listener on your phone or remote server:
|
|
125
|
+
akash serve --daemon --label termux
|
|
126
|
+
|
|
127
|
+
# Open interactive shell from your laptop:
|
|
128
|
+
akash shell --device termux
|
|
129
|
+
|
|
130
|
+
# Run individual command remotely:
|
|
131
|
+
akash run "uptime" --device termux
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
### 3. ☁️ Cloud File Vault & Streaming
|
|
135
|
+
```bash
|
|
136
|
+
# Upload a file with 7-day auto-expiry:
|
|
137
|
+
akash cloud upload my_doc.pdf --expiry 7
|
|
138
|
+
|
|
139
|
+
# One-time burn-after-read:
|
|
140
|
+
akash cloud upload --burn secret_report.pdf
|
|
141
|
+
|
|
142
|
+
# Stream video directly into VLC without downloading:
|
|
143
|
+
akash cloud stream 7xY3a0 --vlc
|
|
144
|
+
|
|
145
|
+
# Pipe command output directly into the cloud vault:
|
|
146
|
+
mysqldump -u root db | akash pipe -n "db_backup.sql"
|
|
147
|
+
```
|
|
148
|
+
|
|
149
|
+
### 4. 🔐 P2P Encrypted File Transfers
|
|
150
|
+
Zero-knowledge file exchange using Curve25519 / X25519:
|
|
151
|
+
```bash
|
|
152
|
+
# View your public key and fingerprint:
|
|
153
|
+
akash id
|
|
154
|
+
|
|
155
|
+
# Send encrypted file to a contact:
|
|
156
|
+
akash send bob sensitive_dataset.zip -m "Q3 dataset"
|
|
157
|
+
|
|
158
|
+
# Recipient receives and decrypts:
|
|
159
|
+
akash inbox
|
|
160
|
+
akash inbox 7qR92x
|
|
161
|
+
```
|
|
162
|
+
|
|
163
|
+
### 5. 🔒 Hardware-Encrypted .env Store
|
|
164
|
+
```bash
|
|
165
|
+
# Set secrets into encrypted store:
|
|
166
|
+
akash env set prod DATABASE_URL="postgresql://user:pass@host/db"
|
|
167
|
+
|
|
168
|
+
# Retrieve secret for automation:
|
|
169
|
+
akash env get prod DATABASE_URL --raw
|
|
170
|
+
|
|
171
|
+
# Push encrypted secrets to cloud vault with burn-on-read:
|
|
172
|
+
akash env push prod --burn
|
|
173
|
+
|
|
174
|
+
# Pull secrets onto remote server:
|
|
175
|
+
akash env pull eX481p prod
|
|
176
|
+
```
|
|
177
|
+
|
|
178
|
+
### 6. 🤖 AI Agent Gateway (MCP) & Guard Console
|
|
179
|
+
Supercharge Cursor and Claude Desktop with local terminal execution, protected by real-time human approval:
|
|
180
|
+
```bash
|
|
181
|
+
# 1. Create agent profile with safe role preset:
|
|
182
|
+
akash agent create --name "Cursor" --role @coder
|
|
183
|
+
|
|
184
|
+
# 2. Generate configuration snippet for Cursor / Claude Desktop:
|
|
185
|
+
akash mcp share --claude --temp 30m
|
|
186
|
+
|
|
187
|
+
# 3. Start local tool execution worker with auto-undo checkpoints:
|
|
188
|
+
akash mcp serve
|
|
189
|
+
|
|
190
|
+
# 4. In a separate terminal, open live approval console:
|
|
191
|
+
akash guard
|
|
192
|
+
```
|
|
193
|
+
|
|
194
|
+
---
|
|
195
|
+
|
|
196
|
+
## 📚 In-Depth Documentation Guides
|
|
197
|
+
|
|
198
|
+
Explore comprehensive guides in the [`docs/`](docs/) directory:
|
|
199
|
+
|
|
200
|
+
| Document | Topic Covered |
|
|
201
|
+
| :--- | :--- |
|
|
202
|
+
| **[01. Quickstart & Installation](docs/01-quickstart-and-install.md)** | Setup on Linux, macOS, Windows, Android Termux / PRoot, and troubleshooting |
|
|
203
|
+
| **[02. Remote Terminal & Relays](docs/02-remote-terminal-and-relays.md)** | WebSocket relay, 1-click guest pairing, background daemons, remote execution |
|
|
204
|
+
| **[03. Environment Backups](docs/03-backup-and-disaster-recovery.md)** | Dotfile snapshots, secret scrubbing, visual tree explorer, package recovery |
|
|
205
|
+
| **[04. Cloud Vault & Streaming](docs/04-cloud-vault-and-streaming.md)** | Uploads, burn-after-read, direct VLC streaming, Unix pipe streaming |
|
|
206
|
+
| **[05. P2P Encrypted Transfers](docs/05-p2p-encrypted-transfers.md)** | X25519 ECDH asymmetric encryption, zero-knowledge storage, inbox management |
|
|
207
|
+
| **[06. Secrets & .env Vault](docs/06-env-and-secrets-vault.md)** | Local encrypted store, .env file import/export, cloud push/pull sync |
|
|
208
|
+
| **[07. AI Agents & MCP](docs/07-ai-agents-and-mcp.md)** | Model Context Protocol, Claude/Cursor integration, terminal guard approvals |
|
|
209
|
+
| **[08. Security & Integrity Audit](docs/08-security-integrity-audit.md)** | Hardware machine keys, SHA-256 HMAC code integrity sealing, audit logs |
|
|
210
|
+
| **[09. Full Command Reference](docs/09-full-command-reference.md)** | Exhaustive command cheat-sheet with every argument, flag, and option |
|
|
211
|
+
|
|
212
|
+
---
|
|
213
|
+
|
|
214
|
+
## 📊 Command Matrix
|
|
215
|
+
|
|
216
|
+
```text
|
|
217
|
+
akash
|
|
218
|
+
├── login Connect API key with hardware binding
|
|
219
|
+
├── whoami Account quota & device fingerprint
|
|
220
|
+
├── backup Save terminal environment to cloud or local archive
|
|
221
|
+
├── restore Restore environment (with --tree, --explore, --dry-run)
|
|
222
|
+
├── saves List cloud-saved terminal snapshots
|
|
223
|
+
├── shell Open interactive PTY (local, remote device, or guest code)
|
|
224
|
+
├── run Execute command remotely or save output to vault
|
|
225
|
+
├── serve Make device reachable (--daemon, --share for guest mode)
|
|
226
|
+
├── devices List, authorize, or revoke enrolled machines
|
|
227
|
+
├── cloud
|
|
228
|
+
│ ├── upload Upload file or secret text snippet
|
|
229
|
+
│ ├── files List vault files
|
|
230
|
+
│ ├── stream Direct streaming link or launch in VLC
|
|
231
|
+
│ ├── bulk Recursively upload directory
|
|
232
|
+
│ └── delete Purge file permanently
|
|
233
|
+
├── pipe Upload stdin or command output directly to cloud
|
|
234
|
+
├── send End-to-end encrypted P2P transfer to user public key
|
|
235
|
+
├── inbox Receive and decrypt incoming P2P files
|
|
236
|
+
├── id View or export P2P identity key and manage contacts
|
|
237
|
+
├── env
|
|
238
|
+
│ ├── list List env stores or keys
|
|
239
|
+
│ ├── set Add or update key-value secret
|
|
240
|
+
│ ├── get Retrieve secret (--raw for scripting)
|
|
241
|
+
│ ├── import Import .env file into encrypted store
|
|
242
|
+
│ ├── export Export encrypted store to .env
|
|
243
|
+
│ ├── push Push encrypted store to cloud vault
|
|
244
|
+
│ └── pull Pull and restore env store on new machine
|
|
245
|
+
├── agent
|
|
246
|
+
│ ├── create Generate agent profile (Client ID + Secret + Scopes)
|
|
247
|
+
│ ├── list List agent profiles
|
|
248
|
+
│ └── revoke Revoke agent access
|
|
249
|
+
├── mcp
|
|
250
|
+
│ ├── serve High-reliability MCP worker with undo checkpoints
|
|
251
|
+
│ ├── share Generate configuration snippet for Claude & Cursor
|
|
252
|
+
│ ├── guard Interactive terminal approval console
|
|
253
|
+
│ └── status One-glance MCP gateway status
|
|
254
|
+
├── check Verify package source integrity (--seal to update)
|
|
255
|
+
└── log Operational audit log (--stats for graphic summary)
|
|
256
|
+
```
|
|
257
|
+
|
|
258
|
+
---
|
|
259
|
+
|
|
260
|
+
## 🛡️ Security & Privacy Architecture
|
|
261
|
+
|
|
262
|
+
Akash CLI enforces security at every layer:
|
|
263
|
+
1. **Zero-Knowledge P2P Transfers**: Files are encrypted with X25519 and AES-256-GCM before leaving your device.
|
|
264
|
+
2. **Machine-Bound Secrets**: Local tokens, `.env` stores, and keys are tied to a unique `~/.akash/machine.key` that cannot be copied to other systems.
|
|
265
|
+
3. **Automated Secret Sanitization**: Sensitive variables, connection strings, and tokens in shell history files are scrubbed prior to archiving.
|
|
266
|
+
4. **Source Tamper Detection**: `akash check` computes cryptographic HMAC digests over package files to block malicious code modifications.
|
|
267
|
+
|
|
268
|
+
---
|
|
269
|
+
|
|
270
|
+
## 📄 License
|
|
271
|
+
|
|
272
|
+
Distributed under the MIT License. See [LICENSE](LICENSE) for details.
|
akashcli-4.7.0/README.md
ADDED
|
@@ -0,0 +1,253 @@
|
|
|
1
|
+
<div align="center">
|
|
2
|
+
|
|
3
|
+
# ⚡ Akash CLI (`akash`)
|
|
4
|
+
### Encrypted Cloud Vault · Remote Terminal Relay · AI Agent Tool Bridge
|
|
5
|
+
|
|
6
|
+
[](https://python.org)
|
|
7
|
+
[](https://cryptography.io)
|
|
8
|
+
[](https://modelcontextprotocol.io)
|
|
9
|
+
[](LICENSE)
|
|
10
|
+
|
|
11
|
+
*The developer-first CLI for instant environment backups, zero-setup remote terminals, encrypted peer-to-peer file transfers, and safe AI agent execution.*
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
[📖 Easy Master Guide](GUIDE.md) •
|
|
16
|
+
[Quickstart](#-quickstart-in-60-seconds) •
|
|
17
|
+
[Core Features](#-core-features) •
|
|
18
|
+
[Zero-Login Guest Mode](#-zero-login-guest-mode) •
|
|
19
|
+
[Documentation](#-in-depth-documentation-guides) •
|
|
20
|
+
[Command Matrix](#-command-matrix)
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
</div>
|
|
25
|
+
|
|
26
|
+
## 🌟 Why Akash CLI?
|
|
27
|
+
|
|
28
|
+
Modern developer workflows demand flexibility across multiple machines — laptops, cloud servers, and mobile environments like Android Termux. Akash CLI solves daily pain points with a unified, secure toolkit:
|
|
29
|
+
|
|
30
|
+
* 🖥️ **Remote Shell Anywhere**: Connect to any remote device or share an interactive terminal session in seconds across firewalls and NATs.
|
|
31
|
+
* 💾 **Instant Environment Snapshots**: Backup dotfiles, shell configs, and package inventories with automated secret scrubbing and 1-click restore.
|
|
32
|
+
* ☁️ **Encrypted Cloud Vault**: Store files, stream video directly into VLC, and pipe shell outputs without writing to disk.
|
|
33
|
+
* 🔐 **P2P Zero-Knowledge Transfers**: Send end-to-end encrypted files to other users using X25519 ECDH — even the storage server cannot inspect them.
|
|
34
|
+
* 🔒 **Hardware-Bound .env Store**: Manage local and cloud-synced environment variables encrypted with machine-specific seeds.
|
|
35
|
+
* 🤖 **AI Agent Gateway (MCP)**: Safely expose local tools to Cursor IDE and Claude Desktop with real-time terminal approval guards and auto-undo checkpoints.
|
|
36
|
+
|
|
37
|
+
---
|
|
38
|
+
|
|
39
|
+
## 🚀 Quickstart in 60 Seconds
|
|
40
|
+
|
|
41
|
+
### 1. Installation
|
|
42
|
+
```bash
|
|
43
|
+
# Clone and install in editable mode:
|
|
44
|
+
git clone https://github.com/juniorsir/akashcli.git
|
|
45
|
+
cd akashcli
|
|
46
|
+
pip install -e . --break-system-packages
|
|
47
|
+
```
|
|
48
|
+
|
|
49
|
+
### 2. Connect Your Machine
|
|
50
|
+
Obtain an API key from the [Akash Telegram Bot](https://t.me/EveryDL_bot) (go to **👤 My Account** ➔ **🔑 Generate API Key**), then run:
|
|
51
|
+
```bash
|
|
52
|
+
akash login --label "laptop"
|
|
53
|
+
```
|
|
54
|
+
*(Alternatively, explore without logging in using [Guest Mode](#-zero-login-guest-mode)!)*
|
|
55
|
+
|
|
56
|
+
### 3. Check Account Status
|
|
57
|
+
```bash
|
|
58
|
+
akash whoami
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
---
|
|
62
|
+
|
|
63
|
+
## 🤝 Zero-Login Guest Mode
|
|
64
|
+
|
|
65
|
+
Need to pair two machines instantly without an account or API key?
|
|
66
|
+
|
|
67
|
+
```bash
|
|
68
|
+
# On Machine A (Host):
|
|
69
|
+
akash serve --share
|
|
70
|
+
# ➔ Generates pairing code: A3F7B2
|
|
71
|
+
|
|
72
|
+
# On Machine B (Client):
|
|
73
|
+
akash shell --code A3F7B2
|
|
74
|
+
# ➔ Instantly connected to Host's interactive terminal!
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
---
|
|
78
|
+
|
|
79
|
+
## ⚡ Core Features
|
|
80
|
+
|
|
81
|
+
### 1. 💾 Environment Backups & Disaster Recovery
|
|
82
|
+
Capture your entire shell setup and restore it on any machine in seconds:
|
|
83
|
+
```bash
|
|
84
|
+
# Save your terminal configuration to cloud (or local file with -o):
|
|
85
|
+
akash backup --label "workstation"
|
|
86
|
+
|
|
87
|
+
# Restore on a new computer (zero login required):
|
|
88
|
+
akash pull 8k9F2a
|
|
89
|
+
|
|
90
|
+
# Restore from cloud code or local archive:
|
|
91
|
+
akash restore 8k9F2a
|
|
92
|
+
akash restore ~/my_backup.tar.gz
|
|
93
|
+
|
|
94
|
+
# Preview what will be extracted before touching disk:
|
|
95
|
+
akash restore 8k9F2a --dry-run
|
|
96
|
+
akash restore 8k9F2a --tree
|
|
97
|
+
```
|
|
98
|
+
* **Auto Secret Scrubbing**: Redacts tokens, passwords, and private keys from history files.
|
|
99
|
+
* **Bloat Pruning**: Skips `node_modules`, `__pycache__`, and `.venv`.
|
|
100
|
+
* **Package Manifests**: Inventories `apt`, `brew`, `pip`, `npm`, `cargo` for auto-reinstallation.
|
|
101
|
+
|
|
102
|
+
### 2. 🖥️ Remote Shells & Persistent Devices
|
|
103
|
+
Manage your fleet of servers and workstations:
|
|
104
|
+
```bash
|
|
105
|
+
# Run listener on your phone or remote server:
|
|
106
|
+
akash serve --daemon --label termux
|
|
107
|
+
|
|
108
|
+
# Open interactive shell from your laptop:
|
|
109
|
+
akash shell --device termux
|
|
110
|
+
|
|
111
|
+
# Run individual command remotely:
|
|
112
|
+
akash run "uptime" --device termux
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
### 3. ☁️ Cloud File Vault & Streaming
|
|
116
|
+
```bash
|
|
117
|
+
# Upload a file with 7-day auto-expiry:
|
|
118
|
+
akash cloud upload my_doc.pdf --expiry 7
|
|
119
|
+
|
|
120
|
+
# One-time burn-after-read:
|
|
121
|
+
akash cloud upload --burn secret_report.pdf
|
|
122
|
+
|
|
123
|
+
# Stream video directly into VLC without downloading:
|
|
124
|
+
akash cloud stream 7xY3a0 --vlc
|
|
125
|
+
|
|
126
|
+
# Pipe command output directly into the cloud vault:
|
|
127
|
+
mysqldump -u root db | akash pipe -n "db_backup.sql"
|
|
128
|
+
```
|
|
129
|
+
|
|
130
|
+
### 4. 🔐 P2P Encrypted File Transfers
|
|
131
|
+
Zero-knowledge file exchange using Curve25519 / X25519:
|
|
132
|
+
```bash
|
|
133
|
+
# View your public key and fingerprint:
|
|
134
|
+
akash id
|
|
135
|
+
|
|
136
|
+
# Send encrypted file to a contact:
|
|
137
|
+
akash send bob sensitive_dataset.zip -m "Q3 dataset"
|
|
138
|
+
|
|
139
|
+
# Recipient receives and decrypts:
|
|
140
|
+
akash inbox
|
|
141
|
+
akash inbox 7qR92x
|
|
142
|
+
```
|
|
143
|
+
|
|
144
|
+
### 5. 🔒 Hardware-Encrypted .env Store
|
|
145
|
+
```bash
|
|
146
|
+
# Set secrets into encrypted store:
|
|
147
|
+
akash env set prod DATABASE_URL="postgresql://user:pass@host/db"
|
|
148
|
+
|
|
149
|
+
# Retrieve secret for automation:
|
|
150
|
+
akash env get prod DATABASE_URL --raw
|
|
151
|
+
|
|
152
|
+
# Push encrypted secrets to cloud vault with burn-on-read:
|
|
153
|
+
akash env push prod --burn
|
|
154
|
+
|
|
155
|
+
# Pull secrets onto remote server:
|
|
156
|
+
akash env pull eX481p prod
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
### 6. 🤖 AI Agent Gateway (MCP) & Guard Console
|
|
160
|
+
Supercharge Cursor and Claude Desktop with local terminal execution, protected by real-time human approval:
|
|
161
|
+
```bash
|
|
162
|
+
# 1. Create agent profile with safe role preset:
|
|
163
|
+
akash agent create --name "Cursor" --role @coder
|
|
164
|
+
|
|
165
|
+
# 2. Generate configuration snippet for Cursor / Claude Desktop:
|
|
166
|
+
akash mcp share --claude --temp 30m
|
|
167
|
+
|
|
168
|
+
# 3. Start local tool execution worker with auto-undo checkpoints:
|
|
169
|
+
akash mcp serve
|
|
170
|
+
|
|
171
|
+
# 4. In a separate terminal, open live approval console:
|
|
172
|
+
akash guard
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
---
|
|
176
|
+
|
|
177
|
+
## 📚 In-Depth Documentation Guides
|
|
178
|
+
|
|
179
|
+
Explore comprehensive guides in the [`docs/`](docs/) directory:
|
|
180
|
+
|
|
181
|
+
| Document | Topic Covered |
|
|
182
|
+
| :--- | :--- |
|
|
183
|
+
| **[01. Quickstart & Installation](docs/01-quickstart-and-install.md)** | Setup on Linux, macOS, Windows, Android Termux / PRoot, and troubleshooting |
|
|
184
|
+
| **[02. Remote Terminal & Relays](docs/02-remote-terminal-and-relays.md)** | WebSocket relay, 1-click guest pairing, background daemons, remote execution |
|
|
185
|
+
| **[03. Environment Backups](docs/03-backup-and-disaster-recovery.md)** | Dotfile snapshots, secret scrubbing, visual tree explorer, package recovery |
|
|
186
|
+
| **[04. Cloud Vault & Streaming](docs/04-cloud-vault-and-streaming.md)** | Uploads, burn-after-read, direct VLC streaming, Unix pipe streaming |
|
|
187
|
+
| **[05. P2P Encrypted Transfers](docs/05-p2p-encrypted-transfers.md)** | X25519 ECDH asymmetric encryption, zero-knowledge storage, inbox management |
|
|
188
|
+
| **[06. Secrets & .env Vault](docs/06-env-and-secrets-vault.md)** | Local encrypted store, .env file import/export, cloud push/pull sync |
|
|
189
|
+
| **[07. AI Agents & MCP](docs/07-ai-agents-and-mcp.md)** | Model Context Protocol, Claude/Cursor integration, terminal guard approvals |
|
|
190
|
+
| **[08. Security & Integrity Audit](docs/08-security-integrity-audit.md)** | Hardware machine keys, SHA-256 HMAC code integrity sealing, audit logs |
|
|
191
|
+
| **[09. Full Command Reference](docs/09-full-command-reference.md)** | Exhaustive command cheat-sheet with every argument, flag, and option |
|
|
192
|
+
|
|
193
|
+
---
|
|
194
|
+
|
|
195
|
+
## 📊 Command Matrix
|
|
196
|
+
|
|
197
|
+
```text
|
|
198
|
+
akash
|
|
199
|
+
├── login Connect API key with hardware binding
|
|
200
|
+
├── whoami Account quota & device fingerprint
|
|
201
|
+
├── backup Save terminal environment to cloud or local archive
|
|
202
|
+
├── restore Restore environment (with --tree, --explore, --dry-run)
|
|
203
|
+
├── saves List cloud-saved terminal snapshots
|
|
204
|
+
├── shell Open interactive PTY (local, remote device, or guest code)
|
|
205
|
+
├── run Execute command remotely or save output to vault
|
|
206
|
+
├── serve Make device reachable (--daemon, --share for guest mode)
|
|
207
|
+
├── devices List, authorize, or revoke enrolled machines
|
|
208
|
+
├── cloud
|
|
209
|
+
│ ├── upload Upload file or secret text snippet
|
|
210
|
+
│ ├── files List vault files
|
|
211
|
+
│ ├── stream Direct streaming link or launch in VLC
|
|
212
|
+
│ ├── bulk Recursively upload directory
|
|
213
|
+
│ └── delete Purge file permanently
|
|
214
|
+
├── pipe Upload stdin or command output directly to cloud
|
|
215
|
+
├── send End-to-end encrypted P2P transfer to user public key
|
|
216
|
+
├── inbox Receive and decrypt incoming P2P files
|
|
217
|
+
├── id View or export P2P identity key and manage contacts
|
|
218
|
+
├── env
|
|
219
|
+
│ ├── list List env stores or keys
|
|
220
|
+
│ ├── set Add or update key-value secret
|
|
221
|
+
│ ├── get Retrieve secret (--raw for scripting)
|
|
222
|
+
│ ├── import Import .env file into encrypted store
|
|
223
|
+
│ ├── export Export encrypted store to .env
|
|
224
|
+
│ ├── push Push encrypted store to cloud vault
|
|
225
|
+
│ └── pull Pull and restore env store on new machine
|
|
226
|
+
├── agent
|
|
227
|
+
│ ├── create Generate agent profile (Client ID + Secret + Scopes)
|
|
228
|
+
│ ├── list List agent profiles
|
|
229
|
+
│ └── revoke Revoke agent access
|
|
230
|
+
├── mcp
|
|
231
|
+
│ ├── serve High-reliability MCP worker with undo checkpoints
|
|
232
|
+
│ ├── share Generate configuration snippet for Claude & Cursor
|
|
233
|
+
│ ├── guard Interactive terminal approval console
|
|
234
|
+
│ └── status One-glance MCP gateway status
|
|
235
|
+
├── check Verify package source integrity (--seal to update)
|
|
236
|
+
└── log Operational audit log (--stats for graphic summary)
|
|
237
|
+
```
|
|
238
|
+
|
|
239
|
+
---
|
|
240
|
+
|
|
241
|
+
## 🛡️ Security & Privacy Architecture
|
|
242
|
+
|
|
243
|
+
Akash CLI enforces security at every layer:
|
|
244
|
+
1. **Zero-Knowledge P2P Transfers**: Files are encrypted with X25519 and AES-256-GCM before leaving your device.
|
|
245
|
+
2. **Machine-Bound Secrets**: Local tokens, `.env` stores, and keys are tied to a unique `~/.akash/machine.key` that cannot be copied to other systems.
|
|
246
|
+
3. **Automated Secret Sanitization**: Sensitive variables, connection strings, and tokens in shell history files are scrubbed prior to archiving.
|
|
247
|
+
4. **Source Tamper Detection**: `akash check` computes cryptographic HMAC digests over package files to block malicious code modifications.
|
|
248
|
+
|
|
249
|
+
---
|
|
250
|
+
|
|
251
|
+
## 📄 License
|
|
252
|
+
|
|
253
|
+
Distributed under the MIT License. See [LICENSE](LICENSE) for details.
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
try:
|
|
2
|
+
from importlib.metadata import version
|
|
3
|
+
__version__ = version("akashcli")
|
|
4
|
+
except Exception:
|
|
5
|
+
__version__ = "4.7.0"
|
|
6
|
+
|
|
7
|
+
AKASH_VERSION = __version__
|
|
8
|
+
|
|
9
|
+
from .client import AkashClient
|
|
10
|
+
from .auth import AuthManager
|
|
11
|
+
from .models import UserInfo, UploadResult, FileInfo
|
|
12
|
+
from .exceptions import AkashError, AuthenticationError, QuotaExceeded, UploadFailed
|
|
13
|
+
|
|
14
|
+
__all__ = [
|
|
15
|
+
"AkashClient",
|
|
16
|
+
"AuthManager",
|
|
17
|
+
"UserInfo",
|
|
18
|
+
"UploadResult",
|
|
19
|
+
"FileInfo",
|
|
20
|
+
"AkashError",
|
|
21
|
+
"AuthenticationError",
|
|
22
|
+
"QuotaExceeded",
|
|
23
|
+
"UploadFailed",
|
|
24
|
+
"__version__",
|
|
25
|
+
"AKASH_VERSION",
|
|
26
|
+
]
|