ed25519-blake2b-fork

raw JSON →
1.4.2 verified Fri May 01 auth: no python

A fork of the ed25519 library that uses BLAKE2b instead of SHA-512 hashing for public-key signatures. Version 1.4.2 adds automatic wheel builds via cibuildwheel. The library provides Ed25519 signing and verification with a pure Python implementation. Release cadence is irregular.

pip install ed25519-blake2b-fork
error ImportError: No module named 'ed25519_blake2b'
cause The package is installed as ed25519-blake2b-fork but the import uses underscores.
fix
Ensure you installed the package: pip install ed25519-blake2b-fork Then import: from ed25519_blake2b import SigningKey
error AttributeError: module 'ed25519_blake2b' has no attribute 'SigningKey'
cause Possibly an older version or incorrect import path.
fix
Use from ed25519_blake2b import SigningKey. If still fails, reinstall package: pip install --upgrade ed25519-blake2b-fork
error ed25519_blake2b.BadSignatureError: Invalid signature
cause Signature was created with a different key or algorithm (e.g., SHA-512 ed25519).
fix
Ensure you are using the same key and that the message hashing uses BLAKE2b. This fork is not compatible with standard Ed25519.
gotcha This library is a fork that uses BLAKE2b instead of SHA-512. Do not use it interchangeably with the standard ed25519 library; signatures are incompatible.
fix Ensure you use this library only where BLAKE2b-based Ed25519 is expected.
deprecated The package name 'ed25519-blake2b-fork' may be renamed or superseded. Check for newer versions or official replacements.
fix Monitor the repository for updates or consider using the original ed25519 library with SHA-512 if compatibility is needed.
gotcha The private key seed generation uses system random. For deterministic keys, you must provide your own seed.
fix Pass a 32-byte seed to SigningKey(seed=your_seed) for reproducible keys.

Generate a key pair, sign a message, and verify the signature.

from ed25519_blake2b import SigningKey, VerifyingKey

sk = SigningKey()
vk = sk.get_verifying_key()
message = b"Hello, world!"
signature = sk.sign(message)
print("Signature:", signature.hex())
assert vk.verify(signature, message)
print("Verification passed!")