EdDSA Private Key Bytes
Ed25519 private keys without the ECDSA baggage
- private_bytes
- private_key
Ed25519 is the modern, no-fuss signing algorithm: faster than ECDSA, smaller keys, and famously impossible to get subtly wrong the way you can with a hand-picked curve. EdDSAPrivateKeyFormat ("EdDSA Private Key Bytes") generates one of these keys and serializes it into PEM, DER, or raw bytes. If you're building a signature loop from scratch and don't have a legacy reason to use ECDSA, this is the key you want to start from.
What it does
It's the EdDSA cousin of ECPrivateKey - same shape, different algorithm family. The node calls Ed25519PrivateKey.generate() (or Ed448), then serializes. Two key type choices, a handful of format choices, and it hands you the key twice: once as bytes, once as an object.
The inputs that matter
key_type-Ed25519orEd448. Ed25519 is the one to reach for: 32-byte keys, fast, universally supported. Ed448 exists for parity and slightly bigger security margin, but for an ARG there's no practical reason to leave the default.encoding-PEM(text),DER(binary), orRaw(the bare 32-byte secret). Raw is the compact form you'd actually hide inside a puzzle; PEM is what you'd paste into a file.formatting-PKCS8(the standard),OpenSSH, orRaw. Two things to know:OpenSSHonly works with Ed25519 (Ed448 + OpenSSH will error), andRawpairs withRawencoding.encryption-Best Availableencrypts the key, but only ifencryption_passwordis actually filled in.Nonewrites it in the clear. Same silent-plaintext gotcha as the EC node: chooseBest Availableand forget the password, and you get an unencrypted key with no warning.
Outputs
private_bytes(BYTESLIKE) - the serialized key; save it, transport it, or feed it back intoEdDSASignature/EdDSAPublicKeyFormatvia theirFrom Private Bytesmode.private_key(KEYOBJ) - the parsed key object for wiring into the pack's other EdDSA nodes directly.
Note there's no way to supply your own seed here - unlike ECPrivateKey's private_value, this node only generates fresh keys. If you need a deterministic key from fixed bytes, you'd use From Private Bytes on the signature or public key nodes with bytes you derived elsewhere. For reproducibility, save private_bytes and reuse them.
Installing it
Part of the ComfyUI ARG Toolkit, one install for everything:
cd ComfyUI/custom_nodes
git clone https://github.com/AzelusLightvale/ComfyUI-ARG-Toolkit
Restart, or use ComfyUI Manager's "ComfyUI ARG Toolkit" entry - it pulls cryptography (the actual EdDSA implementation) plus the rest of the pack's dependencies.
Where people get burned
- OpenSSH format on Ed448. The dropdown lets you try it; the code rejects it. Stick to Ed25519 if you need OpenSSH output.
- Random key per run. A fresh key each execution means non-reproducible workflows. Save
private_bytesand load them back in on the signature node. - Type confusion. The
KEYOBJ/BYTESLIKEsplit trips up everyone new to the pack. The object goes to object inputs (From Loaded Key), the bytes go to bytes inputs (From Private Bytes).
This is the "just works" choice for the modern half of the ARG Toolkit. Generate the key, hand private_key to EdDSASignature, derive the public half with EdDSAPublicKeyFormat, and you've got a clean Ed25519 signing identity with zero curve-selection anxiety.
Inputs (5)
| Name | Type | Default | Description |
|---|---|---|---|
| key_type | COMBO | Ed25519 | 2 options: Ed25519, Ed448 |
| encoding | COMBO | PEM | 3 options: PEM, DER, Raw |
| formatting | COMBO | PKCS8 | 3 options: PKCS8, OpenSSH, Raw |
| encryption | COMBO | Best Available | 2 options: Best Available, None |
| encryption_passwordopt | STRING | The password to use to encrypt the private key. Required if encryption is used. |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| private_bytes | BYTESLIKE | — |
| private_key | KEYOBJ | — |