Skip to content

[bug] Multicall functions not decoded properly #464

@fala13

Description

@fala13

Component

Heimdall (CLI)

Have you ensured that you are up to date?

  • Bifrost
  • Heimdall

What version of Heimdall are you on?

8.2 // cfc1765

Operating System

Linux

Describe the bug

Symbolic execution does not correctly figure out, which I guess is to be expected because of their difficulty.
Then the match_parameters function also rejects the 4bytes resolved signatures due to both different number of input arguments (symbolic detects few uint256 inputs) and their type.

I'm doing some heuristic workaround to just use the 4bytes signature if there is a byte[] involved, but need to some experiments how common this is.

Examples on Ethereum:
0x1F98415757620B543A52E61c46B32eB19261F984 - uniswap multicall
0xca11bde05977b3631167028862be2a173976ca11 - multicall3

In the Heimdall output the issue is only visible on TRACE log level:

2024-07-22T09:41:20.602399Z TRACE heimdall_decompiler::core::resolve: checking function multicall((address,uint256,by
tes)[]) against Unresolved_0x1749e1e3(uint256,uint256,uint256,uint256)

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions