Skip to content

Commit

Permalink
New page for offenses and slashes (#5878)
Browse files Browse the repository at this point in the history
* new page

* moved content

- added links to new page
- added new page to sidebar

* edits

* banners and reorg content

* reorg content

- moved content to new page
- redirect
- rm duplicated content
- keywords

* edits

* Update docs/learn/learn-comparison-rollups.md

Co-authored-by: Maciej <[email protected]>

* Update docs/learn/learn-offenses.md

Co-authored-by: Maciej <[email protected]>

* Update docs/learn/learn-offenses.md

Co-authored-by: Maciej <[email protected]>

* Update docs/learn/learn-offenses.md

Co-authored-by: Maciej <[email protected]>

* Update docs/learn/learn-offenses.md

Co-authored-by: Maciej <[email protected]>

* Update docs/learn/learn-staking.md

Co-authored-by: Maciej <[email protected]>

* Update docs/learn/learn-staking.md

Co-authored-by: Maciej <[email protected]>

* Update docs/learn/learn-parachains-protocol.md

Co-authored-by: Maciej <[email protected]>

* Update docs/learn/learn-offenses.md

Co-authored-by: Maciej <[email protected]>

* Update docs/learn/learn-offenses.md

Co-authored-by: Maciej <[email protected]>

* Update docs/learn/learn-offenses.md

Co-authored-by: Maciej <[email protected]>

* Update docs/learn/learn-offenses.md

Co-authored-by: Maciej <[email protected]>

* Update docs/learn/learn-offenses.md

Co-authored-by: Maciej <[email protected]>

* Update docs/learn/learn-offenses.md

Co-authored-by: Maciej <[email protected]>

* Update docs/learn/learn-offenses.md

Co-authored-by: Maciej <[email protected]>

* fix broken link

* Maciej feedback

* Update docs/learn/learn-offenses.md

Co-authored-by: Maciej <[email protected]>

* cleaned text, final edits

---------

Co-authored-by: Radha <[email protected]>
Co-authored-by: Maciej <[email protected]>
  • Loading branch information
3 people authored Jun 10, 2024
1 parent 76ba2ae commit e73105e
Show file tree
Hide file tree
Showing 36 changed files with 391 additions and 349 deletions.
4 changes: 2 additions & 2 deletions docs/build/build-client-side.md
Original file line number Diff line number Diff line change
Expand Up @@ -82,8 +82,8 @@ Oracle solutions range from centralized and trusted to decentralized and game-th
centralized end of the spectrum, an oracle could be a single account that has the authority to
dictate the real-world data on-chain. On the decentralized end, a
[complex game of "chicken"](https://blog.ethereum.org/2014/03/28/schellingcoin-a-minimal-trust-universal-data-feed/)
can be played among various staked actors who risk getting slashed if they don't submit the same
data as everyone else.
can be played among various staked actors who risk getting [slashed](../learn/learn-offenses.md) if
they don't submit the same data as everyone else.

<!-- prettier-ignore -->
<Tabs groupId="clients" values={[ {label: 'Chainlink', value: 'chainlink'}, {label: 'Acurast', value: 'acurast'} ]}>
Expand Down
10 changes: 5 additions & 5 deletions docs/general/faq.md
Original file line number Diff line number Diff line change
Expand Up @@ -236,11 +236,11 @@ functionalities like staking and democracy. In exchange to the lost staking rewa
DOTs, the parachain team may offer rewards to the contributor.

The utility of crowdloaned DOT is to provide a lease for a parachain. The utility of staked DOT is
to secure the network through a reward/slash mechanism. Allowing crowdloaned DOT to be staked
results in complex consequences like applying a slash on crowdloaned DOT that was meant to be bonded
for the entire lease period of a parachain. In a way, the inaccessibility of crowdloaned DOTs and
the lack of staking rewards for the entire lease duration encourages the contributors to back
projects that are valuable to the ecosystem.
to secure the network through a reward/[slash](../learn/learn-offenses.md) mechanism. Allowing
crowdloaned DOT to be staked results in complex consequences like applying a slash on crowdloaned
DOT that was meant to be bonded for the entire lease period of a parachain. In a way, the
inaccessibility of crowdloaned DOTs and the lack of staking rewards for the entire lease duration
encourages the contributors to back projects that are valuable to the ecosystem.

## Governance

Expand Down
7 changes: 4 additions & 3 deletions docs/general/glossary.md
Original file line number Diff line number Diff line change
Expand Up @@ -405,8 +405,9 @@ the good behavior of the validator. Nominated Proof-of-Stake differs from the mo
Delegated Proof-of-Stake in that nominators are subject to loss of stake if they nominate a bad
validator; delegators are not subject to loss of stake based on the behavior of the validator. Note
that some other blockchain technologies may use the term Delegated Proof-of-Stake, even if
delegators can be slashed. {{ polkadot: Polkadot :polkadot }}{{ kusama: Kusama :kusama }} uses the
Phragmén method to allocate stake to nominees.
delegators can be [slashed](../learn/learn-offenses.md).
{{ polkadot: Polkadot :polkadot }}{{ kusama: Kusama :kusama }} uses the Phragmén method to allocate
stake to nominees.

## Nominator

Expand Down Expand Up @@ -646,7 +647,7 @@ attacker would need to attack the entire
## Slashing

The removal of a percentage of an account's DOT as a punishment for a validator acting maliciously
or incompetently.
or incompetently. For more information, see the [page about offenses](../learn/learn-offenses.md).

## Soft Fork

Expand Down
7 changes: 4 additions & 3 deletions docs/general/grants.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,10 @@ Web3 Foundation Grants website for comprehensive information.

### Polkadot Treasury

The Polkadot Treasury is a pot of on-chain funds collected through transaction fees, slashing,
staking inefficiencies, etc. The funds held in the treasury can be spent on spending proposals. Both
Polkadot and Kusama offer everyone the opportunity to apply for funding via the treasury. See:
The Polkadot Treasury is a pot of on-chain funds collected through transaction fees,
[slashing](../learn/learn-offenses.md), staking inefficiencies, etc. The funds held in the treasury
can be spent on spending proposals. Both Polkadot and Kusama offer everyone the opportunity to apply
for funding via the treasury. See:

- [Treasury Wiki](../learn/learn-polkadot-opengov-treasury.md)
- [Polkadot Treasury Guide](https://docs.google.com/document/d/1IZykdp2cyQavcRyZd_dgNj5DcgxgZR6kAqGdcNARu1w)
Expand Down
2 changes: 1 addition & 1 deletion docs/general/polkadotjs-ui.md
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ Staking menu you can access:
all bags within the [**bags list**](../learn/learn-staking-advanced.md#bags-list). Here (if
applicable), you can rebag accounts that do not belong to the bag you are in, and you can move
your account in front of the account having less stake than you.
- The **Slashes** tab showing if there are any global slashes.
- The **Slashes** tab showing if there are any global [slashes](../learn/learn-offenses.md).
- The **Validator stats** tab showing statistics for a chosen validator.

### Settings
Expand Down
3 changes: 1 addition & 2 deletions docs/general/web3-and-polkadot.md
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,7 @@ the chain. Although it can be possible to add an invalid block (a block with inv
or censor certain transactions, if the blockchain network is not sufficiently decentralized. In
decentralized proof-of-stake blockchains like
{{ polkadot: Polkadot :polkadot }}{{ kusama: Kusama :kusama }} such attacks are financially
expensive, and attempting to do it can get you
[slashed](../learn/learn-staking-advanced.md#slashing).
expensive, and attempting to do it can get you [slashed](../learn/learn-offenses.md).

So, with blockchain as a means of storing data and transactions permanently without an option to
modify them, we can ensure what we cryptographically sign with our digital identity is set in stone
Expand Down
5 changes: 3 additions & 2 deletions docs/learn/archive/learn-treasury.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,9 @@ import MessageBox from "../../../components/MessageBox"; import
<MessageBox message="The content on this page is archived. For up-to-date information about treasury, see the
[Polkadot OpenGov Treasury page](../../learn/learn-polkadot-opengov-treasury.md)." />

The Treasury is a pot of funds collected through a portion of block production rewards, transaction
fees, slashing, [staking inefficiencies](../learn-staking.md#inflation), etc.
The Treasury is a pot of funds collected through a portion of block production rewards,
[transaction fees](../learn-transaction-fees.md), [slashing](../learn-offenses.md),
[staking inefficiencies](../learn-staking.md#inflation), etc.

The Treasury funds are held in a [system account](../learn-account-advanced.md#system-accounts) not
accessible by anyone; only the system internal logic can access it. Funds can be spent by making a
Expand Down
8 changes: 4 additions & 4 deletions docs/learn/learn-DOT.md
Original file line number Diff line number Diff line change
Expand Up @@ -85,10 +85,10 @@ DOT will be used to facilitate the consensus mechanism that underpins Polkadot.
function and allow for valid transactions to be carried out across parachains, Polkadot will rely on
holders of DOT to play active roles. Participants will put their DOT at risk (via staking) to
perform these functions. The staking of DOT acts as a disincentive for malicious participants who
will be punished by the network by getting their DOT slashed. The DOT required to participate in the
network will vary depending on the activity that is being performed, the duration the DOT will be
staked for, and the total number of DOT staked. For more information about staking on Polkadot visit
[the dedicated staking page](./learn-staking.md).
will be punished by the network by getting their DOT [slashed](./learn-offenses.md). The DOT
required to participate in the network will vary depending on the activity that is being performed,
the duration the DOT will be staked for, and the total number of DOT staked. For more information
about staking on Polkadot visit [the dedicated staking page](./learn-staking.md).

### DOT for Parachain Slot Acquisition

Expand Down
4 changes: 2 additions & 2 deletions docs/learn/learn-comparison-rollups.md
Original file line number Diff line number Diff line change
Expand Up @@ -131,8 +131,8 @@ is interactive, unlike ZK rollups, which are non-interactive. Additionally, unli
are no difficulties in creating parachains with Turing-complete logic. Each parachain is also a
full-fledged state machine (usually in the form of a blockchain). Similarly to optimistic rollups,
the Parachain Protocol also has cases where disputes and resolutions of potentially harmful para
blocks (blocks representing the parachain) can take place, in which case validators are slashed if a
bad parablock is found.
blocks (blocks representing the parachain) can take place, in which case the validators that vouched for that parablock are
[slashed](./learn-offenses.md) if it is found to be bad.

**Benefits:**

Expand Down
12 changes: 6 additions & 6 deletions docs/learn/learn-comparisons-avalanche.md
Original file line number Diff line number Diff line change
Expand Up @@ -121,12 +121,12 @@ algorithm to make decisions about which edges to keep and which to not.

## Staking Mechanics

Avalanche uses a Delegated Proof-of-Stake mechanism without any slashing. The barrier to entry for
staking as a full node validator is 2500 AVAX, and 25 AVAX to become a delegator. With a minimum
stake period being two weeks and a maximum period being a year, for both validators and delegators.
It is not clear from the Avalanche documentation what happens after a year, it is likely that
validators will have to re-stake and start a new period. Validators acquire points for uptime and
correctness of their work, and the remuneration of rewards depends on that.
Avalanche uses a Delegated Proof-of-Stake mechanism without any [slashing](./learn-offenses.md). The
barrier to entry for staking as a full node validator is 2500 AVAX, and 25 AVAX to become a
delegator. With a minimum stake period being two weeks and a maximum period being a year, for both
validators and delegators. It is not clear from the Avalanche documentation what happens after a
year, it is likely that validators will have to re-stake and start a new period. Validators acquire
points for uptime and correctness of their work, and the remuneration of rewards depends on that.

In Polkadot the minimum stake needed to be a validator is variable, same for being a nominator. The
true minimum need to be competitive enough to be included in the active set for validators, or
Expand Down
4 changes: 2 additions & 2 deletions docs/learn/learn-cryptography.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,8 @@ Since the stash key is kept offline, it must be set to have its funds bonded to
proxy. For non-spending actions, the staking proxy has the funds of the stash behind it. For
example, in nominating, staking, or voting, the proxy can indicate its preference with the weight of
the stash. It will never be able to actually move or claim the funds in the stash key. However, if
someone does obtain your proxy key, they could use it for slashable behavior, so you should still
protect it and change it regularly.
someone does obtain your proxy key, they could use it for [slashable behavior](./learn-offenses.md),
so you should still protect it and change it regularly.

### Session Keys

Expand Down
2 changes: 1 addition & 1 deletion docs/learn/learn-guides-identity.md
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ guidelines about clearing identities.
**Clearing:** Users can clear their identity information and have their deposit returned. Clearing
an identity also clears all sub accounts and returns their deposits.

**Killing:** The Council can kill an identity that it deems erroneous. This results in a slash of
**Killing:** It is is possible to kill an identity that deems erroneous. This results in a slash of
the deposit.

## Setting Sub-Identities
Expand Down
11 changes: 5 additions & 6 deletions docs/learn/learn-guides-nominator.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ their identities, the amount of KSM that are staking for them, amount that is th
stake, how much they charge in commission, the era points they've earned in the current era, and the
last block number that they produced. If you click on the chart button it will take you to the
"Validator Stats" page for that validator that shows you more detailed and historical information
about the validator's stake, rewards and slashes.
about the validator's stake, rewards and [slashes](./learn-offenses.md).

The "Account actions" subsection ([link](https://polkadot.js.org/apps/#/staking/actions)) allows you
to stake and nominate.
Expand All @@ -64,7 +64,7 @@ queue for a very long time if they never get enough backing.

The "Validator Stats" subsection ([link](https://polkadot.js.org/apps/#/staking/query)) allows you
to query a validator's stash address and see historical charts on era points, elected stake,
rewards, and slashes.
rewards, and [slashes](./learn-offenses.md).

Pick "Account actions" underneath "Network" > "Staking", then click the "+ Nominator" button.

Expand Down Expand Up @@ -96,10 +96,9 @@ Read the support article about
:::

You are now bonded. Being bonded means your tokens are locked and could be
[slashed](./learn-staking.md#slashing) if the validators you nominate misbehave. All bonded funds
can now be distributed to up to {{ polkadot: 16 :polkadot }} {{ kusama: 24 :kusama }} validators. Be
careful about the validators you choose since you will be slashed if your validator commits an
offence.
[slashed](./learn-offenses.md) if the validators you nominate misbehave. All bonded funds can now be
distributed to up to {{ polkadot: 16 :polkadot }} {{ kusama: 24 :kusama }} validators. Be careful
about the validators you choose since you will be slashed if your validator commits an offence.

Click on "Nominate" on an account you've bonded and you will be presented with another popup asking
you to select some validators.
Expand Down
2 changes: 1 addition & 1 deletion docs/learn/learn-guides-staking-pools.md
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ A pool can be pushed into the “destroying” state via one of:
specific ID of the pool and `state` is the pool's state that must be set to "destroying". Other
possible states are "open" and "blocked".
- Any account can set the pool to destroying if over 90% of the pool's active bonded balance has
been slashed.
been [slashed](./learn-offenses.md).

When a pool is in ‘destroying’ state, `unbond` and `withdrawUnbonded` become permissionless, so
anyone can help all the members exit.
Expand Down
15 changes: 8 additions & 7 deletions docs/learn/learn-nomination-pools.md
Original file line number Diff line number Diff line change
Expand Up @@ -289,12 +289,12 @@ of nomination pools. The cycle includes creation, upkeep and destruction.

## Nomination Pools - Slashing

Suppose the staking system slashes a pool’s underlying nomination account. In that case, the slash
is distributed evenly across the bonded pool, and the unbonding pools from slash era+1 through the
slash apply era. Thus, any member who either a) was unbonding or b) was actively bonded in the
aforementioned range of eras will be affected by the slash. In other words, a member who may have
been actively bonded during the offence is slashed pro rata based on its stake relative to the total
slash amount.
Suppose the staking system [slashes](./learn-offenses.md) a pool’s underlying nomination account. In
that case, the slash is distributed evenly across the bonded pool, and the unbonding pools from
slash era+1 through the slash apply era. Thus, any member who either a) was unbonding or b) was
actively bonded in the aforementioned range of eras will be affected by the slash. In other words, a
member who may have been actively bonded during the offence is slashed pro rata based on its stake
relative to the total slash amount.

Unbonding pools need to be slashed to ensure all nominators who were in the bonded pool while it was
backing a validator that committed an offense are punished. Without these measures a nominator could
Expand All @@ -311,7 +311,8 @@ Nominating is the action of choosing validators. It does not simply involve bond
Nominating is an active task, which implies that you regularly monitor that your stake is backing an
active validator in all the eras and check if you are receiving your staking rewards. More
importantly, ensure that the validators you chose always act in the best interests of the network
protocol and have less chance of getting slashed. To nominate, you need a minimum of
protocol and have less chance of getting [slashed](./learn-offenses.md). To nominate, you need a
minimum of
{{ polkadot: <RPC network="polkadot" path="query.staking.minNominatorBond" defaultValue={100000000000} filter="humanReadable"/> :polkadot }}{{ kusama: <RPC network="kusama" path="query.staking.minNominatorBond" defaultValue={100000000000} filter="humanReadable"/> :kusama }},
and to receive rewards, you need at least a balance greater than the minimum active bond. If the
validator misbehaves, It is worth noting that your stake is subject to slashing, irrespective of
Expand Down
13 changes: 7 additions & 6 deletions docs/learn/learn-nominator.md
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ take a slightly more passive role. Being a nominator does not require running a
worrying about online uptime. However, a good nominator performs due diligence on the validators
that they elect. When looking for validators to nominate, a nominator should pay attention to their
own reward percentage for nominating a specific validator - as well as the risk that they bear of
being [slashed](./learn-staking.md#slashing) if the validator gets slashed.
being [slashed](./learn-offenses.md) if the validator gets slashed.

## Why Nominate?

Expand Down Expand Up @@ -249,11 +249,12 @@ example, `ZUG CAPITAL/07` is one of the numerous validators belonging to the ope

:::warning Single Operators with Multiple Validators

Recall that slashing is an additive function; the more validators equivocating in a given session,
the harsher the penalties. Since validators that are controlled by a single operator are more at
risk of a "synchronized" failure, nominating them implies a greater risk of having a large slash of
your nominated funds. Generally, it is safer to nominate validators whose behavior is independent of
others in many ways (different hardware, geographic location, owner, etc.).
Recall that [slashing](./learn-offenses.md) is an additive function; the more validators
equivocating in a given session, the harsher the penalties. Since validators that are controlled by
a single operator are more at risk of a "synchronized" failure, nominating them implies a greater
risk of having a large slash of your nominated funds. Generally, it is safer to nominate validators
whose behavior is independent of others in many ways (different hardware, geographic location,
owner, etc.).

:::

Expand Down
Loading

0 comments on commit e73105e

Please sign in to comment.