In bitcoin core can ScriptToUniv give us wallet address of public key?

Free Bitcoins: FreeBitcoin | BonusBitcoin

Coins Kaufen: Bitcoin.deAnycoinDirektCoinbaseCoinMama (mit Kreditkarte)Paxfull

Handelsplätze / Börsen: Bitcoin.de | KuCoinBinanceBitMexBitpandaeToro

Lending / Zinsen erhalten: Celsius NetworkCoinlend (Bot)

Cloud Mining: HashflareGenesis MiningIQ Mining


a few days ago I created a PR https://github.com/bitcoin/bitcoin/pull/27546
where I proposed ScriptToUniv can give us wallet address of public key But some guy commented
“Concept NACK
Sorry, no. P2PK outputs do not have an address. It’s an outdated and confusing practice to refer to them as their corresponding P2PKH address”

as far as my understanding

see we have

private key –> secp256k1 — > public key –> sha256 –> RIPEMD160 –> Hashed Publickey –> hashed Publickey + checksum = wallet address

and we have the flow of ExtractDestination

PUBKEY –>passed to –> EXTRACT DESTINATION –>PKHash returned

PUBKEYHASH –>passed to –> EXTRACT DESTINATION –> PKHash returned

we pass this PKHash to EncodeDestination which passes it to DestinationEncoder which returns us the wallet address

https://github.com/bitcoin/bitcoin/blob/master/src/core_write.cpp#L165

can someone please guide me where I am getting it wrong ?

Source link

Free Bitcoins: FreeBitcoin | BonusBitcoin

Coins Kaufen: Bitcoin.deAnycoinDirektCoinbaseCoinMama (mit Kreditkarte)Paxfull

Handelsplätze / Börsen: Bitcoin.de | KuCoinBinanceBitMexBitpandaeToro

Lending / Zinsen erhalten: Celsius NetworkCoinlend (Bot)

Cloud Mining: HashflareGenesis MiningIQ Mining

By continuing to use the site, you agree to the use of cookies. more information

The cookie settings on this website are set to "allow cookies" to give you the best browsing experience possible. If you continue to use this website without changing your cookie settings or you click "Accept" below then you are consenting to this.

Close