1

Is it possible to add a new header to ethereums block header without messing up go-ethereums core too much.. im looking at the block.go file specifically at this part... see the custom super header i have added I. Ive also added this new field to the genesis file but when syncing i get that the signer is unauthorized to do so. anyone have experience with doing this kind of heavy modification ?

    type Header struct {
        ParentHash      common.Hash    `json:"parentHash"       gencodec:"required"`
        UncleHash       common.Hash    `json:"sha3Uncles"       gencodec:"required"`
        Coinbase        common.Address `json:"miner"            gencodec:"required"`
        Root            common.Hash    `json:"stateRoot"        gencodec:"required"`
        TxHash          common.Hash    `json:"transactionsRoot" gencodec:"required"`
        ReceiptHash     common.Hash    `json:"receiptsRoot"     gencodec:"required"`
        Bloom           Bloom          `json:"logsBloom"        gencodec:"required"`
        Difficulty      *big.Int       `json:"difficulty"       gencodec:"required"`
        Number          *big.Int       `json:"number"           gencodec:"required"`
        GasLimit        uint64         `json:"gasLimit"         gencodec:"required"`
        GasUsed         uint64         `json:"gasUsed"          gencodec:"required"`
        Time            *big.Int       `json:"timestamp"        gencodec:"required"`
        Extra           []byte         `json:"extraData"        gencodec:"required"`
        MixDigest       common.Hash    `json:"mixHash"          gencodec:"required"`
        Nonce           BlockNonce     `json:"nonce"            gencodec:"required"`
        SuperCustomData []byte         `json:"superCustomData"        gencodec:"required"`
    }

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.