Bitcoin Forum

Bitcoin => Development & Technical Discussion => Topic started by: Majestic-milf on August 02, 2022, 08:32:38 AM



Title: Why PTLC when HTLC does the job
Post by: Majestic-milf on August 02, 2022, 08:32:38 AM
 I'm quite confused about this and would need some insight on this. What does PTLC offer that makes it far better than HTLC? I'm aware that Taproot is an improvement or upgrade to the LN, but where I can't grab is why the PTLC is more preferred.

Contributions to this will be duly appreciated, thanks.


Title: Re: Why PTLC when HTLC does the job
Post by: j2002ba2 on August 02, 2022, 09:53:30 AM
This is the main disadvantage of HTLC:
When used to secure multiple payments (e.g. a routed LN payment or an atomic swap), all payments use the same preimage and hash lock. This creates a link between those payments if they’re published onchain or if they’re routed offchain though surveillance nodes.
Also using the same hash gives surveillance information for a single payment as well, by revealing parts of the path.

In contrast PTLC:
Each point lock can use different keys and signatures, so there is nothing about the point lock that correlates different payments either onchain or when routed offchain through surveillance nodes.


Title: Re: Why PTLC when HTLC does the job
Post by: NotATether on August 02, 2022, 10:59:38 AM
In contrast PTLC:
Each point lock can use different keys and signatures, so there is nothing about the point lock that correlates different payments either onchain or when routed offchain through surveillance nodes.

PLTC depends on Schnorr signatures to be widely implemented on wallets and blockchain software first (and as Pieter Wuille explained to me on the mailing list, any implementation that supports Taproot already has the necessary code for making Schnorr signatures), so it's merely a matter on supporting Taproot in more places - and it will budge exchanges that want to participate with them to finally support segwit and bech32 in the process.


Title: Re: Why PTLC when HTLC does the job
Post by: Zilon on August 02, 2022, 11:23:22 AM
Both HTLC and PTLC are conditional payment options used in multi signature payment. For HTLC the payments are locked using a hash message/digest and can only be unlocked by the preimage that accurately matches the digest hashed. This message digest uses Hash 256 function which produces a 256-bit (32-byte) digest commonly generated from a 32-byte preimage.

For PTLC public keys here serve as the lock and can only be unlocked by proving a signature that matches the signature adaptors. PTLC allows outputs created to be spent if anyone can provide a digital signature to the address that arise from the public key that comes from a secret.

What makes PTLC more preferred to HTLC is the uncorrelated payment it offers offers both onchain and off chain meaning. We can say PTLC provides a secure, private with multisig and  makes multiparty payment using Schnorr signature