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

AI pivots won’t save you. Wintermute speaks to Bitcoin miners:

March 14, 2026

Startup StarCloud Plans First Bitcoin Mining Satellite in Low Earth Orbit

March 8, 2026

Are Investors Abandoning BTC?

March 2, 2026
Add A Comment

Comments are closed.

Recent Posts

MetaWinners Community Launches $METAWIN Token Presale

March 19, 2026

Pi Network weathers cryptocurrency market crash as major mainnet upgrade fuels hype

March 19, 2026

Phemex Astral Trading League Launches $450,000 Pisces Season

March 19, 2026

Ethereum is gaining ground over Bitcoin amid the escalating US-Iran war.

March 19, 2026

Cango Inc. Reports Fourth Quarter And Full Year 2025 Unaudited Financial Results

March 19, 2026

Leonardo AI unveils comprehensive image editing suite with six model options

March 19, 2026

RWA increases by 8% in 30 days – is it more than just a ‘safe’ bet?

March 19, 2026

Bitmine Immersion Technologies (BMNR) Announces ETH Holdings Reach 4.596 Million Tokens, And Total Crypto And Total Cash Holdings Of $11.5 Billion

March 19, 2026

Bank of Korea begins phase 2 of digital won pilot project including real subsidies

March 19, 2026

Vault12 Guard 2.8 provides real-time portfolio balance for cryptocurrency inheritance

March 18, 2026

Aster Expands WLFI Collaboration, Launches USD1-Denominated Perpetual Markets

March 18, 2026

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

MetaWinners Community Launches $METAWIN Token Presale

March 19, 2026

Pi Network weathers cryptocurrency market crash as major mainnet upgrade fuels hype

March 19, 2026

Phemex Astral Trading League Launches $450,000 Pisces Season

March 19, 2026
Most Popular

Bitcoin at 15: The Enduring Resilience of Peer-to-Peer Electronic Cash

November 29, 2023

What is Polkadot (DOT) Bridge?

June 24, 2024

Is Ethereum Market Bottoming? Price indicators point to a $5K target

June 28, 2024
  • Home
  • About Us
  • Contact Us
  • Disclaimer
  • Privacy Policy
  • Terms and Conditions
© 2026 Crypto Flexs

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