{"id":15633945,"url":"https://github.com/tintinweb/vscode-decompiler","last_synced_at":"2025-06-23T16:31:23.482Z","repository":{"id":45492168,"uuid":"263429392","full_name":"tintinweb/vscode-decompiler","owner":"tintinweb","description":"Decompile things directly from VSCode","archived":false,"fork":false,"pushed_at":"2023-01-09T00:59:33.000Z","size":46616,"stargazers_count":161,"open_issues_count":17,"forks_count":29,"subscribers_count":5,"default_branch":"master","last_synced_at":"2024-12-10T05:42:56.193Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://marketplace.visualstudio.com/items?itemName=tintinweb.vscode-decompiler","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tintinweb.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-05-12T19:15:11.000Z","updated_at":"2024-12-03T23:14:34.000Z","dependencies_parsed_at":"2023-02-08T08:15:27.175Z","dependency_job_id":null,"html_url":"https://github.com/tintinweb/vscode-decompiler","commit_stats":null,"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tintinweb%2Fvscode-decompiler","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tintinweb%2Fvscode-decompiler/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tintinweb%2Fvscode-decompiler/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tintinweb%2Fvscode-decompiler/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tintinweb","download_url":"https://codeload.github.com/tintinweb/vscode-decompiler/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":230479865,"owners_count":18232630,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":"2024-10-03T10:50:42.552Z","updated_at":"2024-12-19T18:16:22.757Z","avatar_url":"https://github.com/tintinweb.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"[\u003cimg width=\"200\" alt=\"get in touch with Consensys Diligence\" src=\"https://user-images.githubusercontent.com/2865694/56826101-91dcf380-685b-11e9-937c-af49c2510aa0.png\"\u003e](https://diligence.consensys.net)\u003cbr/\u003e\n\u003csup\u003e\n[[  🌐  ](https://diligence.consensys.net)  [  📩  ](mailto:diligence@consensys.net)  [  🔥  ](https://consensys.github.io/diligence/)]\n\u003c/sup\u003e\u003cbr/\u003e\u003cbr/\u003e\n\n\n# Decompiler!\n\nLet's be honest, there is no reason to remember how to decompile stuff with the various tools available. Wouldn't it be nice to just decompile the $h*! out of things right off the fingertips in Visual Studio Code? Well, here we go:\n\nThis extension decompiles ...\n\n* \u003cimg width=\"17\" alt=\"PE\" src=\"https://user-images.githubusercontent.com/2865694/81810700-b7e73b80-9523-11ea-9ed3-f52704689939.png\"\u003e\u003cimg width=\"17\" alt=\"ELF/MACH\" src=\"https://user-images.githubusercontent.com/2865694/81844741-d3683b80-954f-11ea-8d21-df843d1dc4df.png\"\u003e Binary executables for various platforms\n    * as supported by [Ghidra](https://github.com/NationalSecurityAgency/ghidra/wiki/Frequently-asked-questions#what-processors-are-currently-supported); Windows PE, Linux ELF, IOS, etc..\n    * or [IDAPro](https://www.hex-rays.com/products/ida/processors/) (Experimental, Windows Only for now)\n* \u003cimg width=\"16\" alt=\"Jar\" src=\"https://user-images.githubusercontent.com/2865694/81810613-8a9a8d80-9523-11ea-9fd9-0c83274746d7.png\"\u003e Java Jar archives and compiled Classes\n* \u003cimg width=\"15\" alt=\"APK\" src=\"https://user-images.githubusercontent.com/2865694/81810616-8c645100-9523-11ea-9bd1-cfddde16a420.png\"\u003e Android APK's\n* \u003cimg width=\"15\" alt=\"PYC\" src=\"https://user-images.githubusercontent.com/2865694/82730302-e7a1fa80-9cfe-11ea-9499-8cabe633a1d0.png\"\u003e Python `.pyc` and `.pyo`\n* \u003cimg width=\"15\" alt=\"EVM\" src=\"https://user-images.githubusercontent.com/2865694/84128845-702fd300-aa41-11ea-8202-d7bbb5fda19b.png\"\u003e Ethereum/EVM based Smart Contracts \n    * (Experimental, [Linux/MacOs only](https://github.com/eveem-org/panoramix/issues/19))\n\nJust `right-click → Decompile` on a supported executable and wait for the magic to happen.\n\nThe decompilation result is added to a temporary sub-workspace. You can `right-click → Download` files to your local file-system right from the sub-workspace.\n\nHave phun 🙌\n\n## Tour\n\n**macOS**\n\n![vscode-decompiler](https://user-images.githubusercontent.com/2865694/81797377-faeae400-950e-11ea-9060-2712dbb4740f.gif)\n\n**Windows (Ghidra vs. IDAPro)**\n\n![vscode-decompiler-idapro](https://user-images.githubusercontent.com/2865694/82062800-ee12ef80-96ca-11ea-8ef6-78920c012477.gif)\n\n**Ethereum Smart Contract**\n\nSave the `EVM` byte-code in a file with extension `.evm`, then `right-click → Decompile`.\n\n![vscode-decompiler-evm-1](https://user-images.githubusercontent.com/2865694/84135961-eb49b700-aa4a-11ea-9d9c-f329f7400ef0.gif)\n\n\n## Setup\n\n\u003cdetails\u003e\n  \u003csummary style='font-size:12pt'\u003e\u003cb\u003eRequirements:\u003c/b\u003e General\u003c/summary\u003e\n\n* Requires Java (11+) to be installed system-wide. Just install the latest JRE/JDK for your OS (e.g. OpenJDK, Oracle JDK).\n* Other tools are bundled with the extension. Just make sure Java is available in your `PATH`.\n\n\u003c/details\u003e\n\u003cdetails\u003e\n  \u003csummary style='font-size:12pt'\u003e\u003cb\u003eRequirements:\u003c/b\u003e Binary executables (Ghidra / IDA Pro)\u003c/summary\u003e\n\n* Requires a working installation of [Ghidra](https://ghidra-sre.org/) (← Download) to decompile executables\n    * either available in `PATH` (like when you install it with `brew cask install ghidra` on os-x; or set-up manually)\n    * otherwise please specify the path to the executable `\u003cghidra\u003e/support/analyzeHeadless` in `code → preferences → settings: vscode-decompiler.tool.ghidra.path` and make sure that the `analyzeHeadless` script runs without errors (and is not prompting for the JDK Home 🤓). Here's a sample Ghidra config for Windows:\n    ![ghidraconf](https://user-images.githubusercontent.com/2865694/81807509-7dc76b00-951e-11ea-99d7-359bd624cce5.png)\n* (Experimental; Windows Only) Optional a licensed version of [IDA Pro](https://www.hex-rays.com/products/decompiler/) with decompiler support.\n    * specify the path to the `idaw` executable in `code → preferences → settings: vscode-decompiler.tool.idaPro.path`, e.g. `c:\\IDA68\\idaw.exe`.\n    * set preference to `idaPro (experimental Windows Only)` in `code → preferences → settings: vscode-decompiler.default.decompiler.selected`.\n    * we'll automatically try to run 32 and 64bits `idaw` on the target application (preference on what executable is configured by you)\n    * If you're running `\u003c= IDA Pro 6.6` and the normal IDA decompilation mode does not work you can try the set preference to `idaPro legacy hexx-plugin (experimental Windows Only)` in `code → preferences → settings: vscode-decompiler.default.decompiler.selected`. Note: Use this method only if the normal IDA Pro mode doesnt work. Caveat: `idaw*.exe` must not be in a path that contains spaces, ask @microsoft why 😉.\n* You're using Ghidra? Great! Now please follow the [Ghidra installation guide](https://ghidra-sre.org/InstallationGuide.html#JavaNotes) (JAVA setup in particular). Make sure both `ghidraRun` and `support/analyzeHeadless` run without errors.\n\n\u003c/details\u003e\n\u003cdetails\u003e\n  \u003csummary style='font-size:12pt'\u003e\u003cb\u003eRequirements:\u003c/b\u003e Python\u003c/summary\u003e\n\n* Python decompilation requires `pip3 install uncompyle6` (see settings)\n  * specify the `uncompyle6` script location in `code → preferences → settings: vscode-decompiler.tool.uncompyle.path` or set to `uncompyle6` if it is available in `PATH`\n\n\u003c/details\u003e\n\n\n\u003cdetails\u003e\n  \u003csummary style='font-size:12pt'\u003e\u003cb\u003eRequirements:\u003c/b\u003e Smart Contracts (EVM byte-code)\u003c/summary\u003e\n\n* The pseudocode generator [panoramix](https://github.com/eveem-org/panoramix)/[eveem](https://www.eveem.org/) requires a working installation of `python3.8` or newer.\n  * specify the `python3.8` path in `code → preferences → settings: vscode-decompiler.tool.python38.path` (e.g. `/usr/local/opt/python@3.8/bin/python3.8` (macos/homebrew))\n  * make sure `pip` for `python3.8` is installed\n  * install `panoramix` dependencies: `$ /usr/local/opt/python@3.8/bin/python3.8 -m pip install coloredlogs requests web3 timeout_decorator ` \n* Note: Panoramix is run in local mode. EVM byte-code is **not** sent to eveem.org.\n  * It will attempt to download a function signature database on first load.\n  * It will cache files to `\u003cuserhome\u003e/.panoramix`.\n* No Windows support :/ ([see this issue](https://github.com/eveem-org/panoramix/issues/19)).\n\n\u003c/details\u003e\n\n\u003cdetails\u003e\n  \u003csummary style='font-size:12pt'\u003eSetting tool preferences\u003c/summary\u003e\n\n`code → preferences → settings:`\n\n* Set default decompiler preference to `ghidra` (default) or `idaPro (experimental Windows Only)` (requires a licensed version of IDAPro + Decompiler)\n    * `vscode-decompiler.default.decompiler.selected`\n* Set preference for java decompilation to JADX or JD-CLI (default)\n    * `vscode-decompiler.java.decompiler.selected`\n* Set preference for android apk decompilation to dex2jar + jd-cli (slow) or JADx (default)\n    * `vscode-decompiler.apk.decompiler.selected\"`\n\n\u003c/details\u003e\n\n\n## Troubleshooting \u0026 FAQ\n\n### (macOs) \"macOs cannot verify the developer of 'decompiler' ...\n\n- Follow the fix outline in https://support.apple.com/en-za/guide/mac-help/mh40616/mac. \n- Verify that you've downloaded ghidra from the original website, verify checksums. **Note:** you're running an NSA tool on your computer, just saying.\n- Open the `\u003cghidra-install-folder\u003e/Ghidra/Features/Decompiler/os/osx64` in finder, \u003ckbd\u003eCtrl\u003c/kbd\u003e+\u003ckbd\u003emouseClick\u003c/kbd\u003e on `decompile` → `open` and **confirm that you trust the application** (you only need to do this one time).\n\n\u003cimg src=\"https://user-images.githubusercontent.com/2865694/103020817-6a1ac300-4549-11eb-89ab-e17d8d34e1da.png\" height=175px\u003e\u003c/img\u003e\n\n### (General) This thing failed with: {\"code\":1,\"type\":\"single\"}. What does this mean?\n\n- Your tool (Ghidra/Ida/...) is not set up correctly and therefore execution failed. The path may be wrong, the tool may fail due ti an incorrect java configuration or the java version is incompatible. There are many ways this error can be provoked and it's in 99% of cases a misconfiguration of the tool or the environment it requires (e.g. java env vars, version, etc)\n- code: is the tools exit code. we are expecting success (0) but a tool may return non-zero to indicate an error. Check the tools output to troubleshoot. code=1 means the tool retunred exitcode 1, indicating an error conditon.\n- type: is how ths tool got executed. single or multi command. ignore this.\n\n### (Ghidra) Failed to run decompiliation command. Check your configuration. {\"code\":1,\"type\":\"single\"}\n\n- make sure you're using a **supported** java version (e.g. win: jdk 14 is working, jdk 16 seems to be incompatible)\n- make sure environment vars are set up correctly ([ghida setup doc](https://ghidra-sre.org/InstallationGuide.html#JavaNotes) [google: setting env vars](https://www.google.com/search?q=how+to+set+permanent+env+var+win+10))\n  - `JAVA_HOME` pointing to your jdk installation folder\n  - `PATH` including an en try pointing to `$JAVA_HOME/bin` (win: `%JAVA_HOME\\bin`)\n- make sure `ghidraRun` and `support/analyzeHeadless` run without errors (you may have to follow the analyzeheadless documentation to provide meaningful parameters for this test)\n- check out the ghidra application log in (windows) `c:\\users\\\u003cyourname\u003e\\.ghidra\\\u003c.ghidraversion\u003e\\application.log`\n\nNote: **always** restart vscode after changing env vars for changes to take effect.\n\n\n## Credits\n\nThis extension wouldn't be possible without the smarties that are developing the following reverse-engineering tools:\n\n* [Ghidra](https://github.com/NationalSecurityAgency/ghidra/) by [@NSA/CSS](https://twitter.com/NSAGov)\n* [JadX](https://github.com/skylot/jadx/) by [@skylot](https://github.com/skylot/)\n* [JD-CLI](https://github.com/kwart/jd-cmd) by [@Josef Cacek](https://github.com/kwart)\n* [dex2Jar](https://github.com/pxb1988/dex2jar) by [@Bob Pan](https://github.com/pxb1988)\n* [IDA Pro Advanced \u0026 Decompiler](https://www.hex-rays.com/products/decompiler/)\n* [python-uncompyle6](https://github.com/rocky/python-uncompyle6/) by [@R. Bernstein](https://github.com/rocky)\n* [panoramix](https://github.com/eveem-org/panoramix) the engine behind [eveem.org](https://www.eveem.org/) created by [@Tomasz Kolinko](https://twitter.com/kolinko)\n* LogoMakr (CC; Logo)\n\n## Release Notes\n\nsee [CHANGELOG](./CHANGELOG.md)\n\n-----------------------------------------------------------------------------------------------------------\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftintinweb%2Fvscode-decompiler","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftintinweb%2Fvscode-decompiler","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftintinweb%2Fvscode-decompiler/lists"}