Sign and submit transaction #73
Unanswered
zweetdreamz
asked this question in
Q&A
Replies: 1 comment
-
Hi @zweetdreamz , is there already something in the witness set in the original tx = Transaction.from_cbor(cbor_data)
tx_body = tx.transaction_body
vk = PaymentVerificationKey.from_signing_key(sk)
signature = sk.sign(tx_body.hash())
if tx.transaction_witness_set.vkey_witnesses is not None:
tx.transaction_witness_set.vkey_witnesses.append(VerificationKeyWitness(vk, signature))
else:
tx.transaction_witness_set.vkey_witnesses = [VerificationKeyWitness(vk, signature)]
context.submit(tx) |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi everyone,
How can I sign and submit transaction to blockchain?
I have transaction in cbor like
84a80083825...65397b73f5f6
I have tried this code, but it doesnt work for me
Thank you.
Beta Was this translation helpful? Give feedback.
All reactions