Skip to content
This repository was archived by the owner on Oct 7, 2024. It is now read-only.

Replace withAppKeyOrigin option with getAppKey#19

Draft
Gudahtt wants to merge 1 commit intomainfrom
get-app-key
Draft

Replace withAppKeyOrigin option with getAppKey#19
Gudahtt wants to merge 1 commit intomainfrom
get-app-key

Conversation

@Gudahtt
Copy link
Copy Markdown
Member

@Gudahtt Gudahtt commented Nov 26, 2019

The new getAppKey method will return the private app key derived from the provided origin. This serves as an alternative to optionally augmenting each keyring method with a set of options that may contain a withAppKeyOrigin value.

Moving app key generation to a single place makes it easier to limit access to sensitive information, such as the primary private keys. It also allows the consumer to use app keys more efficiently by using the same wallet for successive operations, rather than generating a new private key each time with keccak.

The private app key returned can itself be used to instantiate a new keyring instance, which allows app keys to perform all the same functions that a 'normal' key would allow.

The new `getAppKey` method will return the private app key derived from
the provided origin. This serves as an alternative to optionally
augmenting each keyring method with a set of options that may contain
a `withAppKeyOrigin` value.

Moving app key generation to a single place makes it easier to limit
access to sensitive information, such as the primary private keys. It
also allows the consumer to use app keys more efficiently by using the
same wallet for successive operations, rather than generating a new
private key each time with `keccak`.

The private app key returned can itself be used to instantiate a new
keyring instance, which allows app keys to perform all the same
functions that a 'normal' key would allow.
@Gudahtt
Copy link
Copy Markdown
Member Author

Gudahtt commented Nov 26, 2019

This depends upon MetaMask/eth-simple-keyring#35 , and upon v4.0.0 of eth-simple-keyring being published.

@Gudahtt
Copy link
Copy Markdown
Member Author

Gudahtt commented Nov 26, 2019

I will bump the version to v4.0.0 after eth-simple-keyring is published. I can't generate the correct lockfile until then anyway.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant