Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/vaporyjs/vap-bin-to-method-ids

Extracts the four byte methodIds from EVM byte code.
https://github.com/vaporyjs/vap-bin-to-method-ids

vapory vvm

Last synced: 11 days ago
JSON representation

Extracts the four byte methodIds from EVM byte code.

Awesome Lists containing this project

README

        

# vap-bin-to-method-ids

Extracts the four byte methodIds from EVM byte code.
Uses naive static analysis to look for entrypoints based on common Solidity->EVM patterns.

### usage
```js
const binToMethodIds = require('vap-bin-to-method-ids')
const code = Buffer.from('6060604052...', 'hex')

const methodIds = binToMethodIds(code)
console.log(methodIds)
// => [
// '0230a07c',
// '13c89a8f',
// '15f73331',
// '22ec1244'
// ]
```