Skip to content

Commit b9c1a61

Browse files
feat: slashing commitments (#1645)
**Motivation:** We want to solve the following use cases: - As an AVS I want to make a commitment on the address that can slash a given operatorSet - As an AVS I want to allow *one* address to slash an operatorSet - As an AVS I DO NOT want to allow the admin to slash the operatorSet via `PermissionController` actions **Modifications:** The slasher permissions are set and stored in the `AllocationManager` instead of the `PermissionController`. The slasher is initially set upon creation of the operatorSet. New functions: - `updateSlasher`: can set a new slasher on a `ALLOCATION_CONFIGURATION_DELAY` blocks (17.5 days on mainnet) - `migrateSlasher`: migrates the slasher address from the `PermissionController` to the `AllocationManager`. Can be migrated only once for a given operatorSet. This function will be called after the upgrade for all operatorSets. See the script in the script folder, which will eventually be added to the upgrade script. - `createOperatorSet`: modified to take in a slasher address, which can immediately slash an operatorSet. The *old* function is still available and will be deprecated in Q2 2026. The *old* function automatically the slasher to the avs address. Old Functions: - `slashOperator` is modified to not use the `checkCanCall` modifier We have 1.9KB left in the ALM. **Result:** Stronger commitments. --------- Co-authored-by: Nadir Akhtar <[email protected]>
1 parent 15e17a2 commit b9c1a61

File tree

72 files changed

+17215
-2742
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

72 files changed

+17215
-2742
lines changed

.github/workflows/foundry.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,7 @@ jobs:
193193
FOUNDRY_PROFILE=coverage \
194194
FOUNDRY_CACHE=true \
195195
FOUNDRY_CACHE_PATH=cache \
196-
forge coverage --report lcov --report summary --no-match-coverage "script|test" -j $(nproc)
196+
forge coverage --report lcov --report summary --no-match-coverage "script|test" -j $(nproc) --no-match-test test_noCoverage
197197
genhtml -q -o report ./lcov.info
198198
199199
# Upload coverage report as artifact before potential failure

.github/workflows/validate-deployment-scripts.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ jobs:
3131
submodules: recursive
3232

3333
- name: Install Zeus
34-
run: npm install -g @layr-labs/zeus
34+
run: npm install -g @layr-labs/zeus --ignore-scripts
3535

3636
# Restore Forge cache
3737
- name: Cache Forge Build

docs/core/AllocationManager.md

Lines changed: 175 additions & 13 deletions
Large diffs are not rendered by default.

pkg/bindings/AVSDirectory/binding.go

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/bindings/AVSDirectoryStorage/binding.go

Lines changed: 1 addition & 32 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/bindings/AllocationManager/binding.go

Lines changed: 657 additions & 237 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/bindings/AllocationManagerStorage/binding.go

Lines changed: 300 additions & 1228 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/bindings/AllocationManagerView/binding.go

Lines changed: 3306 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pkg/bindings/BN254CertificateVerifier/binding.go

Lines changed: 4 additions & 35 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)