snapshot
Blog
  • Welcome to Snapshot docs
  • User guides
    • Spaces
      • What is a space?
      • Create a space
        • Register an ENS domain
        • Alternative way to create a space
      • Settings
      • Sub-spaces
      • Space verification
      • Space hibernation
      • Add a custom domain
      • Add a skin
      • Space roles
      • Space badges
      • Snapshot Pro
      • Space handbook
        • Most common
        • Voting threshold
        • Anti-whale
        • Sybil resistance, scam & spam prevention
        • Liquidity / staking pool
        • Delegation
        • NFT voting
          • Most common: ERC-721
          • Multi-token: ERC-1155
          • POAP - Proof of Attendance
        • Custom calculations
    • Create a proposal
    • Voting
      • Vote on a proposal
      • Delegate your voting power
    • Voting strategies
    • Validation strategies
    • Using Safe multi-sig
    • Delegation
  • Developer Guides
    • Create a voting strategy
    • Create a validation strategy
    • Identify integrator activity
    • Add a network
  • Tools
    • Tools overview
    • Snapshot.js
    • API
      • API Keys
    • Webhooks
    • Subgraphs
    • Mobile notifications
    • Bots
  • Snapshot X
    • Overview
    • User guides
      • Create a space
      • Proposals
      • Voting
      • Safe execution setup
    • Protocol
      • Overview
      • Space actions
      • Space controller actions
      • Authenticators
      • Proposal validations
      • Voting strategies
      • Starknet specifics
      • Execution strategies
      • Audits
    • Services
      • Architecture
      • API
      • SX.js
      • UI
      • Mana
  • V1 interface
    • Email notifications
    • Plugins
      • What is a plugin?
      • Create a plugin
      • oSnap
      • SafeSnap
      • POAP
      • Quorum
      • Domino notifications
      • Galxe
    • Boost
  • Community
    • Help center
    • Discord
    • X (Twitter)
    • GitHub
Powered by GitBook
On this page
  • Ethereum signature authenticator
  • Ethereum transaction authenticator
  • And more!

Was this helpful?

Edit on GitHub
Export as PDF
  1. Snapshot X
  2. Protocol

Authenticators

PreviousSpace controller actionsNextProposal validations

Last updated 6 months ago

Was this helpful?

Authenticators are the contracts in charge of authenticating users to create proposals and cast votes.

All proposal creation, proposal update, and vote transactions must be sent to the relevant DAO's space contract via an authenticator.

DAOs are free to write their own custom authenticators that suit their own needs however we provide the following approaches:

Ethereum signature authenticator

Will authenticate a user based on a message signed by an Ethereum private key. Users create an EIP712 signature for the transaction which is checked for validity in this contract.

function authenticate(
    uint8 v,
    bytes32 r,
    bytes32 s,
    uint256 salt,
    address target,
    bytes4 functionSelector,
    bytes calldata data
) external;
  • v,r,s: ECDSA Signature

  • salt : The salt used in the signature to prevention replays (only required for proposal creation and updating).

  • target: The destination space contract.

  • functionSelector: The function selector of the desired action.

  • data: The ABI encoded transaction payload for the action. Refer to the section for more information on the payload contents.

This can work in conjunction with a meta transaction relayer to allow proposal creation or vote costs to be sponsored by the DAO, providing a free end user experience.

Ethereum transaction authenticator

Will authenticate a user by checking if the caller address corresponds to the author or voter address.

function authenticate(address target, bytes4 functionSelector, bytes calldata data) external;
  • target: The destination space contract.

  • functionSelector: The function selector of the desired action.

The core use case for this authenticator is to allow smart contract accounts such as multi-sigs to use Snapshot X as they have no way to generate a signature and therefore cannot authenticate via signature verification.

And more!

Our modular approach here allows spaces to authenticate users via other authentication methods without any changes to the space contract.

data: The ABI encoded transaction payload for the action. Refer to the section for more information on the payload contents.

Please note, that if you wanted to add sybil resistance to your governance process, this should not be handled by Authenticators, but by or .

Space actions
Space actions
Proposal validations
Voting strategies