Commit 5c1e1ac
fix: update allocation delay fields immediately for newly registered operators
Addresses audit finding L-01: State inconsistency for new operator allocation delay.
When a new operator registers and their allocation delay is set via DelegationManager,
_setAllocationDelay now also updates info.delay and info.isSet immediately,
not just pendingDelay. This ensures storage consistency where the raw
AllocationDelayInfo struct reflects the effective delay immediately.
Changes:
- AllocationManager._setAllocationDelay(): Set delay and isSet when newlyRegistered=true
- IAllocationManager: Updated NatSpec for AllocationDelayInfo struct
- AllocationManagerHarness: Added getAllocationDelayInfoRaw() for testing raw storage
- Unit tests: Added tests verifying storage consistency
- Docs: Updated setAllocationDelay effects
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>1 parent e9bb4b0 commit 5c1e1ac
File tree
12 files changed
+67
-16
lines changed- docs/core
- pkg/bindings
- AllocationManagerView
- AllocationManager
- CrossChainRegistry
- DelegationManager
- KeyRegistrar
- RewardsCoordinator
- StrategyManager
- src
- contracts
- core
- interfaces
- test
- harnesses
- unit
12 files changed
+67
-16
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
990 | 990 | | |
991 | 991 | | |
992 | 992 | | |
993 | | - | |
994 | | - | |
| 993 | + | |
| 994 | + | |
995 | 995 | | |
996 | 996 | | |
997 | 997 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
605 | 605 | | |
606 | 606 | | |
607 | 607 | | |
608 | | - | |
| 608 | + | |
| 609 | + | |
| 610 | + | |
609 | 611 | | |
610 | 612 | | |
611 | 613 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
93 | 93 | | |
94 | 94 | | |
95 | 95 | | |
96 | | - | |
97 | | - | |
98 | | - | |
99 | | - | |
100 | | - | |
101 | | - | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
102 | 101 | | |
103 | 102 | | |
104 | 103 | | |
| |||
0 commit comments