-
Notifications
You must be signed in to change notification settings - Fork 432
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: CCIP hook and ism #5392
feat: CCIP hook and ism #5392
Conversation
🦋 Changeset detectedLatest commit: 3acd58d The changes in this PR will be included in the next version bump. This PR includes changesets to release 9 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
@@ -0,0 +1,84 @@ | |||
// SPDX-License-Identifier: MIT OR Apache-2.0 | |||
pragma solidity >=0.8.0; |
Check notice
Code scanning / Olympix Integrated Security
Using an unbounded pragma for Solidity version may be unsafe if future versions introduce breaking changes. For more information, visit: http://detectors.olympixdevsectools.com/article/web3-vulnerability/unbounded-pragma Low
// ============ Constructor ============ | ||
|
||
constructor( | ||
address _ccipRouter, |
Check notice
Code scanning / Olympix Integrated Security
Parameters passed to a constructor that are not validated for correct values may lead to contract creation in an undesired state. For more information, visit: http://detectors.olympixdevsectools.com/article/web3-vulnerability/no-parameter-validation-in-constructor Low
|
||
constructor( | ||
address _ccipRouter, | ||
uint64 _ccipDestination, |
Check notice
Code scanning / Olympix Integrated Security
Parameters passed to a constructor that are not validated for correct values may lead to contract creation in an undesired state. For more information, visit: http://detectors.olympixdevsectools.com/article/web3-vulnerability/no-parameter-validation-in-constructor Low
constructor( | ||
address _ccipRouter, | ||
uint64 _ccipDestination, | ||
address _mailbox, |
Check notice
Code scanning / Olympix Integrated Security
Parameters passed to a constructor that are not validated for correct values may lead to contract creation in an undesired state. For more information, visit: http://detectors.olympixdevsectools.com/article/web3-vulnerability/no-parameter-validation-in-constructor Low
address _ccipRouter, | ||
uint64 _ccipDestination, | ||
address _mailbox, | ||
uint32 _destination, |
Check notice
Code scanning / Olympix Integrated Security
Parameters passed to a constructor that are not validated for correct values may lead to contract creation in an undesired state. For more information, visit: http://detectors.olympixdevsectools.com/article/web3-vulnerability/no-parameter-validation-in-constructor Low
uint64 _ccipDestination, | ||
address _mailbox, | ||
uint32 _destination, | ||
bytes32 _ism |
Check notice
Code scanning / Olympix Integrated Security
Parameters passed to a constructor that are not validated for correct values may lead to contract creation in an undesired state. For more information, visit: http://detectors.olympixdevsectools.com/article/web3-vulnerability/no-parameter-validation-in-constructor Low
@@ -0,0 +1,70 @@ | |||
// SPDX-License-Identifier: MIT OR Apache-2.0 | |||
pragma solidity >=0.8.0; |
Check notice
Code scanning / Olympix Integrated Security
Using an unbounded pragma for Solidity version may be unsafe if future versions introduce breaking changes. For more information, visit: http://detectors.olympixdevsectools.com/article/web3-vulnerability/unbounded-pragma Low
* @title CCIPIsm | ||
* @notice Uses CCIP hook to verify interchain messages. | ||
*/ | ||
contract CCIPIsm is AbstractMessageIdAuthorizedIsm, CCIPReceiver { |
Check failure
Code scanning / Olympix Integrated Security
Contracts that can receive ether but cannot send it may lock value permanently. For more information, visit: http://detectors.olympixdevsectools.com/article/web3-vulnerability/locked-ether Critical
|
||
// ============ Storage ============ | ||
constructor( | ||
address _ccipRouter, |
Check notice
Code scanning / Olympix Integrated Security
Parameters passed to a constructor that are not validated for correct values may lead to contract creation in an undesired state. For more information, visit: http://detectors.olympixdevsectools.com/article/web3-vulnerability/no-parameter-validation-in-constructor Low
// ============ Storage ============ | ||
constructor( | ||
address _ccipRouter, | ||
uint64 _ccipOrigin |
Check notice
Code scanning / Olympix Integrated Security
Parameters passed to a constructor that are not validated for correct values may lead to contract creation in an undesired state. For more information, visit: http://detectors.olympixdevsectools.com/article/web3-vulnerability/no-parameter-validation-in-constructor Low
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## ccip-warp-route #5392 +/- ##
===================================================
- Coverage 77.87% 77.11% -0.76%
===================================================
Files 107 109 +2
Lines 2142 2163 +21
Branches 191 193 +2
===================================================
Hits 1668 1668
- Misses 453 474 +21
Partials 21 21
|
@@ -10,7 +10,7 @@ import 'solidity-coverage'; | |||
*/ | |||
module.exports = { | |||
solidity: { | |||
version: '0.8.19', | |||
version: '0.8.22', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
CCIP contracts impose ^0.8.20
1260fb3
to
e69a84c
Compare
receiver: abi.encode(ism), | ||
data: abi.encode(message.id()), | ||
tokenAmounts: new Client.EVMTokenAmount[](0), | ||
extraArgs: "", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How come we hardcode extraArgs? In their best practices, it says this should be mutable to 1) set the gas limits outside of the 200k default, and 2) set out of order execution if it’s required for certain chains
When allowOutOfOrderExecution is Required:
You must set allowOutOfOrderExecution to true. This setting acknowledges that messages may be executed out of order. If set to false, the message will revert and will not be processed.
Description
Implements CCIP hook and ISM that offloads message verification to the CCIP message bridge
Related issues
Fixes #2852
Backward compatibility
Yes
Testing
Unit Tests/Fork Tests