Advertisement
Guest User

Untitled

a guest
Jun 17th, 2019
130
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.83 KB | None | 0 0
  1. const script = this.app.env.bitcoin.script.compile([
  2. hashOpcode,
  3. Buffer.from(secretHash, "hex"),
  4. this.app.env.bitcoin.opcodes.OP_EQUALVERIFY,
  5.  
  6. Buffer.from(recipientPublicKey, "hex"),
  7. this.app.env.bitcoin.opcodes.OP_EQUAL,
  8. this.app.env.bitcoin.opcodes.OP_IF,
  9.  
  10. Buffer.from(recipientPublicKey, "hex"),
  11. this.app.env.bitcoin.opcodes.OP_CHECKSIG
  12. ])
  13.  
  14. Buffer.from(recipientPublicKey, "hex"),
  15. this.app.env.bitcoin.opcodes.OP_EQUAL,
  16. this.app.env.bitcoin.opcodes.OP_AND,
  17. Buffer.from(exchangePublicKey, "hex"),
  18. this.app.env.bitcoin.opcodes.OP_EQUAL,
  19. this.app.env.bitcoin.opcodes.OP_IF,
  20.  
  21. Buffer.from(recipientPublicKey, "hex"),
  22. this.app.env.bitcoin.opcodes.OP_CHECKMULTISIG,
  23. this.app.env.bitcoin.opcodes.OP_AND,
  24. Buffer.from(exchangePublicKey, "hex"),
  25. this.app.env.bitcoin.opcodes.OP_CHECKMULTISIG,
  26. this.app.env.bitcoin.opcodes.OP_ELSE,
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement