4 stable releases
new 1.0.3 | Dec 24, 2024 |
---|
#485 in Command line utilities
244 downloads per month
Used in bestool
44KB
705 lines
Algae: simplified encryption commands.
You can install the CLI tool with:
$ cargo install algae-cli
Introduction
Algae is a simplified profile of the excellent age format.
It implements five functions for the most common operations, and tries to be as obvious and hard-to-misuse as possible, without being prohibitively hard to use, and while retaining forward-compatibility with age (all algae products can be used with age, but not all age products may be used with algae).
To start with, generate a keypair with algae keygen
. This will generate two files:
identity.txt.age
, a passphrase-protected keypair, and identity.pub
, the public key in plain.
To encrypt a file, use algae encrypt -k identity.pub filename
. As this uses the public key, it
doesn't require a passphrase. The encrypted file is written to filename.age
. To decrypt it,
use algae decrypt -k identity.txt.age filename.age
. As this uses the secret key, it will
prompt for its passphrase. The decoded file is written back to filename
(i.e. without the
.age
suffix).
To obtain a plaintext identity.txt
(i.e. to remove the passphrase), use
algae reveal identity.txt.age
. To add a new passphrase on a plaintext identity, use
algae protect identity.txt
. These commands are not special to identity files: you can
protect
(encrypt) and reveal
(decrypt) arbitrary files with a passphrase.
Library interface
Algae has a library interface (a Rust crate). It is peculiar in that it deliberately exposes the CLI support structures alongside more traditional library routines, for the purpose of embedding part or parcel of the Algae command set or conventions into other tools.
Documentation: https://docs.rs/algae-cli
Name
age is pronounced ah-gay. While age doesn't have an inherent meaning, the Italian-adjacent Friulian language (spoken around Venice) word aghe, pronounced the same, means water.
Algae (pronounced al-gay or al-ghee) is a lightweight (a)ge. Algae are also fond of water.
(Google Translate invents an Italian translation for aghe
but in fact
that's not a word.
The actual plural of ago ("needle") is aghi.
The perils of AI…)
License
The tool and library are licensed GPL-3.0 or later.
Dependencies
~24–37MB
~533K SLoC