Skip to main content
Pre-release

This release is a pre-release and may not be stable for production use.

remailers

A toolkit for anonymous messaging with PGP over Usenet and Tor email: hashed/encrypted subjects (hSub/eSub), nym-server (ZAX) registration, and SOCKS/Tor SMTP. Built on top of usenet.

For research and privacy education. The public nym/remailer network is largely historical. Treat the bundled server definitions as starting points.

Install

pip install remailers

Quickstart

Generate (or load) a PGP identity:

from remailers import Credentials

creds = Credentials("my_key.asc", name="PythonicAnon")
print(creds.pubkey)

Hashed and encrypted subjects: let a recipient spot a message meant for them without revealing the subject:

from remailers import create_hsub, match_hsub, create_esub, match_esub

hsub = create_hsub("evil dolphin captain")
assert match_hsub(hsub, "evil dolphin captain")

esub = create_esub("evil dolphin captain", key="shared-secret")
assert match_esub("evil dolphin captain", "shared-secret", esub)

Post and retrieve anonymous messages via alt.anonymous.messages:

from usenet import UsenetServer
from remailers import Credentials, AnonBox, create_hsub

creds = Credentials("my_key.asc")
hsub = create_hsub("evil dolphin captain")
ciphertext = creds.encrypt("meet at noon")

with UsenetServer("news.neodome.net") as server:
    server.post(ciphertext, hsub, "alt.anonymous.messages")

inbox = AnonBox(creds, UsenetServer("news.neodome.net"))
for article in inbox.retrieve_by_subject("evil dolphin captain"):
    print(article.text)

ZAX nym servers and Tor email are in remailers.zax and remailers.mail. See examples/.

Security notes

  • Initialization vectors come from os.urandom (remailers.utils.generate_iv).
  • hSub uses SHA-256. eSub uses Blowfish for Type-I compatibility: it exists for interop with the legacy remailer ecosystem, not as modern AEAD.
  • Message bodies are protected by PGP (RSA-4096, AES-256), not by the subject scheme.

Testing

pip install -e .[test]
pytest test/

Tests are offline: subject round-trips, IV entropy, and a PGP encrypt/decrypt cycle with a freshly generated key.

License

Apache-2.0

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

remailers-0.1.0a2.tar.gz (17.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

remailers-0.1.0a2-py3-none-any.whl (15.5 kB view details)

Uploaded Python 3

File details

Details for the file remailers-0.1.0a2.tar.gz.

File metadata

  • Download URL: remailers-0.1.0a2.tar.gz
  • Upload date:
  • Size: 17.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for remailers-0.1.0a2.tar.gz
Algorithm Hash digest
SHA256 cbf65b0967567a4d22d84d1d8e398a02e4565607e69c13f2621f08bf07f19d84
MD5 78c38c7affb606841df276b3015f65f4
BLAKE2b-256 4ef7168a1fd27037e21d680db3cad8598896dc0a8ec7c8e6ddbac6a0872dc43e

See more details on using hashes here.

File details

Details for the file remailers-0.1.0a2-py3-none-any.whl.

File metadata

  • Download URL: remailers-0.1.0a2-py3-none-any.whl
  • Upload date:
  • Size: 15.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for remailers-0.1.0a2-py3-none-any.whl
Algorithm Hash digest
SHA256 15895e1e30bb85d0202b0eab3a83b8ca6c68104cbe64b2d3deef0912dc66496d
MD5 f0e7d9bb4444a175a3d34833e1b582b5
BLAKE2b-256 d66062ea7d2f1721733a0d4639dd40bd6cd2564233ae419cc4a91e02ee35bdb0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page