This repository was archived by the owner on Dec 23, 2021. It is now read-only.
add verifying a merkle tree#29
Open
ZhouHansen wants to merge 1 commit intodat-ecosystem-archive:masterfrom
Open
add verifying a merkle tree#29ZhouHansen wants to merge 1 commit intodat-ecosystem-archive:masterfrom
ZhouHansen wants to merge 1 commit intodat-ecosystem-archive:masterfrom
Conversation
| 6: G | ||
| 7: H | ||
| ``` | ||
| Now, Alice wants to recieve and verify the data `D`, to accomplish this, then she need to recieve: (marked with `~`) |
There was a problem hiding this comment.
Suggested change
| Now, Alice wants to recieve and verify the data `D`, to accomplish this, then she need to recieve: (marked with `~`) | |
| Now, Alice wants to recieve and verify the data `D`. To accomplish this she needs to recieve: (marked with `~`) |
| ``` | ||
|
|
||
| We will first verify the signature on hash #7: `verify(#7, signature, publickey)`, | ||
| then we verify the chunk 3: |
There was a problem hiding this comment.
Suggested change
| then we verify the chunk 3: | |
| then we verify chunk 3 |
| 2. hash #6 and recieved #4: #5 = hash(#6 + #4) | ||
| 3. hash #5 and recieved #1: #3 = hash(#1 + #5) | ||
| 4. hash #3 and recieved #11: #7 = hash(#3 + #11) | ||
| 5. if our calculated #7 is equal to our received signed #7, then we know the chunk3 we received is valid. |
There was a problem hiding this comment.
Suggested change
| 5. if our calculated #7 is equal to our received signed #7, then we know the chunk3 we received is valid. | |
| 5. if our calculated #7 is equal to our received signed #7, then we know the chunk #3 we received is valid. |
yoshuawuyts
reviewed
Jul 26, 2019
| 6: G | ||
| 7: H | ||
| ``` | ||
| Now, Alice wants to recieve and verify the data `D`, to accomplish this, then she need to recieve: (marked with `~`) |
Contributor
There was a problem hiding this comment.
Suggested change
| Now, Alice wants to recieve and verify the data `D`, to accomplish this, then she need to recieve: (marked with `~`) | |
| Now, Alice wants to receive and verify the data `D`, to accomplish this, then she need to receive: (marked with `~`) |
Contributor
|
@ZhouHansen this makes a lot of sense; thanks for writing! |
Author
|
I only know a little bit of verifying a merkle tree. I want to know how bitfield works with merkle tree, but found no doc. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🔦 documentation change
Add how to verify a merkle tree to
ch01-02-merkle-tree.mdChecklist
Context
No
Semver Changes
a patch