Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8856609
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T14:23:39+00:00 2026-06-14T14:23:39+00:00

I was reading on Wikipedia about hash trees , and I don’t understand the

  • 0

I was reading on Wikipedia about hash trees, and I don’t understand the benefits or purposes of this structure – they seem to require more hashes than just one per leaf with no significant use of the extra hashes.

For example, the use case on wikipedia is that they are used to validate data received in a P2P system. But why is this better than having a one-to-one mapping of blocks numbers and their hashes, without having the tree structure?

Could someone please explain how and why hash trees are useful?

Thanks in advance,

Moshe

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T14:23:41+00:00Added an answer on June 14, 2026 at 2:23 pm
    1. Hash trees can be computed in parallel. If you have two blocks of data to hash, you can use two processors to compute the hash twice as fast. This only works if your hash speed is lower than your IO speed, which is unlikely.

    2. Hash trees can be computed from hashes of individual blocks, or from hashes of larger sections that are aligned correctly. This is important.

    For example, if I want to send you a file, I can break it up into chunks of 1 MiB and send you each chunk with its SHA-256 hash. If the hash for any of the individual chunks is incorrect, then you can ask for that chunk again. At the end, I can sign the tree hash for the file and send you the signed hash. You can verify the hash just by hashing each of the block hashes (which you already verified), which is a lot faster than rehashing the entire file.

    Why use a tree hash?

    A tree hash is advantageous any time that you want to compute the hash of both a portion of a file and the entire file. Using a regular hash like SHA-256, you will have to hash the file chunk and the entire file separately. If the file is 8 GiB, this might take quite some time. With a tree hash, because the hash of the chunk is used to compute the hash of the file, it takes no extra work to compute both hashes.

    How much extra work is a tree hash?

    The “extra work” for computing a tree hash is actually minimal. Yes, it does require computing extra hashes — but only O(1) extra work. If your block size is 1 MiB, then the extra work is approximately zero if your file is 1 MiB or smaller. As the data size increases, the amount of extra work will approach 1 extra hash of two hashes for every block of data — for SHA-256, the core will only be evaluated two extra times per 1 MiB of data at most (once for the input hashes, once for the padding). That’s not very much.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Reading about Http Post on Wikipedia it states that This is a format for
So, I was reading about clipping in this Wikipedia article. It seems pretty essential
I was reading about parsers and parser generators and found this statement in wikipedia's
I was reading a Wikipedia article about Java EE application servers here: http://en.wikipedia.org/wiki/Java_Platform,_Enterprise_Edition#Java_EE_5_certified It
I've been reading up on covariance and contravariance - Wikipedia talks about the following:
I was just reading a bit about the HQ9+ programming language: https://esolangs.org/wiki/HQ9+ , https://en.wikipedia.org/wiki/HQ9+
I'm reading wiki about the singleton pattern and I'm not sure if I understand
I am reading some papers about Genetic Algorithms and often they mention Evolutionary Algorithms
So I'm reading up about hash tables, hash functions etc. I was intrigued to
I was around Wikipedia reading about a programming language called 'D' , it is

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.