LayerZero Channel can be blocked by an attacker #309
Labels
3 (High Risk)
Assets can be stolen/lost/compromised directly
bug
Something isn't working
duplicate
This issue or pull request already exists
invalid
This doesn't seem right
partial-25
Incomplete articulation of vulnerability; eligible for partial credit only (25%)
Lines of code
https://github.com/code-423n4/2022-10-holograph/blob/f8c2eae866280a1acfdc8a8352401ed031be1373/contracts/module/LayerZeroModule.sol#L180
Vulnerability details
Impact
According to the LayerZero docs, the default behavior is that when a transaction on the destination application fails, the channel between the source and destination is blocked. Before any new transactions can be executed, the failed transaction has to be retried until it succeeds.
See https://layerzero.gitbook.io/docs/faq/messaging-properties#message-ordering & https://layerzero.gitbook.io/docs/guides/advanced/nonblockinglzapp
An attacker is able to initiate a transaction they know will fail to block the channel.
Proof of Concept
The LayerZeroModule does not have the non-blocking approach as seen here
Example implementation here by LayerZero here
Tools Used
VSCode
Recommended Mitigation Steps
Use the non-blocking approach as described here.
Reference for similar error here
The text was updated successfully, but these errors were encountered: