Skip to content

Commit

Permalink
[STO-033]: staked entity have read-only access to any storage in non-…
Browse files Browse the repository at this point in the history
…entity contract. (eth-infinitism#156)
  • Loading branch information
drortirosh authored Oct 18, 2023
1 parent 310e63f commit aac31d2
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions packages/bundler/src/parseScannerResult.ts
Original file line number Diff line number Diff line change
Expand Up @@ -318,6 +318,9 @@ export function parseScannerResult (userOp: UserOperation, tracerResults: Bundle
// [STO-031]
// accessing storage member of entity itself requires stake.
requireStakeSlot = slot
} else if (writes[slot] == null) {
// [STO-033]: staked entity have read-only access to any storage in non-entity contract.
requireStakeSlot = slot
} else {
// accessing arbitrary storage of another contract is not allowed
const readWrite = Object.keys(writes).includes(addr) ? 'write to' : 'read from'
Expand Down

0 comments on commit aac31d2

Please sign in to comment.