ELI5 PSBT – Partially Signed Bitcoin Transactions

ELI5 PSBT – Partially Signed Bitcoin Transactions
on September 28, 2019

One of the key concepts behind cryptocurrencies is that you should not have to meet, much less trust, your peers in order to perform successful transactions. That’s why every new addition to Bitcoin Core is carefully designed to follow a decentralized and trustless mindset.

Imagine a situation where users, who could be collaborating remotely in some project and who’ve never met each other before, need to collectively agree to make a group payment. (Note: They could have met but Bitcoin makes no such assumption.) Each member will chip in some BTC and everyone will pay for it together, like a group restaurant bill.

One way to do it would be for each member to send a transaction and then send the TXID to a chosen coordinator who’d gather the payments and make sure the purchase is settled. But this implies a central trusted entity – someone who’d have the responsibility to collect the money, make the payment and then make sure it went through correctly so he could send everyone a receipt afterwards. This would be a fine strategy among friends, if it weren’t for the obvious problem: it isn’t a decentralized solution. Whenever a middleman, an escrow or any other trusted party is required, the solution is no longer decentralized.

PSBT

Enter Partially Signed Bitcoin Transactions (PSBT)

You may be familiar with the concept of a multi-signature, or multisig, system? In this type of system two or more people must sign a transaction in order for it to be valid. There are several possible multisig setups, like 3 out of 5 people must sign, husband or wife may sign and so on, but details about them are beyond the scope of this article.

Multisig payments have one limitation, though: the act of signing must be simultaneous. Everyone who agrees with a transaction must sign it at once before it’s broadcast to the network.

Now imagine that there was a protocol such that a Bitcoin transaction that required multiple signatures was created but this transaction didn’t have to be built at once.

One user could sign today, another user could examine the TX and decide whether to sign later on and so forth. All this without a trusted intermediary!

That’s what PSBT achieves. BIP 174 was proposed in mid 2017 to address exactly this scenario – and this system is already available in the latest Bitcoin Core releases! Here’s a simple example scenario that illustrates now PSBT works.

So it’s been decided that a group payment must be performed. One of the group members creates a PSBT and adds  unspent outputs, both his and others’ and the desired target inputs (who will receive the payment). He transmits the TX id and the Bitcoin network spreads this unfinished TX.

Other users whose inputs are included in the PSBT have their full nodes running. The node identifies a PSBT that includes a local address and shows the user the partial transaction and what’s inside it. The user analyzes the inputs, outputs and amounts and decides whether it’s legit or not. If there’s agreement, the user then adds his signature to the PSBT.

Once every participant has added their signature, the PSBT is complete. It is then compiled into a regular multisig Bitcoin transaction just as if it had been signed simultaneously. The TX is transmitted and mined like any other transaction.

That’s how PSBT’s work! Fully decentralized – no single entity needs to be relied on or trusted to coordinate and distribute funds.

Users must only know each others’s Bitcoin addresses. This is a requirement for all Bitcoin payment processing anyway. So the only manual coordination that’s needed between users is to know each others’ addresses. For which they can coordinate via email or some other collaboration system.

I hope this short intro to partially signed Bitcoin transactions has made the concept clearer for you! For technical details please consult some of the links at the end of this article.

References

PSBT Documentation

BIP 174 – PSBT

Multisig