bitshares / bsips

BitShares Improvement Proposals and Protocols. These technical documents describe the process of updating and improving the BitShares blockchain and technical ecosystem.
https://bitshares.github.io
63 stars 86 forks source link

BSIP 64: Optional HTLC Preimage Length and Add Hash160 Algorithm #195

Closed jmjatlanta closed 5 years ago

jmjatlanta commented 5 years ago

This BSIP will remove the requirement of a preimage length (making it optional), and adding an additional hash algorithm.

This PR fixes Issue https://github.com/bitshares/bsips/issues/163

xeroc commented 5 years ago

I like the solution that sets the size to 0 to disable length check!

+1

jmjatlanta commented 5 years ago

@pmconrad I believe I addressed your concerns. Please review and let me know if you have anything else. Thanks!

nathanielhourt commented 5 years ago

I've written a hash160 implementation here, although I'd like to get some test data to ensure it is compliant with other implementations. Does anyone know of any test data or an easy-to-use hash160 tool?

pmconrad commented 5 years ago

@nathanhourt have you seen https://github.com/bitshares/bitshares-fc/pull/143 ?

nathanielhourt commented 5 years ago

Ahh, nope.

pmconrad commented 5 years ago

How about including this change here #202:

Introducing this commonly used and known item for HTLC transaction as an optional feature is a very helpful step to satisfy the future of Cross Chain Swaps, parties involved within the Cross Chain Swaps will have to communicate their external addresses or some helpful references and info within the HTLC transaction upon creation.

pmconrad commented 5 years ago

Please specify that the memo field will be added as an extension to htlc_create_operation. This is sufficient to include it into the recipient's history, so there's no need to add it to the htlc_object.