Skip to content
This repository was archived by the owner on Jan 22, 2025. It is now read-only.

Add snapshot account state verify proposal#8043

Closed
sakridge wants to merge 1 commit intosolana-labs:masterfrom
sakridge:snapshot-accumulator-proposal
Closed

Add snapshot account state verify proposal#8043
sakridge wants to merge 1 commit intosolana-labs:masterfrom
sakridge:snapshot-accumulator-proposal

Conversation

@sakridge
Copy link
Copy Markdown
Contributor

Problem

xor method of rolling up hashes of live account states is too easily attacked by probabilistic collision.

Summary of Changes

Add proposal to add account states to two sets of accumulators to be able to validate the account set in a snapshot matches what is on the network.

Fixes #

@sakridge sakridge force-pushed the snapshot-accumulator-proposal branch from a807e57 to 0256346 Compare January 30, 2020 21:16
Comment thread book/src/proposals/snapshot-verification.md Outdated
Comment thread book/src/proposals/snapshot-verification.md
@sakridge sakridge force-pushed the snapshot-accumulator-proposal branch from 0256346 to cd69a9d Compare January 31, 2020 02:02
Copy link
Copy Markdown
Contributor

@t-nelson t-nelson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a couple nits here. LGTM otherwise!

Also mind linking to references at the end? Presumably at least https://eprint.iacr.org/2018/1188.pdf

## Problem

Snapshot verification of the account states is implemented, but the bank hash of the snapshot which is used to verify is falsifiable.
When a validator boots up from a snapshot, it needs a way to verify the account set matches what the rest of the network sees quickly. A potential
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: wrap at 80

That hash is added to an RSA accumulator in standard `g^(hash) mod n` way.

Since adding to an accumulator is a single-threaded process, multiple accumulators can
be used to obtain parallelism for the entire account set in the slot. They can be indexed some
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: "indexed by some"

* Account data
* Account pubkey
* Account lamports balance
* Fork the account is stored on
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nits: Slot (rename remnant?)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nits: Also these days, hash includes rent_epoch and executable #7415

@stale
Copy link
Copy Markdown

stale Bot commented Feb 11, 2020

This pull request has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs.

@stale stale Bot added the stale [bot only] Added to stale content; results in auto-close after a week. label Feb 11, 2020
@stale
Copy link
Copy Markdown

stale Bot commented Feb 18, 2020

This stale pull request has been automatically closed. Thank you for your contributions.

@stale stale Bot closed this Feb 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

stale [bot only] Added to stale content; results in auto-close after a week.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants