forex.pm forex forum binary options trade - Binance - Сryptocurrency exchanges - Cant send raw transaction from golang with OP_EQUALVERIFY failed
  • Welcome to forex.pm forex forum binary options trade. Please login or sign up.
 

Cant send raw transaction from golang with OP_EQUALVERIFY failed

Started by Bitcoin, Feb 20, 2022, 04:43 am

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Bitcoin

Cant send raw transaction from golang with OP_EQUALVERIFY failed

I'm using btcsuite (especially this example) package to listen and send unspent inputs for specific address.


Tx hash: 690059e82dcee13678c45f2c583207d357af254624f5037b4d4d12b39caf74ca


From address: mkdaWH9TeZB79vJsLkAU9vYKgAASkjRtWh


To address: mkirYMeQ8WNCHRFo7rRjADHNDVTqYjrNUg


Raw transaction: 0100000001ca74af9cb3124d4d7b03f5244625af57d30732582c5fc47836e1ce2de8590069000000008b483045022100d50f5c0a49cc7307ee8ee450622a6442606aeed02bd7835ee8cde8f553ac25da02201c3fe5c99f3264cd70bc0837d136839ea1fb5b807d10205d1a54a9cb5419cb780141047da316f92b23e3235a0d2ef8ea8ee66a85f2864dd3aa01da669a108c90ef18212c3a4a233e9409a124e0e04f0d1341a6e58f36a62c1c4c04601e6230fe601365ffffffff0127110000000000001976a9143918d158eb42fbc602da0795d0664b9830ef08db88ac00000000


Result: -25: TX rejected: failed to validate input 9a2f1724f86540620c1f976cc5c294ba0a59e03ccbdeadf3fe2cbe470d0b9f45:0 which references output 690059e82dcee13678c45f2c583207d357af254624f5037b4d4d12b39caf74ca:0 - OP_EQUALVERIFY failed (input witness [], input script bytes 483045022100d50f5c0a49cc7307ee8ee450622a6442606aeed02bd7835ee8cde8f553ac25da02201c3fe5c99f3264cd70bc0837d136839ea1fb5b807d10205d1a54a9cb5419cb780141047da316f92b23e3235a0d2ef8ea8ee66a85f2864dd3aa01da669a108c90ef18212c3a4a233e9409a124e0e04f0d1341a6e58f36a62c1c4c04601e6230fe601365, prev output script bytes 76a91438195a17cb2a6e7f9992c40aa0adeec12570c40788ac)


Gist code example (some values are hardcoded): https://gist.github.com/aemet93/252ed5479d5db74b3da5cc0b608b4d57


Source: Cant send raw transaction from golang with OP_EQUALVERIFY failed