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

Avoid address reuse after restarting. #804

Merged
merged 2 commits into from
Jun 12, 2017
Merged

Conversation

jrick
Copy link
Member

@jrick jrick commented Jun 8, 2017

A database upgrade has been added which records the last-returned
child index of both the external and internal branches of each BIP0044
account. As addresses are generated, these child indexes are recorded
in the database and read on the next application startup. New
addresses created after restart use child indexes after the last
returned index in order to prevent accidental address reuse.

Fixes #799.

@jrick jrick added the WIP label Jun 8, 2017
@jrick jrick force-pushed the persistence branch 4 times, most recently from 777b70d to 681c8f1 Compare June 12, 2017 16:03
This also includes the source code to generate the v4 database.
@jrick jrick force-pushed the persistence branch 2 times, most recently from 62dd178 to a3e0d75 Compare June 12, 2017 17:33
A database upgrade has been added which records the last-returned
child index of both the external and internal branches of each BIP0044
account.  As addresses are generated, these child indexes are recorded
in the database and read on the next application startup.  New
addresses created after restart use child indexes after the last
returned index in order to prevent accidental address reuse.
Copy link
Member

@alexlyp alexlyp left a comment

Choose a reason for hiding this comment

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

tACK and code looks great.

@jrick jrick merged commit 5a416ae into decred:master Jun 12, 2017
@jrick jrick deleted the persistence branch June 12, 2017 18:09
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

Successfully merging this pull request may close these issues.

2 participants