HackMD
    • Sharing Link copied
    • /edit
    • View mode
      • Edit mode
      • View mode
      • Book mode
      • Slide mode
      Edit mode View mode Book mode Slide mode
    • Note Permission
    • Read
      • Only me
      • Signed-in users
      • Everyone
      Only me Signed-in users Everyone
    • Write
      • Only me
      • Signed-in users
      • Everyone
      Only me Signed-in users Everyone
    • More (Comment, Invitee)
    • Publishing
    • Commenting Enable
      Disabled Forbidden Owners Signed-in users Everyone
    • Permission
      • Forbidden
      • Owners
      • Signed-in users
      • Everyone
    • Invitee
    • No invitee
    • Options
    • Versions and GitHub Sync
    • Transfer ownership
    • Delete this note
    • Template
    • Save as template
    • Insert from template
    • Export
    • Google Drive Export to Google Drive
    • Gist
    • Import
    • Google Drive Import from Google Drive
    • Gist
    • Clipboard
    • Download
    • Markdown
    • HTML
    • Raw HTML
Menu Sharing Help
Menu
Options
Versions and GitHub Sync Transfer ownership Delete this note
Export
Google Drive Export to Google Drive Gist
Import
Google Drive Import from Google Drive Gist Clipboard
Download
Markdown HTML Raw HTML
Back
Sharing
Sharing Link copied
/edit
View mode
  • Edit mode
  • View mode
  • Book mode
  • Slide mode
Edit mode View mode Book mode Slide mode
Note Permission
Read
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
Write
Only me
  • Only me
  • Signed-in users
  • Everyone
Only me Signed-in users Everyone
More (Comment, Invitee)
Publishing
More (Comment, Invitee)
Commenting Enable
Disabled Forbidden Owners Signed-in users Everyone
Permission
Owners
  • Forbidden
  • Owners
  • Signed-in users
  • Everyone
Invitee
No invitee
   owned this note    owned this note      
Published Linked with GitHub
Like BookmarkBookmarked
Subscribed
  • Any changes
    Be notified of any changes
  • Mention me
    Be notified of mention me
  • Unsubscribe
Subscribe
# FFG+GHOST filtering "viable" branches Yan recently pointed out a potential issue with FFG+GHOST as previously specified. The issues lies in the difference between (a) a branch of the tree that has the latest justified block in it __vs__ (b) a branch of the tree that _sees_ the latest justified block as justified. If validators are to use the state at the head of the fork choice to cast their votes, they must only consider branches that have the latest justification/finalization info correctly in the state. If they consider _all_ branches that include the latest justified block, some such branches might induce voting on out-of-date/incorrect information. WIP implementation of fix in spec repo: https://github.com/ethereum/eth2.0-specs/pull/1495 ## Scenario The following is an attack scenario that can break liveness, but there are less explicitly nefarious scenarios that also lead to poor outcomes. _Setup_ * There is some ancestor block A * Then B, child of A, is created * Then C1, child of B, gets created, and B gets justified via the inclusion of votes A->B (2/3 of validators) in C1 * A few validators attest B -> C1, but C1 does not get justified _Attack_ * B<-C2<-D2 get created as a separate chain, but does NOT include enough votes to justify B * \>1/6 of validators defect to this new chain, voting on A->C2 along with 1/3 of honest validators that didn't vote on A->B * Honest validators from the other chain now see D2 as head. If they use the state of D2 as the info to cast vote, it would suggest A->D2 which surrounds B->C1. Such a vote is slashable and thus this type of scenario can break plausible liveness. ## Fix When running the fork choice, filter out branches that do not contain correct latest justified in head state. So, with the new fork choice in the above scenario, the honest validators see C1 as head and cannot be convinced by minority attacker to switch. ## Argument for why fix doesn't break other things The fix only affects the fork choice, and the fix can only change the fork choice in unexpected cases, and only when the client discovers a new block that contains evidence justifying a new block. This general class of situation already exists. For example, a weird situation that this fix would enable is if A is 65% justified and a chain built off of A through B1 gets built, but then an attacker publishes another 2%, completing the justification, along with a new block B2. However, a parallel situation now exists, where if B1 gets to 65% justification but then a chain built on B2 starts winning, and suddenly the attacker publishes the last remaining 2% fully justifying B1. ## Review by Ryuya TL;DR: The fix seems reasonable. Rationale: This issue is because Casper FFG adopts the locking paradigm of BFT in chain-based consensus, i.e., unlike Tendermint or Hotstuff, blocks which could not collect the 2f + 1 votes for the previous checkpoint (C2 and D2 in the document) continue to exist in the chain, rather than being discarded. ("Chain-based BFT" is a much more ambitious than the "chained/pipelined BFT" in academic papers.) From this point of view, the proposed fix seems a straightforward way to re-define the locking/unlocking rule into chain-based BFT. Unlocking rules exist to force validators to vote on the highest justified checkpoint to synchronize them, so in FFG, the unlocking rule (= definition of the start point of the fork-choice) should not count a chain (C2's chain) which does not allow validators vote on the highest justified checkpoint. I think this fix is compatible with the fix on the bouncing attack, which does not make use of the inconsistency of locking/unlocking.

