Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What is the rationale for the generateAuthorKeypair shortname only allowing lengths of 4 chars? #322

Open
gobengo opened this issue Jun 20, 2023 · 1 comment

Comments

@gobengo
Copy link

gobengo commented Jun 20, 2023

If I try this, it returns a ValidationError

  const newAuthor = await Earthstar.Crypto.generateAuthorKeypair('abcde')

Are you open to allowing differently lengthed shortnames?

@sgwilym
Copy link
Contributor

sgwilym commented Jun 20, 2023

Hi @gobengo!

The idea behind the four character limit is that they are just long enough to form a descriptive label, and short enough that they obviously can't be unique. They're not really for identity, but more like a label hanging off the keychain to remind you what it's for (which makes me think they should be renamed to labels / fobs).

Display names are data you'd store inside of an Earthstar share and associate with your keypair, e.g. with the about format. This means your display name can a much broader scope for expression (non-ASCII characters, spaces, extra long, emoji, can change at any time), and you can have different identities in different shares.

Then again, to argue with myself, share addresses don't have this limitation though logically the same argument could be applied. How persuasive is the above?

Here's a short FAQ on shortnames in the spec which may give more context.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants