$75 to fix "block decode failed" error

Edited on July 23: Since nobody has replied in a day, the reward for this answer has now increased to $75.

Hi,

Since the Overwinter upgrade, the Prohashing mining pool has seen three orphaned ZCash blocks. Unfortunately, the error doesn’t state at what index in the long hex string the block failed decoding, so I don’t know where to begin.

I’ll pay $75 to the first person who can determine why the following block, which is being submitted with “submitblock,” returns a “block decode failed” error.


0400000054e4a57df40228492e60278a6b67dc90009575e89d7ff3dc2f703cf07aeb0d00556569ec6d94551181cbed9fc0693423795a43d37734c62523bcfbe077a5f4da000000000000000000000000000000000000000000000000000000000000000041ea545b8dc50e1ff800000317020000000000000000000000000000000000000000000000000000fd400500641b293f5ebcafa0c912f527b174aa10b196a6a520c8b57db49f2ac76e8562bcb54ec138f5bb8aad1f0602723e8366537f60fe922d991820051036fa824f59f87ea075d8907b48e1f5f541e57569e24f7aceaa01ca32781bc7c74b6da3f0bb8a36d085908854168d19ec5b569d8fe64aef3ad4c08efb89b564d3dfb9bc0ad213fec48a1f81b8793349693e6dbaf520be47591361d737805d1548f57b3940967fadaa6aa1b5be540c1c0340fb5b5d3ae9a861c7c72381608c7b15c7fd1f320f27f4de7f6d9084539aac6842e274b23d54170c3d29e6cd450091aef1a4b5fa2d8c2f5b5fdd840e1cde53ba5916a0178dd6420645dea8a49d4530d03b0e35c7e9800a5490caa1113a56c9cf388fa1aa40562282a4ef41cf9768a41d2760a64af5f302b31c621612c782bd54a54e617047f8c865dafc8ec63fbb44a1181dddefab48b6ba9bd892220b26850923b43a893306a64dad1e04c9b9ad7315bfb67ed819db31d6654d303faca76264eecbd36fa3d672eefb59420479f40806bde54a141e5fa5d0da82917f462ad533b955b9c10f4384d88e7f5abffda9a2c8c3437465d5f4cfe03709fdbb7184838ffdc7f842c35dab1b653af99f07cf332dee87ef70790fb596e9d49bf379fadc6fbaba030d2525660de795d54465d85ddaea145f1b941ec73f406b1ad2595182a88e8674fd5b59be77d4e11ff051081754e18bd60fd8d61db259d31b2928f6973dc7e72b1c45a0fb5c4e77b0bca6acc0726b5671e2d471682fbc13473bcc1fff4147f30bbe9996668ee7552cc2347056c631d1c40d0fc7a464aaab535e2a0e3c059d0890c5750ec4faa6b88357fe37fd6e0e77661ba8673c1e630502633f0547f0483748d6e52bd8393fd43c2135cfee0e11abe5447d749503fc1c22d9073cd757389ef5318ae212a17d3a5521a9e3e6599322dab79000893689cb27f4c5684f32a40cab2b1d87a83ea8430a0bcce24fa3d2ffca9258c457da949f8d7bbd4c140980910ce46974757b3fd32ae4c8b878db72a9a8861381d8ae30d30c815ec422c69be59a12f7dbb883830888773b180785ed6247e1d4a7e15ce5a9e9b2128f1045a1011f608a9d4979786974eb164eb9311b788a2a4a3e393eaacaf3f08d773db9d544be9b75f8f7523da1f7bad1e341bf20660a9371dad7def105fb4bb409b475726ee415f5a4c943b28d6d8af5ccf0f8b674165a19cec412d9caeba905e8983e3351c61e35caae125567f87905143f885704b4bd64bae6408278db4816b6965fd5d08466e2f9a4903028d685d6e735f31d173367a3e6249285b916f3487dae00750d33dbae492f898d149a5ec89d8fabc3aa534be1e613b119abc72fcc8adc55181d46c3bf480f934b99ee8f5317c60542598f9043937604a4b7f6543ab81549e8efd555dd00bfe4bf01c5bf5e838360613f89a7547725491ed00c9af468d0e395a13c5002ce4bcc623daf43586db306d81a638249061d51bb7140923594f656761d5b951794ca9a6b6312b3bc9183c902e914f1a9f89ff07b1880420932d6d37ec556c6191d4e2a46c5cb9d49f141466e059aed6909b7e8ccefde7c1db35bc43d455223d65d4b33bc10f3ff5f0508623cd681a30dfa0cc12611339eff15d95ad5b2e73111f56ca20c31dec0c9041d5c281082e7f8c4e411c7939d8484f463b5a418328cb21d39ed2363bbb74367a51d24f68833549be10684350446064b90d24d11703ff8ed8cd57b7e2ad326620f19051dd93afbb98392351f9d1e6192b730bc08a864ddcd986c09731aa709e1bb4652cfe2fbf27e0cc27b265ac8f80cf3c1a304eae74d893edc4cc3741535acc225172235e52bf198f74b3e3e5f9f9343cd1de1d936ae4daf229a8c42e511ff4c010dbf3f2561010400008085202f89010000000000000000000000000000000000000000000000000000000000000000ffffffff09034c2e040002000000ffffffff0200ca9a3b000000001976a914aee92a7129e7f18506f7d5fb3bbec731c139c23888ac80b2e60e0000000017a9142a71f51b268f74eb3ee5631090589bbf6239bc0c870000000000000000


This block was submitted to the testnet using the new transaction format described in the Overwinter upgrade instructions. I figure that someone who is very knowledgeable with the ZCash codebase could probably run this through some parser, or even look at it quickly, and figure it out in a few minutes.

Payment will be made to the first person who can identify what index of this string is invalid and why it is invalid.

Thanks!

How did you generate the block in the first place? What software?

Our mining pool generated the block. I wrote the software.

I imagine that this shouldn’t be relevant to figuring out where the error is, though. Someone with knowledge of how blocks are serialized should be able to pick apart this block and see where there is a field that is too long or too short.

Got it. Our user support team was curious. We can try to poke around if there’s time but a few engineers are taking off this week so we’re lower resourced. At the very least, we’ll check back in next week.

It’s great someone is willing to help - thanks! We already lost $5200 due to this issue before it was caught, so any help you can provide is appreciated.

Filed ticket for this: Overwinter block fails deserialization when invoking rpc call `submitblock` · Issue #3412 · zcash/zcash · GitHub

1 Like

just naive observation - block head (first 1487 bytes) is fine and valid, while the tail should be 11 bytes longer.

as a wild guess, I suspect that this part of the transaction is missing:
zcash/transaction.h at master · zcash/zcash · GitHub

I wanted to post an update to say that I read the post in github about this issue and that I’m trying to figure out why the transaction is 11 bytes short. Adding the joinSplits fields did not solve the issue, unfortunately.