Continuing #5916 by adding backward compatibility with existing wallets
wallet: Add key generation type #8132
pull luke-jr wants to merge 4 commits into bitcoin:master from luke-jr:keygentype changing 5 files +57 −3-
luke-jr commented at 7:32 PM on June 1, 2016: member
-
1d6d3dad68
add key generation type
A encrypted wallet can still hold keys which where created when the wallet was unencrypted. This PR will add a 8bit-flags-int to the CKeyMetadata class. `listreceivedbyaddress` will report whether the key was generated within a enctypted wallet or if it was imported throught `importprivkey`
-
renamed keyGenerationType to keyOrigin, added new wallet feature level f1fef042df
-
Use a 32bit bitmask for key generation type, remove unset type d4142be472
-
wallet: Provide compatibility with existing wallets using 8-bit flags 104ab313ba
-
jonasschnelli commented at 9:04 AM on June 2, 2016: contributor
Hmm... we never have deployed #5916 (I guess you did in your custom distribution?). This would mean 104ab313baeac2f909ce1fb10fe8562327b35e01 would address a feature-compatibility between third party distribution. Okay for me but results in some ugly migration code.
My preferred solution would be:
- a) 104ab313baeac2f909ce1fb10fe8562327b35e01 must only be included in your custom distribution (if people swap wallet.dat from your fork to Core they might need to manually migrate first)
- b) If a) is problematic, keep the 8BIT bitfield and merge #5916 (which should be sufficient IMO).
PR nit:
s/FEATURE_KEYFLAGS_OLD/FEATURE_KEYFLAGS_8BIT/,s/VERSION_SUPPORT_FLAGS_OLD/VERSION_SUPPORT_FLAGS_8BIT/ - jonasschnelli added the label Wallet on Jun 2, 2016
-
luke-jr commented at 2:51 PM on June 2, 2016: member
I called it "OLD" rather than "8BIT" because there's a bitshift involved.
Any idea what's up with Travis's Mac build? :/
-
laanwj commented at 1:21 PM on June 3, 2016: member
I'd prefer to not include migration code for something that we never deployed. You can include that in your own distribution, of course.
- luke-jr closed this on Sep 10, 2016
- DrahtBot locked this on Sep 8, 2021