Running a slasher

This section provides instructions to run slasher to identify and report slashable offenses on the testnet. If slasher detects a slashable offense, proof is sent to the beacon-chain node for inclusion in a block. Validators earn a small whistleblower reward for including this proof into a block.

NOTICE: Running slasher is optional, but helps secure the chain and may result in additional earnings.

Slashable Offenses

Validator slashings

  • Double voting
    • occurs when a validator signs two different beacon blocks in the same epoch
  • Surround votes
    • occurs when a validator signs two conflicting attestations

Block Proposer slashings

  • occurs when a proposer broadcasts more then one block for the same slot

Prysm with Slasher

Get Prysm and start beacon-chain

NOTICE: If beacon-chain is already running, skip to step 2

  1. To begin, follow the instructions for GNU\Linux, macOS, ARM64, or Windows to fetch and install Prysm. The beacon-chain process should be running and fully synced before proceeding.

Run Slasher

  1. Depending on your platform, issue the appropriate command alongside any startup parameters from the examples below to start slasher.

Running slasher with prysm.bat on Windows

.\prysm.bat slasher

Running slasher with prysm.sh on GNU\Linux, macOS, and ARM64

./prysm.sh slasher

Running slasher with Docker on GNU\Linux, and macOS

docker pull gcr.io/prysmaticlabs/prysm/slasher:latest
docker run -it --network="host" -v $HOME/.eth2:/data --name slasher \
gcr.io/prysmaticlabs/prysm/slasher:latest \
--datadir=/data

Running slasher with Docker on Windows

docker pull gcr.io/prysmaticlabs/prysm/slasher:latest
docker run -it --network="host" -v c:/prysm:/data gcr.io/prysmaticlabs/prysm/slasher:latest

Running slasher with Bazel on GNU\Linux, macOS, and ARM64

bazel run //slasher
  1. Slasher will spin up and immediately begin communicating with the beacon-chain process.

Congratulations, you are now ready to identify and report slashable attestations and block proposals

Still have questions? Stop by our Discord for further assistance!