2025-12-11 15:25:24 -07:00
2025-12-11 14:53:01 -07:00
2025-12-11 15:25:24 -07:00
2025-12-11 15:00:59 -07:00
2025-12-11 14:53:01 -07:00
2025-12-11 14:53:01 -07:00
2025-12-11 15:12:21 -07:00
2025-12-11 15:12:21 -07:00

himbocrypt

A robust end-to-end encryption engine and CLI.

What is this?

An encryption tool for secure message exchange. Uses X25519 key exchange, XChaCha20-Poly1305 for authenticated encryption, and HKDF for key derivation.

How it works

  1. Keys: You get a "Public Key" (share with the other party) and a "Private Key" (keep secret).
  2. Sending: The tool combines your private key with the recipient's public key to derive a shared secret and encrypt the message.
  3. Receiving: The recipient uses their private key and your public key to derive the same secret and decrypt.
  4. Forward Secrecy: Every message generates an ephemeral keypair that's discarded after use. If your long-term key is compromised later, past messages remain secure.

Usage

Build

go build -o himbocrypt cmd/himbocrypt/main.go

Make Keys

Both parties need to generate their own keypair.

./himbocrypt keygen

Save the output!

Send a Message

./himbocrypt encrypt \
  -sender-priv <YOUR_PRIVATE_KEY> \
  -recipient-pub <RECIPIENT_PUBLIC_KEY> \
  -msg "Hello there"

Read a Message

./himbocrypt decrypt \
  -recipient-priv <YOUR_PRIVATE_KEY> \
  -sender-pub <SENDER_PUBLIC_KEY> \
  -ciphertext <THE_CIPHERTEXT>

For Developers

Use this in your own Go apps:

import "himbocrypt/pkg/engine"

e := engine.NewEngine()

Testing

Run the full test suite:

go test ./pkg/engine/... -v

Run benchmarks:

go test ./pkg/engine/... -bench=. -benchmem
Description
A robust end-to-end encryption engine and CLI.
Readme 1.7 MiB
Languages
Go 97.1%
Nix 2.3%
Makefile 0.6%