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

Conversation

@kumavis
Copy link
Member

@kumavis kumavis commented Jan 12, 2022

Based on LeastAuthority Audit December 2021: Suggestion 1 and Suggestion 5

this would be a breaking change in behavior (requires consumer to call generateRandomMnemonic() after initialization for creating new SRPs)

@kumavis kumavis requested a review from a team as a code owner January 12, 2022 01:07
Copy link
Member

@Gudahtt Gudahtt left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

addAccounts(numberOfAccounts = 1) {
if (!this.root) {
this._initFromMnemonic(bip39.generateMnemonic());
throw new Error('Eth-Hd-Keyring: No secret recovery phrase provided');
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: It would be nice to have this covered by a test as well

@kumavis kumavis merged commit 4b04a99 into main Feb 14, 2022
@kumavis kumavis deleted the explicit-generate-random branch February 14, 2022 18:52
@adonesky1 adonesky1 mentioned this pull request Apr 14, 2022
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.

3 participants