What is WIF?
👉 it means Wallet Import Format.
What is messagePrefix?
👉 there is a list of address prefixes for Base58Check which is the exception of Bech32 encoding.
How Different the type of Bitcoin addresses is ?!
====P2PKH====
Legacy Address
// start with the number 1
example: "15e15hWo6CShMgbAfo8c2Ykj4C6BLq6Not"
// the legacy address is simply the hash of the public key to your private key.
// That address type isn't recommended not to be incompatible with newer address type
====P2SH====
Pay to ScriptHash
// start with the number 3
example: "35PBEaofpUeH8VnnNSorM1QZsadrZoQp4N"
// It isn't the hash of the public key, but of a script that involves certain spending conditions, which stay hidden from the sender.
// this spending conditions can be very simple => owner of public key A can spend this bitcoin
// it can make use of SegWit and save transaction fee.
How different the trasaction fee between P2SH and P2PKH
=> Sending to a P2SH address is roughly 26% cheaper than using a wallet with legacy addresses!!!
=> Ok I understand, But why different?!
====P2WPKH====
Native SegWit
// start with "bc1q"
example: "bc1q42lja79elem0anu8q8s3h2n687re9jax556pcc"
// this type of address reduces the amount of information stored in the transaction even more by not keeping the signature and script within the transaction, but in the witness.
====P2TR====
Taproot addresses
// start with "bc1p"
example: "bc1pmzfrwwndsqmk5yh69yjr5lfgfg4ev8c0tsc06e"
// this isn't used yet.
// this will enable a lot if new smart-contract capabilities for bitcoin-addresses and improve the privacy of spending such transactions.
Transaction Fee
P2PKH >>(26%)>> P2SH >>(16%)>> P2WPKH
you can save over 38% fee over legacy addresses
because P2WPKH is currently the most used standard for addresses.
I have two questions!
1️⃣ Can you explain the more details of "witness" in P2WPKH??
2️⃣ Is P2WPKH same as “Bech32”??
'Bitcoin' 카테고리의 다른 글
23.02.04 psbt input 타입 (0) | 2023.02.04 |
---|