System Contracts

System contracts are designed to meet the internal needs of the network and enhance its security, e.g. through mechanisms like staking and slashing. All system contracts are deployed on mainchain, i.e. Polygon. The following are the key system contracts:

DKG (Distributed Key Generation) Contract

The Nerif Network utilizes a distributed key generation procedure to create a common shared secret among all validators. The implementation of DKG within the network requires on-chain logic for full decentralization.

This logic is implemented in the DKG smart contract, which is used during the DKG process.

Additionally, the DKG contract implements the SignerStorage interface to store the collective network address generated through the DKG process:

  • Distributed key derivation is used in the interactive process involving N parties to generate secret keys and a single public key

  • Valid signatures can be produced through an interactive process involving any T parties.

  • The DKG contract employs secret sharing, additively homomorphic encryption, and zero-knowledge proofs to achieve trustlessness.

Staking Contract

The staking contract implements the necessary logic for validators to stake tokens and join the network. Validators are required to store a certain amount of tokens (N tokens), configured per network within the contract, to become network participants. The staking contract governs this process.

Slashing Contract

The Nerif Network includes slashing protection functionality, which addresses malicious validators using smart contracts. The slashing contract handles the necessary mechanisms to penalize or slash tokens from validators engaging in malicious activities.

RewardDistributionPool Contract

The reward distribution pool contract implements the logic for proper rewards distribution.

Last updated