No description
Find a file
Gregory Sanders c67ef2938c
Merge #600: PSBT for Confidential Assets
3127c6561 Add legacy help text for walletprocesspsbt suggesting to use new RPCs instead. (Glenn Willen)
d39925b08 Disable PSBT RPCs when not in g_con_elementsmode. (Glenn Willen)
2848b520b PSBT for Confidential Assets (Glenn Willen)
f87684a00 Add convenience method GetNonIssuanceBlindingData (Glenn Willen)

Pull request description:

  This PR extends the PSBT format and RPCs to handle Confidential Assets transactions.

  New fields in PSBT inputs: Unblinded value, Value blinder, Unblinded asset, Asset blinder.
  New fields in PSBT outputs: Recipient blinding pubkey, Value commitment, Value blinder, Asset commitment, Asset blinder, Nonce commitment, Range proof, Surjection proof.

  We preserve the existing invariant that the unsigned transaction inside a PSBT never changes during the process; all updates that need to be applied to produce the final signed transaction are accumulated in the PSBT fields listed above.

  The process is as follows:
  * Create a PSBT using `converttopsbt` [deprecated], `walletcreatefundedpsbt`, `createpsbt`
     * At this point, the output pubkey fields will be filled, for any outputs to confidential addresses.
     * Input fields may be filled, if the wallet was used; otherwise they will be filled in the next step.
     * Incremental creation of the unsigned transaction itself is OUTSIDE the scope of this work. The unsigned transaction must be fully populated with inputs and outputs before the PSBT is created.
     * Transactions with peg-in, issuance, or reissuance outputs are NOT supported at this time.
  * If necessary, update the psbt with input data using `walletfillpsbtdata`.
     * This is like the old `walletprocesspsbt` RPC [deprecated], which tried to both fill and sign the PSBT (which is not workable in the Confidential Assets setting.)
  * Once all inputs have had necessary data updated, possibly using multiple wallets if necessary, any wallet can be used to blind the transaction using `blindpsbt`.
     * This uses the input blinding data, along with the output blinding pubkeys, to compute the output blinding data.
     * Incremental blinding is not supported. All input blinding data must be available when `blindpsbt` is called.
  * Then, the blinded PSBT must be signed using `walletsignpsbt`. As with updating, this can be done by multiple wallets as necessary for the inputs being signed.
  * Once all signatures are present, `finalizepsbt` is used to create the final transaction in the regular transaction format, as before.
  * Then `sendrawtransaction` is used, which will check to make sure that blinding was performed properly before sending.

Tree-SHA512: 2844a1545383cdab6025b90791c9e66f280d988bd40e37354c831b309c4c41eead144ca6d69c956cac40e849978c3450d1a22910f51ca3c6245236b29c05faa8
2019-07-31 15:06:51 -04:00
.github Get more info about GUI-related issue on Linux 2018-12-27 06:53:07 +02:00
.travis travis: Switch to ubuntu keyserver to avoid timeouts 2019-05-31 14:54:10 +01:00
.tx qt: Pre-0.18 split-off translations update 2019-02-04 15:24:37 +01:00
build-aux/m4 Bump minimum Qt version to 5.5.1 2019-02-14 11:12:30 +01:00
build_msvc Update msft build version too 2019-06-05 12:44:28 +02:00
contrib Squashed 'src/secp256k1/' changes from 43dd1f4..44db4d8 2019-06-06 11:40:35 +02:00
depends Update zmq to 4.3.1 2019-01-18 10:25:14 +02:00
doc travis: Properly cache and error on timeout 2019-05-31 14:54:25 +01:00
share UPSTREAM MERGE BROKEN: Merge upstream commit '519b0bc5dc' into master 2019-05-17 16:17:09 +01:00
src Add legacy help text for walletprocesspsbt suggesting to use new RPCs instead. 2019-07-31 10:50:03 -07:00
test PSBT for Confidential Assets 2019-07-31 10:50:03 -07:00
.appveyor.yml appveyor: Remove unused NDEBUG removal 2019-02-17 18:26:49 +08:00
.gitattributes Separate protocol versioning from clientversion 2014-10-29 00:24:40 -04:00
.gitignore Squashed 'src/secp256k1/' changes from 43dd1f4..44db4d8 2019-06-06 11:40:35 +02:00
.python-version [test] Travis: enforce Python 3.4 support in functional tests 2018-12-12 10:39:32 +01:00
.travis.yml Squashed 'src/secp256k1/' changes from 43dd1f4..44db4d8 2019-06-06 11:40:35 +02:00
autogen.sh Add "export LC_ALL=C" to all shell scripts 2018-06-14 15:27:52 +02:00
configure.ac Squashed 'src/secp256k1/' changes from 43dd1f4..44db4d8 2019-06-06 11:40:35 +02:00
CONTRIBUTING.md UPSTREAM MERGE BROKEN: Merge upstream commit '519b0bc5dc' into master 2019-05-17 16:17:09 +01:00
COPYING [Trivial] Update license year range to 2019 2018-12-31 04:27:59 +01:00
INSTALL.md Update INSTALL landing redirection notice for build instructions. 2016-10-06 12:27:23 +13:00
libbitcoinconsensus.pc.in Unify package name to as few places as possible without major changes 2015-12-14 02:11:10 +00:00
Makefile.am Squashed 'src/secp256k1/' changes from 43dd1f4..44db4d8 2019-06-06 11:40:35 +02:00
README.md Squashed 'src/secp256k1/' changes from 43dd1f4..44db4d8 2019-06-06 11:40:35 +02:00
SECURITY.md Add secure reporting document, link in README 2019-03-20 12:05:21 +00:00

Elements Project blockchain platform

Build Status

https://elementsproject.org

This is the integration and staging tree for the Elements blockchain platform, a collection of feature experiments and extensions to the Bitcoin protocol. This platform enables anyone to build their own businesses or networks pegged to Bitcoin as a sidechain or run as a standalone blockchain with arbitrary asset tokens.

Modes

Elements supports a few different pre-set chains for syncing. Note though some are intended for QA and debugging only:

  • Liquid mode: elementsd -chain=liquidv1 (syncs with Liquid network)
  • Bitcoin mainnet mode: elementsd -chain=main (not intended to be run for commerce)
  • Bitcoin testnet mode: elementsd -chain=testnet3
  • Bitcoin regtest mode: elementsd -chain=regtest
  • Elements custom chains: Any other -chain= argument. It has regtest-like default parameters that can be over-ridden by the user by a rich set of start-up options.

Confidential Assets

The latest feature in the Elements blockchain platform is Confidential Assets, the ability to issue multiple assets on a blockchain where asset identifiers and amounts are blinded yet auditable through the use of applied cryptography.

Features of the Elements blockchain platform

Compared to Bitcoin itself, it adds the following features:

Previous elements that have been integrated into Bitcoin:

  • Segregated Witness
  • Relative Lock Time

Elements deferred for additional research and standardization:

License

Elements is released under the terms of the MIT license. See COPYING for more information or see http://opensource.org/licenses/MIT.

What is the Elements Project?

Elements is an open source, sidechain-capable blockchain platform. It also allows experiments to more rapidly bring technical innovation to the Bitcoin ecosystem.

Learn more on the Elements Project website

https://github.com/ElementsProject/elementsproject.github.io

Secure Reporting

See our vulnerability reporting guide