Import from clipboard

Advanced permission required

Your current role can only read. Ask the system administrator to acquire write and comment permission.

This team is disabled

Sorry, this team is disabled. You can't edit this note.

This note is locked

Sorry, only owner can edit this note.

Reach the limit

Sorry, you've reached the max length this note can be.
Please reduce the content or divide it to more notes, thank you!

Import from Gist

Import from Snippet

or

Export to Snippet

Are you sure?

Do you really want to delete this note?
All users will lost their connection.

Create a note from template

Create a note from template

Oops...
This template has been removed or transferred.


Upgrade

All
  • All
  • Team
No template.

Create a template


Upgrade

Delete template

Do you really want to delete this template?

This page need refresh

You have an incompatible client version.
Refresh to update.
New version available!
See releases notes here
Refresh to enjoy new features.
Your user state has changed.
Refresh to load new user state.

Sign in

Sign in via SAML

or

Sign in via GitHub

Help

  • English
  • 中文
  • 日本語

Documents

Tutorials

Book Mode Tutorial

Slide Example

YAML Metadata

Resources

Releases

Blog

Policy

Terms

Privacy

Cheatsheet

Syntax Example Reference
# Header Header 基本排版
- Unordered List
  • Unordered List
1. Ordered List
  1. Ordered List
- [ ] Todo List
  • Todo List
> Blockquote
Blockquote
**Bold font** Bold font
*Italics font* Italics font
~~Strikethrough~~ Strikethrough
19^th^ 19th
H~2~O H2O
++Inserted text++ Inserted text
==Marked text== Marked text
[link text](https:// "title") Link
![image alt](https:// "title") Image
`Code` Code 在筆記中貼入程式碼
```javascript
var i = 0;
```
var i = 0;
:smile: :smile: Emoji list
{%youtube youtube_id %} Externals
$L^aT_eX$ LaTeX
:::info
This is a alert area.
:::

This is a alert area.

Versions

Versions and GitHub Sync

Sign in to link this note to GitHub Learn more
This note is not linked with GitHub Learn more
 
Add badge Pull Push GitHub Link Settings
Upgrade now

Version named by    

More Less
  • Edit
  • Delete

Note content is identical to the latest version.
Compare with
    Choose a version
    No search result
    Version not found

Feedback

Submission failed, please try again

Thanks for your support.

On a scale of 0-10, how likely is it that you would recommend HackMD to your friends, family or business associates?

Please give us some advice and help us improve HackMD.

 

Thanks for your feedback

Remove version name

Do you want to remove this version name and description?

Transfer ownership

Transfer to
    Warning: is a public team. If you transfer note to this team, everyone on the web can find and read this note.

      Link with GitHub

      Please authorize HackMD on GitHub

      Please sign in to GitHub and install the HackMD app on your GitHub repo. Learn more

       Sign in to GitHub

      HackMD links with GitHub through a GitHub App. You can choose which repo to install our App.

      Push the note to GitHub Push to GitHub Pull a file from GitHub

        Authorize again
       

      Choose which file to push to

      Select repo
      Refresh Authorize more repos
      Select branch
      Select file
      Select branch
      Choose version(s) to push
      • Save a new version and push
      • Choose from existing versions
      Available push count

      Upgrade

      Pull from GitHub

       
      File from GitHub
      File from HackMD

      GitHub Link Settings

      File linked

      Linked by
      File path
      Last synced branch
      Available push count

      Upgrade

      Danger Zone

      Unlink
      You will no longer receive notification when GitHub file changes after unlink.

      Syncing

      Push failed

      Push successfully