Add READMEs for AUR CLI and API packages
- aur-cli: Lightweight CLI-only usage documentation - aur-api: REST API with HTTPS/TLS configuration docs - aur: Updated to reflect Python 3.11-3.14 support Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
102
aur-api/README.md
Normal file
102
aur-api/README.md
Normal file
@@ -0,0 +1,102 @@
|
|||||||
|
# Stegasoo API AUR Package
|
||||||
|
|
||||||
|
REST API server package for programmatic steganography operations. Includes HTTPS support and API key authentication.
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
### From AUR (once published)
|
||||||
|
```bash
|
||||||
|
yay -S stegasoo-api-git
|
||||||
|
# or
|
||||||
|
paru -S stegasoo-api-git
|
||||||
|
```
|
||||||
|
|
||||||
|
### Manual build
|
||||||
|
```bash
|
||||||
|
git clone https://aur.archlinux.org/stegasoo-api-git.git
|
||||||
|
cd stegasoo-api-git
|
||||||
|
makepkg -si
|
||||||
|
```
|
||||||
|
|
||||||
|
## What Gets Installed
|
||||||
|
|
||||||
|
- `/opt/stegasoo-api/venv/` - Self-contained Python venv with API dependencies
|
||||||
|
- `/opt/stegasoo-api/config/` - API key storage
|
||||||
|
- `/opt/stegasoo-api/certs/` - TLS certificates
|
||||||
|
- `/usr/bin/stegasoo` - CLI executable
|
||||||
|
- `/usr/lib/systemd/system/stegasoo-api.service` - Systemd service
|
||||||
|
|
||||||
|
## Quick Start
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# 1. Create an API key
|
||||||
|
sudo -u stegasoo stegasoo api keys create mykey
|
||||||
|
|
||||||
|
# 2. Start the service
|
||||||
|
sudo systemctl enable --now stegasoo-api
|
||||||
|
|
||||||
|
# 3. Test the API
|
||||||
|
curl -k -H "X-API-Key: YOUR_KEY" https://localhost:8000/
|
||||||
|
```
|
||||||
|
|
||||||
|
## Service Details
|
||||||
|
|
||||||
|
| Setting | Value |
|
||||||
|
|---------|-------|
|
||||||
|
| Port | 8000 |
|
||||||
|
| Protocol | HTTPS (self-signed cert auto-generated) |
|
||||||
|
| API Docs | https://localhost:8000/docs |
|
||||||
|
| OpenAPI | https://localhost:8000/openapi.json |
|
||||||
|
|
||||||
|
## API Key Management
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# List all keys
|
||||||
|
stegasoo api keys list
|
||||||
|
|
||||||
|
# Create a new key
|
||||||
|
sudo -u stegasoo stegasoo api keys create <name>
|
||||||
|
|
||||||
|
# Revoke a key
|
||||||
|
sudo -u stegasoo stegasoo api keys revoke <name>
|
||||||
|
```
|
||||||
|
|
||||||
|
## TLS Configuration
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# View current certificate info
|
||||||
|
stegasoo api tls info
|
||||||
|
|
||||||
|
# Generate new self-signed certificate
|
||||||
|
sudo -u stegasoo stegasoo api tls generate
|
||||||
|
|
||||||
|
# Use custom certificates (edit service)
|
||||||
|
sudo systemctl edit stegasoo-api
|
||||||
|
# Add:
|
||||||
|
# [Service]
|
||||||
|
# ExecStart=
|
||||||
|
# ExecStart=/opt/stegasoo-api/venv/bin/stegasoo api serve \
|
||||||
|
# --host 0.0.0.0 --port 8000 \
|
||||||
|
# --cert /path/to/cert.pem --key /path/to/key.pem
|
||||||
|
```
|
||||||
|
|
||||||
|
## Manual Run (without systemd)
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# Development mode (auto-reload)
|
||||||
|
/opt/stegasoo-api/venv/bin/stegasoo api serve --reload
|
||||||
|
|
||||||
|
# Production mode
|
||||||
|
/opt/stegasoo-api/venv/bin/stegasoo api serve --host 0.0.0.0 --port 8000
|
||||||
|
```
|
||||||
|
|
||||||
|
## For Web UI
|
||||||
|
|
||||||
|
Install the full package instead:
|
||||||
|
```bash
|
||||||
|
yay -S stegasoo-git
|
||||||
|
```
|
||||||
|
|
||||||
|
## Maintainer
|
||||||
|
|
||||||
|
Aaron D. Lee
|
||||||
62
aur-cli/README.md
Normal file
62
aur-cli/README.md
Normal file
@@ -0,0 +1,62 @@
|
|||||||
|
# Stegasoo CLI AUR Package
|
||||||
|
|
||||||
|
Lightweight CLI-only package for steganography operations. No web UI or API server.
|
||||||
|
|
||||||
|
## Installation
|
||||||
|
|
||||||
|
### From AUR (once published)
|
||||||
|
```bash
|
||||||
|
yay -S stegasoo-cli-git
|
||||||
|
# or
|
||||||
|
paru -S stegasoo-cli-git
|
||||||
|
```
|
||||||
|
|
||||||
|
### Manual build
|
||||||
|
```bash
|
||||||
|
git clone https://aur.archlinux.org/stegasoo-cli-git.git
|
||||||
|
cd stegasoo-cli-git
|
||||||
|
makepkg -si
|
||||||
|
```
|
||||||
|
|
||||||
|
## What Gets Installed
|
||||||
|
|
||||||
|
- `/opt/stegasoo-cli/venv/` - Self-contained Python venv with CLI dependencies only
|
||||||
|
- `/usr/bin/stegasoo` - CLI executable
|
||||||
|
|
||||||
|
## Usage
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# Show all commands
|
||||||
|
stegasoo --help
|
||||||
|
|
||||||
|
# Generate credentials (passphrase + PIN)
|
||||||
|
stegasoo generate
|
||||||
|
stegasoo generate --words 5 --pin-length 8
|
||||||
|
|
||||||
|
# Generate with RSA keys and QR codes
|
||||||
|
stegasoo generate --rsa --qr-ascii
|
||||||
|
|
||||||
|
# Encode a message
|
||||||
|
stegasoo encode -i carrier.jpg -r reference.jpg -m "secret message" \
|
||||||
|
-P "word1 word2 word3 word4" -p 123456
|
||||||
|
|
||||||
|
# Decode a message
|
||||||
|
stegasoo decode -i encoded.png -r reference.jpg \
|
||||||
|
-P "word1 word2 word3 word4" -p 123456
|
||||||
|
|
||||||
|
# Image tools
|
||||||
|
stegasoo tools --help
|
||||||
|
stegasoo tools compress image.png
|
||||||
|
stegasoo tools rotate image.jpg 90
|
||||||
|
```
|
||||||
|
|
||||||
|
## For Web UI or REST API
|
||||||
|
|
||||||
|
Install the full package instead:
|
||||||
|
```bash
|
||||||
|
yay -S stegasoo-git
|
||||||
|
```
|
||||||
|
|
||||||
|
## Maintainer
|
||||||
|
|
||||||
|
Aaron D. Lee
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
# Stegasoo AUR Package
|
# Stegasoo AUR Package
|
||||||
|
|
||||||
> **Note:** Uses Python 3.12 via `python312` AUR package (jpegio not yet compatible with 3.13)
|
Full package with CLI, Web UI, and REST API. Supports Python 3.11-3.14.
|
||||||
|
|
||||||
## Installation
|
## Installation
|
||||||
|
|
||||||
@@ -20,15 +20,15 @@ makepkg -si
|
|||||||
|
|
||||||
## What Gets Installed
|
## What Gets Installed
|
||||||
|
|
||||||
- `/opt/stegasoo/venv/` - Self-contained Python 3.12 venv with all dependencies
|
- `/opt/stegasoo/venv/` - Self-contained Python venv with all dependencies
|
||||||
- `/usr/bin/stegasoo` - CLI symlink
|
- `/usr/bin/stegasoo` - CLI symlink
|
||||||
- `/usr/lib/systemd/system/stegasoo-web.service` - Web UI service
|
- `/usr/lib/systemd/system/stegasoo-web.service` - Web UI service (port 5000)
|
||||||
- `/usr/lib/systemd/system/stegasoo-api.service` - REST API service
|
- `/usr/lib/systemd/system/stegasoo-api.service` - REST API service (port 8000, HTTPS)
|
||||||
|
|
||||||
## Optional Dependencies
|
## Optional Dependencies
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# QR code reading from webcam/images
|
# QR code reading from webcam/images (recommended)
|
||||||
sudo pacman -S zbar
|
sudo pacman -S zbar
|
||||||
```
|
```
|
||||||
|
|
||||||
@@ -39,41 +39,52 @@ All other dependencies are bundled in the venv.
|
|||||||
### CLI
|
### CLI
|
||||||
```bash
|
```bash
|
||||||
stegasoo --help
|
stegasoo --help
|
||||||
stegasoo generate --rsa --qr-ascii
|
stegasoo generate # Generate passphrase + PIN
|
||||||
stegasoo encode -i carrier.jpg -r reference.jpg -m "secret" -P passphrase -p 123456
|
stegasoo generate --rsa --qr-ascii # With RSA keys and QR codes
|
||||||
|
stegasoo encode -i carrier.jpg -r reference.jpg -m "secret" -P "word1 word2 word3 word4" -p 123456
|
||||||
|
stegasoo decode -i encoded.png -r reference.jpg -P "word1 word2 word3 word4" -p 123456
|
||||||
```
|
```
|
||||||
|
|
||||||
### Web UI (systemd)
|
### Web UI
|
||||||
```bash
|
```bash
|
||||||
# Create service user (first time)
|
# Start service (user created automatically on install)
|
||||||
sudo useradd -r -s /usr/bin/nologin stegasoo
|
|
||||||
|
|
||||||
# Start service
|
|
||||||
sudo systemctl enable --now stegasoo-web
|
sudo systemctl enable --now stegasoo-web
|
||||||
|
|
||||||
# Access at http://localhost:5000
|
# Access at http://localhost:5000
|
||||||
```
|
```
|
||||||
|
|
||||||
### REST API (systemd)
|
### REST API
|
||||||
```bash
|
```bash
|
||||||
# Start service
|
# Create an API key first
|
||||||
|
sudo -u stegasoo stegasoo api keys create mykey
|
||||||
|
|
||||||
|
# Start service (HTTPS with auto-generated self-signed cert)
|
||||||
sudo systemctl enable --now stegasoo-api
|
sudo systemctl enable --now stegasoo-api
|
||||||
|
|
||||||
# Access at http://localhost:8000/docs
|
# Access docs at https://localhost:8000/docs
|
||||||
|
curl -k -H "X-API-Key: YOUR_KEY" https://localhost:8000/
|
||||||
```
|
```
|
||||||
|
|
||||||
### Manual run (without systemd)
|
### HTTPS Configuration
|
||||||
|
|
||||||
|
The API uses HTTPS by default with auto-generated self-signed certificates.
|
||||||
|
|
||||||
```bash
|
```bash
|
||||||
# Web UI
|
# View certificate info
|
||||||
/opt/stegasoo/venv/bin/python -m gunicorn -b 0.0.0.0:5000 \
|
stegasoo api tls info
|
||||||
--chdir /opt/stegasoo/venv/lib/python3.12/site-packages/frontends/web app:app
|
|
||||||
|
|
||||||
# REST API
|
# Generate new self-signed cert
|
||||||
/opt/stegasoo/venv/bin/uvicorn \
|
sudo -u stegasoo stegasoo api tls generate
|
||||||
--app-dir /opt/stegasoo/venv/lib/python3.12/site-packages/frontends/api \
|
|
||||||
main:app --host 0.0.0.0 --port 8000
|
# Use custom certs (edit service file)
|
||||||
|
sudo systemctl edit stegasoo-api
|
||||||
```
|
```
|
||||||
|
|
||||||
|
## Alternative Packages
|
||||||
|
|
||||||
|
- `stegasoo-cli-git` - CLI only, minimal dependencies
|
||||||
|
- `stegasoo-api-git` - CLI + REST API, no web UI
|
||||||
|
|
||||||
## Maintainer
|
## Maintainer
|
||||||
|
|
||||||
Aaron D. Lee
|
Aaron D. Lee
|
||||||
|
|||||||
Reference in New Issue
Block a user