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

Seedutil: derive child seed for swap clients (allow creation any time) #1576

Closed
kilrau opened this issue May 23, 2020 · 1 comment · Fixed by #1928
Closed

Seedutil: derive child seed for swap clients (allow creation any time) #1576

kilrau opened this issue May 23, 2020 · 1 comment · Fixed by #1928
Assignees
Labels

Comments

@kilrau
Copy link
Contributor

kilrau commented May 23, 2020

Change lndbtc/lndltc to derive a child seed (or rather the entropy for such) from the seedutil master seed and create with these, just like connext already does.

This allows allows swap clients to be created any time, xucli create to be called any time, the new behavior of xucli create could be along the lines: xud detects connected swap clients which aren't created yet (based on files which only exist if client is created since client can be locked). xucli create output will tell user which clients will be created so the user can sanity check if all she wants are listed. If user confirms, xud will create these new swap clients without touching existing ones.

I propose to split this up into two:

  1. Derive entropy from seedutil master seed, create lnd swap clients with this (connext already does)
  2. UX flow allowing to create a swap client after initial create as a follow-up issue
@kilrau
Copy link
Contributor Author

kilrau commented Sep 9, 2020

Bumping prio since this is a dependency for some other issues, see #1815 (comment)

@kilrau kilrau added P2 mid priority and removed P3 low priority labels Sep 9, 2020
@kilrau kilrau added P1 top priority and removed P2 mid priority labels Oct 8, 2020
sangaman added a commit that referenced this issue Oct 9, 2020
This change uses separate mnemonics and seeds for each swap client that
are unique to that client, rather than using a single seed and mnemonic
across all clients. To accomplish this, a new method is added to the
seedutil tool to derive a child mnemonic from a provided mnemonic. This
is done by extracting the 16 bytes of entropy from the provided seed,
concatenating the entropy with the name of the client (e.g. "LND-BTC")
and then hashing the concatenation and taking 16 bytes from the
resulting hash.

Closes #1576.
sangaman added a commit that referenced this issue Oct 9, 2020
This change uses separate mnemonics and seeds for each swap client that
are unique to that client, rather than using a single seed and mnemonic
across all clients. To accomplish this, a new method is added to the
seedutil tool to derive a child mnemonic from a provided mnemonic. This
is done by extracting the 16 bytes of entropy from the provided seed,
concatenating the entropy with the name of the client (e.g. "LND-BTC")
and then hashing the concatenation and taking 16 bytes from the
resulting hash.

Closes #1576.
sangaman added a commit that referenced this issue Oct 9, 2020
This change uses separate mnemonics and seeds for each swap client that
are unique to that client, rather than using a single seed and mnemonic
across all clients. To accomplish this, a new method is added to the
seedutil tool to derive a child mnemonic from a provided mnemonic. This
is done by extracting the 16 bytes of entropy from the provided seed,
concatenating the entropy with the name of the client (e.g. "LND-BTC")
and then hashing the concatenation and taking 16 bytes from the
resulting hash.

Closes #1576.
sangaman added a commit that referenced this issue Oct 9, 2020
This change uses separate mnemonics and seeds for each swap client that
are unique to that client, rather than using a single seed and mnemonic
across all clients. To accomplish this, a new method is added to the
seedutil tool to derive a child mnemonic from a provided mnemonic. This
is done by extracting the 16 bytes of entropy from the provided seed,
concatenating the entropy with the name of the client (e.g. "LND-BTC")
and then hashing the concatenation and taking 16 bytes from the
resulting hash.

Closes #1576.
@ghost ghost closed this as completed in #1928 Oct 13, 2020
This issue was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants