-
Notifications
You must be signed in to change notification settings - Fork 714
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
[wallet] Reopen CDBEnv after encryption instead of shutting down #2648
[wallet] Reopen CDBEnv after encryption instead of shutting down #2648
Commits on Nov 24, 2021
-
wallet: Reset BerkeleyDB handle after connection fails
According to the BerkeleyDB docs, the DbEnv handle may not be accessed after close() has been called. This change ensures that we create a new handle after close() is called. This avoids a segfault when the first connection attempt fails and then a second connection attempt tries to call open() on the already closed DbEnv handle.
Configuration menu - View commit details
-
Copy full SHA for 5670880 - Browse repository at this point
Copy the full SHA 5670880View commit details -
Configuration menu - View commit details
-
Copy full SHA for cba20b9 - Browse repository at this point
Copy the full SHA cba20b9View commit details -
Move BerkeleyEnvironment deletion from internal method to callsite
Instead of having the object destroy itself, having the caller destroy it.
Configuration menu - View commit details
-
Copy full SHA for 8e57466 - Browse repository at this point
Copy the full SHA 8e57466View commit details -
Configuration menu - View commit details
-
Copy full SHA for f4200eb - Browse repository at this point
Copy the full SHA f4200ebView commit details -
Add function to close all Db's and reload the databae environment
Adds a ReloadDbEnv function to BerkeleyEnvironment in order to close all Db instances, closes the environment, resets it, and then reopens the BerkeleyEnvironment. Also adds a ReloadDbEnv function to BerkeleyDatabase that calls BerkeleyEnvironment's ReloadDbEnv.
Configuration menu - View commit details
-
Copy full SHA for 17ac47e - Browse repository at this point
Copy the full SHA 17ac47eView commit details -
After encrypting the wallet, reload the database environment
Calls ReloadDbEnv after encrypting the wallet so that the database environment is flushed, closed, and reopened to prevent unencrypted keys from being saved on disk.
Configuration menu - View commit details
-
Copy full SHA for 64a8a73 - Browse repository at this point
Copy the full SHA 64a8a73View commit details
Commits on Nov 25, 2021
-
No longer shutdown after encrypting the wallet
Since the database environment is flushed, closed, and reopened during EncryptWallet, there is no need to shut down the software anymore. Adaptation of btc@c1dde3a949b36ce9c2155777b3fa1372e7ed97d8
Configuration menu - View commit details
-
Copy full SHA for 6e03bf2 - Browse repository at this point
Copy the full SHA 6e03bf2View commit details -
Configuration menu - View commit details
-
Copy full SHA for 28d17a1 - Browse repository at this point
Copy the full SHA 28d17a1View commit details
Commits on Nov 28, 2021
-
test: add temp wallet testing setup.
There are tests, like the ones that uses the wallet encryption, that need access to a real wallet database and not to a mock.
Configuration menu - View commit details
-
Copy full SHA for c5340ec - Browse repository at this point
Copy the full SHA c5340ecView commit details