keyfunc: deterministic keys, age encryption and child mnemonics from one mnemonic (spec) #1
Reference in New Issue
Block a user
Delete Branch "clawbot/hacks:bip85ssh"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Spec only, for review. Nothing else is on the branch; implementation starts after the spec is approved.
keyfunc/README.mdspecifies a command-line tool that derives keys from a BIP-39 mnemonic, so the same mnemonic, kind and index always give the same key and nothing is ever stored. It usesgit.eeqj.de/sneak/secret/pkg/bip85and follows the steps of that repository'sagehdpackage. No vendor id in the path; application numbers are spelled the way BIP-85 spells RSA: SSH838372, age657169; child mnemonics use BIP-85's own mnemonic application39.Commands:
keyfunc ssh pub|priv|install|tofor ed25519 keys (installappends the public line on a host if absent,toruns the systemsshwith the key served from an in-process agent, never on disk);keyfunc age pub|priv|encrypt|decryptfor age identities and for encrypting to and decrypting with them, the derived identity always among the recipients;keyfunc mnemonicfor a child mnemonic of 12, 18 or 24 words.The mnemonic is never a command-line argument: a shell command given by flag or environment, the mnemonic in the environment, or a no-echo prompt.
Model: fable-5-1
Decisions the task left open; the reading I am taking for each, unless told otherwise:
privoutput comment: the OpenSSH private key carries a comment field; I write the same comment aspub(bip85ssh/<n>, or--comment).sshcommand: the in-process agent holds only the derived key, andIdentityAgentreplaces the user's own agent for that run, so the user's other keys are not offered.-o IdentityAgent=...is placed before the user's arguments, so a later-o IdentityAgentfrom the user wins.install: the remote side is a shortshscript run overssh; the key line is fed to it on standard input rather than placed in the remote command line, so it does not appear in the remote process list.agehd; no flag for it.Model: fable-5-1
bip85ssh: deterministic SSH keys from BIP-85 entropyto bip85keys: deterministic key pairs from BIP-85 entropy, SSH first (spec)Amended per sneak: mnemonic only, no xprv. The mnemonic now comes from, in order,
--mnemonic-command(a shell command whose output is the mnemonic, for examplesecret get foo),BIP85KEYS_MNEMONIC_COMMAND,BIP85KEYS_MNEMONIC, or a no-echo prompt. One reading: the file flag is gone, since--mnemonic-command 'cat path'covers it; say the word and it comes back. Still spec only, waiting for approval.Model: fable-5-1
Amended per sneak: no vendor id in the path, since this is meant as a standard others can adopt. Path is
m/83696968'/<app>'/<n>', with application numbers spelled the way BIP-85 spells RSA (828365 = R S A): SSH838372, age657169.ssh sshis nowssh to. Test vectors recomputed for the new path with thesecretpackage.secretderives age keys at a vendor-specific path today; matching this standard is a change there. The tool's name is still open; ten proposals are with sneak.Model: fable-5-1
bip85keys: deterministic key pairs from BIP-85 entropy, SSH first (spec)to keyfunc: deterministic key pairs from a mnemonic, SSH first (spec)keyfunc: deterministic key pairs from a mnemonic, SSH first (spec)to keyfunc: deterministic keys, age encryption and child mnemonics from one mnemonic (spec)Closing: sneak approved the specification and moved the tool to its own repository, https://git.eeqj.de/sneak/keyfunc, where the README on main is this spec and the 0.1.0 work runs on next (https://git.eeqj.de/sneak/keyfunc/milestone/28).
Model: fable-5-1
Pull request closed