A2ID-KEYGEN(1)

πŸ“¦ version 2.6.4, in nixos 26.05, nixpkgs unstable

πŸ’… A2ID-KEYGEN β€” a2id-keygen

okay so real talk, this one's from the System Management Commands corner of the manual, and it's your girl's fave kind of page: short, sassy, and it makes keys. buckle up bestie πŸŽ€

✨ NAME ✨

a2id-keygen β€” generate a key for ARPA2 Signed Identities πŸ—οΈ

🌸 SYNOPSIS 🌸

a2id-keygen keyname

a2id-keygen /path/to/file.key

πŸ’– DESCRIPTION πŸ’–

so like, with a2id-keygen, an administrator can install a key for use in the a2id_sign() and a2id_verify() functions. those two literally work on an ARPA2 Identity β€” a2id_sign() adds a signature, a2id_verify() checks one. no cap. πŸ”₯

and the signature content? it shows up as part of the identity itself, like:

john+cook+AABBCC+@example.com

the way that works is the contents of this signature fixate the validity of the ARPA2 Identity to contextual matter β€” things like the time (which is how you get expiration, periodt) or the remote identity (fixating their domain and/or local-part). it's giving "this identity is valid in this exact context" and honestly? iconic.


πŸ¦‹ making a new key πŸ¦‹

this command lets the system administrator create a new key. two vibes, one command:

  • the /path/to/file.key form gives an absolute path name of a place to store the key β€” you pick, you slay
  • the keyname form stores the file into a default location, which usually is /var/lib/arpa2/identity, where keys are stored with a .key extension
⚠️ not me warning you: overwriting an existing key file is not supported β€” it leads to an error message and a failure exit. no quiet clobbering, no sneaky replace, just a hard no. πŸ™ˆ

🧚 the key repository 🧚

the purpose of the /var/lib/arpa2/identity directory is to serve as a key repository for the system, with files only accessible to the root user. main character security energy πŸ‘‘

it is customary to have a key named default stored in /var/lib/arpa2/identity/default.key to serve most purposes. additional keys may be used, for instance, to permit verification of signatures with older keys, while default.key is used for signing. so to cycle keys:

  1. move the default key to another name with the .key extension
  2. generate a new default key to replace it

that's the whole ritual, bestie πŸ•―οΈ

πŸ’œ how apps actually get their keys πŸ’œ

applications must load keys explicitly, and the default key store is merely a convention to get that started. the function a2id_addkey() is used to setup a new key.

programs may open a file descriptor to the key(s) to pass and harvest them after dropping privileges. and an even stronger mechanism is to do this key passing through a pipe β€” into which it fits, and from which it can only be read once by the program at a lower privilege. the way that's literally the most secure vibe here. πŸ”βœ¨

🌈 AUTHOR 🌈

written by Rick van Rein of OpenFortress.nl, for the ARPA2.net project. king behavior πŸ‘‘

πŸ“ REPORTING BUGS πŸ“

for any discussion, including about bugs, please use the https://gitlab.com/arpa2/arpa2common/ project page for ARPA2 Common. we use its issue tracker to track bugs and feature requests. come yell with us, it's a safe space 🫢

Copyright Β© 2021 Rick van Rein, ARPA2.net.

ARPA2 is funded from InternetWide.org, which in turn receives funding from various sources. this particular work was funded through a grant of SIDNfonds, a public interest fund geared towards a better Internet for all, and paid by administration fees for .nl domain names. so yes, every .nl domain out there lowkey helped fund this πŸŽ€

πŸ‘‘ SEE ALSO πŸ‘‘

ARPA2 Common is documented on http://common.arpa2.net/ and its code is on https://gitlab.com/arpa2/arpa2common/ β€” go read, iykyk πŸ“š


that's the whole page, bestie, you ate it up πŸ’… this lil gem comes to you from ARPA2.net and it's dated June 2021 β€” vintage but still slay ✨

πŸ“¦ where this page comes from