Commit 96fea29
Require that msgSender be an owner of the Safe (#17900)
* Add SaferSafes as child of the module and guard
* Add ISaferSafes
* Test comment and assertion fixes
* Improve comments
* Make LivenessModule2 and TimelockGuard abstract
Move semver to SaferSafes
semver lock
* fix test contract name
* Move semver to SaferSafes
* Disable the guard and module upon ownership transfer
* Add _disableThisGuard function
* Update tests
* Add config resets
* fmt
* fix test_changeOwnershipToFallback_canRechallenge_succeeds
* Simplify by clearing config directly
* Put _disableThisGuard into child contract
* Add timelockDelay reset on _disableThisGuard
* semver-lock
* Move _disableThisGuard logic into TimelockGuard
* clear livenessSafeConfig at tend of _disableThisModule
* Clarify use of SENTINEL_OWNER
* Fix the ordering of the disableGuard and disableModule calls
* semver-lock
* remove unused imports
* rename _disableThisGuard to _disableGuard
* bump semver
* Add test to remove unrelated guard
* Add SENTINEL_MODULE constant
* Clean up using ternary if
* Reset cancellationThreshold to 0 on changeOwnership
* Fix moduleFound if/else handling
* Clear pending transactions
* Pre-pr fixes
* Add test contract to test name lint exclusions
* fix name of test contract
* Move _disableGuard impl into TimelockGuard
* Add missing natspec
* Add gas limit testing on changeOwnershipToFallback
* Remove interfaces for abstract contracts
* Move state changes out into internal _clearLivenessModule
* Improve names on the internal _disableX methods
* Add clearTimelockGuard function
* Add _disableGuard helper to TLG tests
* Limit number of transactions cancelled to 100
* Revert "Remove interfaces for abstract contracts"
This reverts commit bd03288.
* Move livenessModule2 address into TestUtils
Reduces diff a bit
* Reduce diff somewhat
* Remove unused arg
* Update packages/contracts-bedrock/src/safe/TimelockGuard.sol
Co-authored-by: graphite-app[bot] <96075541+graphite-app[bot]@users.noreply.github.com>
* Fix iface
* update abi for iface fix
* Do not clear or disable the module during ownership transfer
* Fix inaccurate comment on _disableAndClearGuard
* Further improve comment
* remove unused import
* fix test name
* Do not clear guard during changeOwnershipToFallback
* Remove unused SENTINEL_MODULE var
* Remove dangling comment
* Revert "Remove dangling comment"
This reverts commit d266d12.
* Fix whitespace
* remove unnecessary internal _clearTimelockGuard function
It's no longer reused in the change ownership call.
* Address feedback
* Add missing assertion
* Move guard slot into constants
* semver-lock
* Remove LivenessModule from semver-lock
* fix: fmt, semver-lock, unused imports
* Remove unused variable
* fix semver lock by resetting old LivenessModule
* fix unused import
* Require that msgSender be an owner of the Safe
* fix compiler error
* Fix placement of _msgSender check
* semver-lock
* Add TimelockGuard_NotOwner test
* Bump semver
* Add test comment, make into fuzz test
* Improvements to SaferSafes styling (#17903)
* Add public getter livenessSafeConfiguration to return a struct rather than tuple
* Use Safe as input type to mappings and functions on LivenessModule2
* Add dividers based on function type
* fmt
* snapshots
* Remove conditional return of 0 in the cancellationThreshold if the guard is not enabled
* rename timelockConfiguration func to timelockDelay
* semver-lock
* Add missing natspec on tests and convert to fuzzing where possible
* fix import and abi snapshot
* fix: off by one error in challenge period test
* fix test name
---------
Co-authored-by: graphite-app[bot] <96075541+graphite-app[bot]@users.noreply.github.com>1 parent bb24f93 commit 96fea29
File tree
11 files changed
+385
-197
lines changed- packages/contracts-bedrock
- scripts/deploy
- snapshots
- abi
- storageLayout
- src/safe
- test
- safe
- scripts
11 files changed
+385
-197
lines changedLines changed: 4 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
324 | 324 | | |
325 | 325 | | |
326 | 326 | | |
327 | | - | |
328 | | - | |
| 327 | + | |
| 328 | + | |
329 | 329 | | |
330 | | - | |
| 330 | + | |
331 | 331 | | |
332 | 332 | | |
333 | 333 | | |
334 | | - | |
| 334 | + | |
335 | 335 | | |
336 | 336 | | |
337 | 337 | | |
| |||
Lines changed: 28 additions & 16 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
49 | 49 | | |
50 | 50 | | |
51 | 51 | | |
52 | | - | |
| 52 | + | |
53 | 53 | | |
54 | 54 | | |
55 | 55 | | |
| |||
62 | 62 | | |
63 | 63 | | |
64 | 64 | | |
65 | | - | |
| 65 | + | |
66 | 66 | | |
67 | 67 | | |
68 | 68 | | |
| |||
81 | 81 | | |
82 | 82 | | |
83 | 83 | | |
84 | | - | |
| 84 | + | |
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
| |||
163 | 163 | | |
164 | 164 | | |
165 | 165 | | |
166 | | - | |
| 166 | + | |
167 | 167 | | |
168 | 168 | | |
169 | 169 | | |
| |||
227 | 227 | | |
228 | 228 | | |
229 | 229 | | |
230 | | - | |
| 230 | + | |
231 | 231 | | |
232 | 232 | | |
233 | 233 | | |
| |||
246 | 246 | | |
247 | 247 | | |
248 | 248 | | |
249 | | - | |
250 | | - | |
| 249 | + | |
| 250 | + | |
251 | 251 | | |
252 | 252 | | |
253 | 253 | | |
254 | 254 | | |
255 | 255 | | |
256 | 256 | | |
257 | | - | |
258 | | - | |
259 | | - | |
260 | | - | |
261 | | - | |
262 | | - | |
263 | | - | |
264 | | - | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
265 | 272 | | |
266 | 273 | | |
267 | 274 | | |
| |||
560 | 567 | | |
561 | 568 | | |
562 | 569 | | |
563 | | - | |
| 570 | + | |
564 | 571 | | |
565 | 572 | | |
566 | 573 | | |
| |||
902 | 909 | | |
903 | 910 | | |
904 | 911 | | |
| 912 | + | |
| 913 | + | |
| 914 | + | |
| 915 | + | |
| 916 | + | |
905 | 917 | | |
906 | 918 | | |
907 | 919 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
208 | 208 | | |
209 | 209 | | |
210 | 210 | | |
211 | | - | |
212 | | - | |
| 211 | + | |
| 212 | + | |
213 | 213 | | |
214 | 214 | | |
215 | 215 | | |
| |||
Lines changed: 3 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
4 | | - | |
| 4 | + | |
5 | 5 | | |
6 | 6 | | |
7 | | - | |
| 7 | + | |
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
14 | | - | |
| 14 | + | |
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| |||
0 commit comments