0
0
Fork 0
mirror of https://github.com/bitcoin/bitcoin.git synced 2025-02-09 10:43:19 -05:00
bitcoin-bitcoin-core/src/rpc
Wladimir J. van der Laan 961901f77e
Merge #11117: Prepare for non-Base58 addresses
864cd2787 Move CBitcoinAddress to base58.cpp (Pieter Wuille)
5c8ff0d44 Introduce wrappers around CBitcoinAddress (Pieter Wuille)

Pull request description:

  This patch removes the need for the intermediary Base58 type `CBitcoinAddress`, by providing {`Encode`,`Decode`,`IsValid`}`Destination` functions that directly operate on the conversion between `std::string`s and `CTxDestination`.

  As a side, it also fixes a number of indentation issues, and removes probably several unnecessary implicit `CTxDestination`<->`CBitcoinAddress` conversions.

  This change is far from complete. In follow-ups I'd like to:
  * Split off the specific address and key encoding logic from base58.h, and move it to a address.h or so.
  * Replace `CTxDestination` with a non-`boost::variant` version (which can be more efficient as `boost::variant` allocates everything on the heap, and remove the need for `boost::get<...>` and `IsValidDestination` calls everywhere).
  * Do the same for `CBitcoinSecret`, `CBitcoinExtKey`, and `CBitcoinExtPubKey`.

  However, I've tried to keep this patch to be minimally invasive, but still enough to support non-Base58 addresses. Perhaps a smaller patch is possible to hack Bech32 support into `CBitcoinAddress`, but I would consider that a move in the wrong direction.

Tree-SHA512: c2c77ffb57caeadf2429b1c2562ce60e8c7be8aa9f8e51b591f354b6b441162625b2efe14c023a1ae485cf2ed417263afa35c892891dfaa7844e7fbabccab85e
2017-09-06 22:31:02 +02:00
..
blockchain.cpp Merge #11203: rpc: add wtxid to mempool entry output 2017-09-06 20:57:18 +02:00
blockchain.h Remove unnecessary forward class declarations in header files 2017-06-12 20:37:43 +02:00
client.cpp listsinceblock: optionally find and list any transactions that were undone due to reorg when requesting a non-main chain block in a new 'removed' array. 2017-07-21 09:50:59 +09:00
client.h rpc: Named argument support for bitcoin-cli 2017-01-10 12:04:54 +01:00
mining.cpp Introduce wrappers around CBitcoinAddress 2017-09-06 13:07:45 -07:00
mining.h Properly bound check conf_target in wallet RPC calls 2017-07-14 23:41:40 -04:00
misc.cpp Introduce wrappers around CBitcoinAddress 2017-09-06 13:07:45 -07:00
net.cpp rpc: Push down safe mode checks 2017-08-29 10:09:41 +02:00
protocol.cpp rpc: Write authcookie atomically 2017-08-25 15:37:24 +02:00
protocol.h rpc: Write authcookie atomically 2017-08-25 15:37:24 +02:00
rawtransaction.cpp Introduce wrappers around CBitcoinAddress 2017-09-06 13:07:45 -07:00
register.h Do not shadow global RPC table variable (tableRPC) 2016-08-25 15:02:26 +02:00
safemode.cpp rpc: Push down safe mode checks 2017-08-29 10:09:41 +02:00
safemode.h rpc: Push down safe mode checks 2017-08-29 10:09:41 +02:00
server.cpp rpc: Push down safe mode checks 2017-08-29 10:09:41 +02:00
server.h rpc: Push down safe mode checks 2017-08-29 10:09:41 +02:00