Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
N
nebula
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
exchain
nebula
Commits
888b6e14
Unverified
Commit
888b6e14
authored
Aug 27, 2023
by
Michael de Hoog
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add note about arbitrary message sending from OptimismPortal
parent
f37a108c
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
0 deletions
+13
-0
withdrawals.md
specs/withdrawals.md
+13
-0
No files found.
specs/withdrawals.md
View file @
888b6e14
...
...
@@ -48,6 +48,7 @@ finalization.
-
[
Security Considerations
](
#security-considerations
)
-
[
Key Properties of Withdrawal Verification
](
#key-properties-of-withdrawal-verification
)
-
[
Handling Successfully Verified Messages That Fail When Relayed
](
#handling-successfully-verified-messages-that-fail-when-relayed
)
-
[
OptimismPortal can send abitrary messages on L1
](
#optimismportal-can-send-abitrary-messages-on-l1
)
<!-- END doctoc generated TOC please keep comment here to allow auto update -->
...
...
@@ -216,3 +217,15 @@ contracts if desired.
[
`WithdrawalTransaction` type
]:
https://github.com/ethereum-optimism/optimism/blob/08daf8dbd38c9ffdbd18fc9a211c227606cdb0ad/packages/contracts-bedrock/src/libraries/Types.sol#L62-L69
[
`OutputRootProof` type
]:
https://github.com/ethereum-optimism/optimism/blob/08daf8dbd38c9ffdbd18fc9a211c227606cdb0ad/packages/contracts-bedrock/src/libraries/Types.sol#L25-L30
### OptimismPortal can send abitrary messages on L1
The
`L2ToL1MessagePasser`
contract's
`initiateWithdrawal`
function accepts a
`_target`
address and
`_data`
bytes,
which is passed to a
`CALL`
opcode on L1 when
`finalizeWithdrawalTransaction`
is called after the challenge
period. This means that, by design, the
`OptimismPortal`
contract can be used to send arbitrary transactions on
the L1, with the
`OptimismPortal`
as the
`msg.sender`
.
This means users of the
`OptimismPortal`
contract should be careful what permissions they grant to the portal.
For example, any ERC20 tokens mistakenly sent to the
`OptimismPortal`
contract are essentially lost, as they can
be claimed by anybody that pre-approves transfers of this token out of the portal, using the L2 to initiate the
approval and the L1 to prove and finalize the approval (after the challenge period).
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment