Crypto Flexs
  • DIRECTORY
  • CRYPTO
    • ETHEREUM
    • BITCOIN
    • ALTCOIN
  • BLOCKCHAIN
  • EXCHANGE
  • TRADING
  • SUBMIT
Crypto Flexs
  • DIRECTORY
  • CRYPTO
    • ETHEREUM
    • BITCOIN
    • ALTCOIN
  • BLOCKCHAIN
  • EXCHANGE
  • TRADING
  • SUBMIT
Crypto Flexs
Home»BITCOIN NEWS»bitcoin core – How do miners generate multiple outputs on a coinbase transaction?
BITCOIN NEWS

bitcoin core – How do miners generate multiple outputs on a coinbase transaction?

By Crypto FlexsSeptember 9, 20241 Min Read
Facebook Twitter Pinterest LinkedIn Tumblr Email
bitcoin core – How do miners generate multiple outputs on a coinbase transaction?
Share
Facebook Twitter LinkedIn Pinterest Email

Bitcoin Core hardcodes the Coinbase transaction as a single output. coinbaseTx.vout.resize(1) By definition src/node/miner.cpp

     // Create coinbase transaction.
    CMutableTransaction coinbaseTx;
    coinbaseTx.vin.resize(1);
    coinbaseTx.vin(0).prevout.SetNull();

****************************************************
//Referring to the line of code below 
    coinbaseTx.vout.resize(1);

*****************************************************
    coinbaseTx.vout(0).scriptPubKey = scriptPubKeyIn;
    coinbaseTx.vout(0).nValue = nFees + GetBlockSubsidy(nHeight, chainparams.GetConsensus());
    coinbaseTx.vin(0).scriptSig = CScript() << nHeight << OP_0;
    pblock->vtx(0) = MakeTransactionRef(std::move(coinbaseTx));
    pblocktemplate->vchCoinbaseCommitment = m_chainstate.m_chainman.GenerateCoinbaseCommitment(*pblock, pindexPrev);
    pblocktemplate->vTxFees(0) = -nFees;

    LogPrintf("CreateNewBlock(): block weight: %u txs: %u fees: %ld sigops %d\n", GetBlockWeight(*pblock), nBlockTx, nFees, nBlockSigOpsCost);

However, in the recent block 860062, the mining pool paid several remote miners directly in a coin-based transaction: https://mempool.space/tx/aff7c9b18666c0a51c66013642e24bfcb8b721a674e0f4ce3afa3004b55b0156

How does a miner create a coinbase transaction that overrides the defaults specified in the above Bitcoin Core code snippet?

Share. Facebook Twitter Pinterest LinkedIn Tumblr Email

Related Posts

BTC price could be range-bound to $60,000-$80,000 pending a rate cut.

November 20, 2025

Bearish Administration: Let’s take a look at how the Bitcoin price has changed since Donald Trump became President.

November 14, 2025

Is Bitcoin price bottoming? The latest on-chain data suggests:

November 8, 2025
Add A Comment

Comments are closed.

Recent Posts

CreatorFi Launches On Aptos With $2M Strategic Backing To Scale Stablecoin Credit For Creators

November 25, 2025

Bybit Lowers Barrier To Elite Wealth Management Solutions With Year-End Exclusive For VIP Clients

November 25, 2025

TrustLinq Launches Swiss-Regulated Crypto-to-Fiat Payment Platform To Boost Cryptocurrency Adoption

November 25, 2025

Bitcoin Is Dropping—but Your Income Doesn’t Have To. Earn Up To $5,927 Per Day Safely With 8 Hours Cloud Mining.

November 25, 2025

BitMine has released 3.6 million ETH, but investors question the math.

November 25, 2025

The Shai Hulud malware has hit NPM as cryptocurrency libraries face a growing security crisis.

November 24, 2025

Wallet In Telegram Lists Monad, Enabling Telegram TGE Trading & Expanding MON Distribution

November 24, 2025

Wallet In Telegram Lists Monad, Enabling Telegram TGE Trading & Expanding MON Distribution

November 24, 2025

MEXC’s ENA Extravaganza Concludes With 51,000+ Participants And $79.7 Billion In Trading Volume

November 24, 2025

Solicoin (Soli) is now available for presale! 🎉

November 24, 2025

Chainlink is the ‘critical connective tissue’ for tokenization

November 24, 2025

Crypto Flexs is a Professional Cryptocurrency News Platform. Here we will provide you only interesting content, which you will like very much. We’re dedicated to providing you the best of Cryptocurrency. We hope you enjoy our Cryptocurrency News as much as we enjoy offering them to you.

Contact Us : Partner(@)Cryptoflexs.com

Top Insights

CreatorFi Launches On Aptos With $2M Strategic Backing To Scale Stablecoin Credit For Creators

November 25, 2025

Bybit Lowers Barrier To Elite Wealth Management Solutions With Year-End Exclusive For VIP Clients

November 25, 2025

TrustLinq Launches Swiss-Regulated Crypto-to-Fiat Payment Platform To Boost Cryptocurrency Adoption

November 25, 2025
Most Popular

Is altcoin season here? Bitcoin dominance and market trend analysis

November 27, 2024

LibMiner: A container-based cryptocurrency miner targeting unsecured Redis servers.

November 24, 2023

Top Trending Cryptocurrencies on DEXTools – AIT Protocol, Satellite Doge-1, dogwifhat

December 25, 2023
  • Home
  • About Us
  • Contact Us
  • Disclaimer
  • Privacy Policy
  • Terms and Conditions
© 2025 Crypto Flexs

Type above and press Enter to search. Press Esc to cancel.