1

I am quite familiar with the way secp256k1 ECDSA works as well as the equations that are utilised. However, I have no idea how this ECDSA applies to signing Bitcoin (SegWit Format) and transferring it to another wallet address.

For instance, if I have some Bitcoin Input in my wallet, how is the secp256k1 curve used so that I can unlock (verify that I own) that Bitcoin and transfer it to Bob. Then, how can Bob sign this Bitcoin that he received using the curve.

1
  • 1
    Please use regular capitalization in topic titles, these aren't newspaper headlines.
    – Murch
    Jun 22, 2022 at 15:35

1 Answer 1

2

You say you are familiar with how secp256k1 and ECDSA works but from what you say later I'm unsure whether you are. SegWit v0 didn't change the signing algorithm (ECDSA) nor the curve (secp256k1). SegWit v1 (Taproot) did change the signing algorithm (Schnorr). The address format with SegWit v0 (bech32) did change but that is nothing to do with signing. The signing part is exactly the same as pre-SegWit other than the message (or transaction data) being signed. What is signed is defined by the sighash flag which did change with the SegWit upgrade (BIP 143).

For instance, if I have some Bitcoin Input in my wallet, how is the secp256k1 curve used so that I can unlock (verify that I own) that Bitcoin and transfer it to Bob. Then, how can Bob sign this Bitcoin that he received using the curve.

With SegWit v0 you produce a witness (that generally includes a signature generated using the ECDSA signing algorithm) to transfer Bitcoin to a new destination. The key thing with the introduction of SegWit was where the witness is stored and not how the signature was generated. However the receiver (Bob in this case) doesn't sign anything. The funds are locked to his public key/address but he only needs to produce a signature if and when he moves the funds from this address.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.