{"id":32159873,"url":"https://github.com/zchn/ethereum-analyzer","last_synced_at":"2026-02-21T15:03:52.286Z","repository":{"id":62435925,"uuid":"88443064","full_name":"zchn/ethereum-analyzer","owner":"zchn","description":"An Ethereum contract analyzer.","archived":false,"fork":false,"pushed_at":"2025-01-22T02:15:30.000Z","size":2016,"stargazers_count":19,"open_issues_count":6,"forks_count":6,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-12-07T23:56:03.168Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://hackage.haskell.org/package/ethereum-analyzer","language":"Haskell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/zchn.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2017-04-16T21:17:14.000Z","updated_at":"2025-02-05T05:16:20.000Z","dependencies_parsed_at":"2025-05-31T23:01:59.444Z","dependency_job_id":"86202f3a-55d9-4929-b1be-98bd568083b7","html_url":"https://github.com/zchn/ethereum-analyzer","commit_stats":null,"previous_names":[],"tags_count":12,"template":false,"template_full_name":null,"purl":"pkg:github/zchn/ethereum-analyzer","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zchn%2Fethereum-analyzer","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zchn%2Fethereum-analyzer/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zchn%2Fethereum-analyzer/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zchn%2Fethereum-analyzer/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/zchn","download_url":"https://codeload.github.com/zchn/ethereum-analyzer/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/zchn%2Fethereum-analyzer/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29684076,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-21T14:31:22.911Z","status":"ssl_error","status_checked_at":"2026-02-21T14:31:22.570Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-10-21T13:25:34.960Z","updated_at":"2026-02-21T15:03:52.281Z","avatar_url":"https://github.com/zchn.png","language":"Haskell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ethereum-analyzer [![Hackage](https://img.shields.io/hackage/v/ethereum-analyzer.svg)](https://hackage.haskell.org/package/ethereum-analyzer) [![Build Status](https://travis-ci.org/zchn/ethereum-analyzer.svg?branch=master)](https://travis-ci.org/zchn/ethereum-analyzer)\n\n- [Usage](#usage)\n  - [Solidity Control Flow Graph (CFG) Generation](#solidity-control-flow-graph-cfg-generation)\n  - [Solidity Linter (WIP)](#solidity-linter-wip)\n  - [EVM CFG Generation](#evm-cfg-generation)\n\n## Usage\n\n### Solidity Control Flow Graph (CFG) Generation\n\n```shell\nstack build --profile \u0026\u0026\\\n  solc --combined-json ast examples/etherscan.io/CryptoKittiesCore.sol |\\\n  stack exec -- ea-analyze \u0026\u0026\\\n  find work/ -name \"*.dot\" -exec dot -Tpng -O \\{\\} \\;\n```\n\ngenerates CFGs like\n\n![Solidity CFG](./doc/img/KittyOwnership.tokensOfOwner.CFG.dot.png)\n\nwhose original code looks like\n\n```javascript\nfunction tokensOfOwner(address _owner) external view returns(uint256[] ownerTokens) {\n  uint256 tokenCount = balanceOf(_owner);\n  if (tokenCount == 0) {\n    return new uint256[](0);\n  } else {\n    uint256[] memory result = new uint256[](tokenCount);\n    uint256 totalCats = totalSupply();\n    uint256 resultIndex = 0;\n    uint256 catId;\n    for (catId = 1; catId \u003c= totalCats; catId++) {\n      if (kittyIndexToOwner[catId] == _owner) {\n        result[resultIndex] = catId;\n        resultIndex++;\n      }\n    }\n    return result;\n  }\n}\n```\n\n### Solidity Linter (WIP)\n\n``` shell\nstack build\nsolc --combined-json ast\\\n  examples/analysis-benchmark/selfdestruct-over-suicide.sol |\\\n  stack exec ea-analyze\n```\n\n### EVM CFG Generation\n\n``` shell\nstack build\ncat examples/etherscan.io/CryptoKittiesSalesAuction.evm | stack exec -- ea-bytecode-vis --outDot=work/tmp.dot \u0026\u0026\\\n  dot -Tpng work/tmp.dot -O\n```\n\ngenerates a pretty large CFG for the whole EVM bytecode sequence, part of which\nlooks like\n\n![EVM CFG](./doc/img/CryptoKittiesSalesAuction.evm.part.dot.png)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzchn%2Fethereum-analyzer","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzchn%2Fethereum-analyzer","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzchn%2Fethereum-analyzer/lists"}