Skip to content
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

Executor contract doesn't support ReceiveUln302 #58

Closed
abhi3700 opened this issue Apr 11, 2024 · 1 comment
Closed

Executor contract doesn't support ReceiveUln302 #58

abhi3700 opened this issue Apr 11, 2024 · 1 comment

Comments

@abhi3700
Copy link

abhi3700 commented Apr 11, 2024

In Executor.sol, the initialize function doesn't have _receiveUln302 param, but _receiveUln301.

Code:

function initialize(
address _endpoint,
address _receiveUln301,
address[] memory _messageLibs,
address _priceFeed,
address _roleAdmin,
address[] memory _admins
) external proxied initializer {
__ReentrancyGuard_init();
__Worker_init(_messageLibs, _priceFeed, 12000, _roleAdmin, _admins);
endpoint = _endpoint;
localEid = ILayerZeroEndpointV2(_endpoint).eid();
receiveUln301 = _receiveUln301;
}

Is this expected?

Now, during setup (as in deploying Executor), I found this code in the tests:

address[] memory libs = new address[](3);
libs[0] = sendUln301;
libs[1] = receiveUln301;
libs[2] = sendUln302;
executor.initialize(endpointV2, receiveUln301, libs, priceFeed, address(this), admins);
executor.setWorkerFeeLib(address(executorFeeLib));

Here, can I include receiveUln302 in the libs?

Moreover, I can see some of the functions like onUpgrade, nativeDropAndExecute301, execute301 are dependent on receiveUln301. So, it's clear that receiveUln301 has to be set in initializer function.

I also found another file - LzExecutor.sol which seems to be a replacement for Executor.sol as it considers receiveUln302 all over. But, then it doesn't have functions - assignJob, getFee.

Can anyone clear my doubts?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants