| 215 | } |
| 216 | |
| 217 | bool WalletBatch::WriteDescriptorKey(const uint256& desc_id, const CPubKey& pubkey, const CPrivKey& privkey) |
| 218 | { |
| 219 | // hash pubkey/privkey to accelerate wallet load |
| 220 | const auto keypair_hash = Hash(pubkey, privkey); |
| 221 | |
| 222 | return WriteIC(std::make_pair(DBKeys::WALLETDESCRIPTORKEY, std::make_pair(desc_id, pubkey)), std::make_pair(privkey, keypair_hash), false); |
| 223 | } |
| 224 | |
| 225 | bool WalletBatch::WriteCryptedDescriptorKey(const uint256& desc_id, const CPubKey& pubkey, const std::vector<unsigned char>& secret) |
| 226 | { |
no test coverage detected