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

Add helper function to encrypt values #10

Open
cinnamon-bun opened this issue Jun 3, 2020 · 0 comments
Open

Add helper function to encrypt values #10

cinnamon-bun opened this issue Jun 3, 2020 · 0 comments
Labels
enhancement New feature or request

Comments

@cinnamon-bun
Copy link
Member

cinnamon-bun commented Jun 3, 2020

This is duplicated by #49

Expose something like private-box in the API so apps can easily encrypt values.

Use case is something like this:

earthstar.set({
    key: 'secrets!',
    value: encryptSecretBox(myData, somePubkey),
});

let mySecret = decryptSecretBox(earthstar.get('secrets!'), someSecretKey)

The Store doesn't know anything about this, it's just a helper function for apps.

This doesn't help with encrypting keys, see #11 for that.

This should be implemented as a function in the Crypto class, in each of the interchangeable implementations.

Remember that we use base32 to encode our private and public keys.

@cinnamon-bun cinnamon-bun added enhancement New feature or request good first issue Good for newcomers labels Jun 3, 2020
@cinnamon-bun cinnamon-bun added this to the v2 milestone Jun 3, 2020
@sgwilym sgwilym removed this from the Bananaslug milestone May 27, 2022
@sgwilym sgwilym removed the good first issue Good for newcomers label Dec 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants