Proof of Stake in Ethereum

·

1. Proof of Stake (PoS) Overview

1.1 What Is PoS?

Proof of Stake (PoS) is a consensus mechanism enabling decentralized agreement on blockchain state transitions. Validators stake ETH into a smart contract and verify new blocks—ensuring legitimacy—while occasionally proposing blocks themselves. Dishonest or inactive validators face penalties ("slashing").

1.2 Validators

To become a validator:

Ethereum time is divided into:

Each slot randomly selects:

1.3 Transaction Execution Flow

  1. User Signs Transaction: Includes a tip for validators.
  2. Submission: Sent to an execution client for legality checks.
  3. Broadcast: Valid transactions enter the mempool and propagate network-wide.
  4. Block Creation:

    • The elected proposer packages transactions into an execution payload.
    • The consensus client wraps this into a beacon block (includes rewards, penalties, attestations).
  5. Validation: Other nodes re-execute transactions to verify state changes.
  6. Finalization: A transaction becomes irreversible after inclusion in two checkpoints (≥66% validator approval).

1.4 Finality

A checkpoint pair achieves finality when:

1.5 Cryptographic Security

Validators earn rewards for honest participation but face:

1.6 Fork Choice

Conflicting blocks trigger the LMD-GHOST algorithm, favoring the fork with the heaviest validator attestation weight.

1.7 PoS vs. PoW Security

While 51% attacks remain possible, PoS enhances resilience:


2. Gasper: Ethereum’s Consensus Engine

Gasper combines:

2.1 Finality Mechanics

  1. Justification: Checkpoint with 2/3 votes.
  2. Finalization: Two consecutive justified checkpoints.

2.2 Rewards and Penalties

| Action | Reward/Penalty |
|---------------------------|---------------------------------------------|
| Honest Attestation | 7/8 × base_reward |
| Block Proposal | Extra 8/64 × base_reward |
| Slashing | Destroy up to 1 ETH + correlation penalties |
| Inactivity | Gradual balance depletion |

2.3 Inactivity Leak

Activates if finality stalls >4 epochs, draining inactive validators’ stakes until <1/3 remain.


3. Weak Subjectivity

3.1 Key Concepts

3.2 Attack Mitigation


4. Validator Lifecycle

4.1 Attestation Process

  1. Create: Votes on source/target checkpoints and head block.
  2. Broadcast: Signed attestations propagate via gossip.
  3. Aggregate: Committees combine signatures for efficiency.
  4. Include: Added to beacon blocks.

4.2 Rewards Calculation

attestation_reward = (7/8) × base_reward × (1/inclusion_delay)  

5. Attacks and Defenses

5.1 Attack Vectors

| Attack | Min Stake Required | Impact |
|---------------------------|------------------------|--------------------------------|
| Reorg | 2% | Short-chain reorganization |
| Balancing Attack | 7% | Fork stalemate |
| Finality Delay | 33% | Chain halt |
| 51% Attack | 51% | Censorship/chain control |

5.2 Community Safeguards

Social coordination ("Layer 0") remains critical for resolving extreme scenarios (e.g., double finality).


6. FAQ

Q: How does PoS differ from PoW in wealth distribution?

A: PoS rewards are linear (fixed % ROI), unlike PoW’s economies of scale favoring large miners.

Q: Can validators be slashed for offline periods?

A: Minor penalties apply, but slashing occurs only for provable malice (e.g., double voting).

Q: What’s the role of execution clients?

A: They process transactions, while consensus clients manage validator coordination.

👉 Learn more about Ethereum staking