NFTBridge
60,000 USDC
View results
Submission Details
Severity: medium
Invalid

Unlimited memory can be consumed in uint256ArrayDeserialize, cairoStringArrayDeserialize of Cairo library

Hello ArkProject,

uint256ArrayDeserialize, cairoStringArrayDeserialize has following code. The code uses new to allocate dynamic memory arrays (new uint256[](...)). If these allocations are large and not controlled, they could be exploited to consume all available gas or even trigger out-of-gas errors, leading to denial-of-service.

uint256 len = buf[offset++];
uint256[] memory uints = new uint256[](len);
uint256 _offset = offset;
uint256 len = buf[_offset++];
string[] memory strs = new string[](len);
Updates

Lead Judging Commences

n0kto Lead Judge 12 months ago
Submission Judgement Published
Invalidated
Reason: Too generic

Support

FAQs

Can't find an answer? Chat with us on Discord, Twitter or Linkedin.