{"id":13482289,"url":"https://github.com/google/bindiff","last_synced_at":"2025-05-14T02:09:59.713Z","repository":{"id":196474479,"uuid":"694009642","full_name":"google/bindiff","owner":"google","description":"Quickly find differences and similarities in disassembled code","archived":false,"fork":false,"pushed_at":"2025-04-03T12:20:50.000Z","size":324390,"stargazers_count":2512,"open_issues_count":40,"forks_count":162,"subscribers_count":32,"default_branch":"main","last_synced_at":"2025-04-19T22:27:09.999Z","etag":null,"topics":["bindiff","binexport","c-plus-plus","diffing","ida-plugin","ida-pro","java","program-analysis","program-differencing","reverse-engineering","vxsig"],"latest_commit_sha":null,"homepage":"https://zynamics.com/bindiff.html","language":"Java","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/google.png","metadata":{"files":{"readme":"README.md","changelog":"change_classifier.cc","contributing":"CONTRIBUTING.md","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":"2023-09-20T06:41:55.000Z","updated_at":"2025-04-18T12:33:00.000Z","dependencies_parsed_at":null,"dependency_job_id":"21041ab5-7ed9-40d1-a6a3-abe9e9d19326","html_url":"https://github.com/google/bindiff","commit_stats":{"total_commits":806,"total_committers":30,"mean_commits":"26.866666666666667","dds":"0.13151364764267992","last_synced_commit":"c8972f08a3438049f2f5e81439a70ee56f95c549"},"previous_names":["google/bindiff"],"tags_count":2,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/google%2Fbindiff","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/google%2Fbindiff/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/google%2Fbindiff/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/google%2Fbindiff/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/google","download_url":"https://codeload.github.com/google/bindiff/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254053330,"owners_count":22006717,"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":["bindiff","binexport","c-plus-plus","diffing","ida-plugin","ida-pro","java","program-analysis","program-differencing","reverse-engineering","vxsig"],"created_at":"2024-07-31T17:01:00.590Z","updated_at":"2025-05-14T02:09:54.701Z","avatar_url":"https://github.com/google.png","language":"Java","readme":"![BinDiff Logo](docs/images/bindiff-lockup-vertical.png)\n\nCopyright 2011-2024 Google LLC.\n\n# BinDiff\n\nThis repository contains the BinDiff source code. BinDiff is an open-source\ncomparison tool for binary files to quickly find differences and similarities\nin disassembled code.\n\n## Table of Contents\n\n- [About BinDiff](#about-bindiff)\n- [Quickstart](#quickstart)\n- [Documentation](#documentation)\n- [Codemap](#codemap)\n- [Building from Source](#building-from-source)\n- [License](#license)\n- [Getting Involved](#getting-involved)\n\n## About BinDiff\n\nBinDiff is an open-source comparison tool for binary files, that assists\nvulnerability researchers and engineers to quickly find differences and\nsimilarities in disassembled code.\n\nWith BinDiff, researchers can identify and isolate fixes for vulnerabilities in\nvendor-supplied patches. It can also be used to port symbols and comments\nbetween disassemblies of multiple versions of the same binary. This makes\ntracking changes over time easier and allows organizations to retain analysis\nresults and enables knowledge transfer among binary analysts.\n\n### Use Cases\n\n* Compare binary files for x86, MIPS, ARM, PowerPC, and other architectures\n  supported by popular [disassemblers](docs/disassemblers.md).\n* Identify identical and similar functions in different binaries\n* Port function names, comments and local names from one disassembly to the\n  other\n* Detect and highlight changes between two variants of the same function\n\n## Quickstart\n\nIf you want to just get started using BinDiff, download prebuilt installation\npackages from the\n[releases page](https://github.com/google/bindiff/releases).\n\nNote: BinDiff relies on a separate disassembler. Out of the box, it ships with\nsupport for IDA Pro, Binary Ninja and Ghidra. The [disassemblers page](docs/disassemblers.md) lists the supported configurations.\n\n## Documentation\n\nA subset of the existing [manual](https://www.zynamics.com/bindiff/manual) is\navailable in the [`docs/` directory](docs/README.md).\n\n## Codemap\n\nBinDiff contains the following components:\n\n* [`cmake`](cmake) - CMake build files declaring external dependencies\n* [`fixtures`](fixtures) - A collection of test files to exercise the BinDiff\n  core engine\n* [`ida`](ida) - Integration with the IDA Pro disassembler\n* [`java`](java) - Java source code. This contains the the BinDiff visual diff\n  user interface and its corresponding utility library.\n* [`match`](match) - Matching algorithms for the BinDiff core engine\n* [`packaging`](packaging) - Package sources for the installation packages\n* [`tools`](tools) - Helper executables that are shipped with the product\n\n## Building from Source\n\nThe instruction below should be enough to build both the native code and the\nJava based components.\n\nMore detailed build instructions will be added at a later date. This includes\nready-made `Dockerfile`s and scripts for building the installation packages.\n\n### Native code\n\nBinDiff uses CMake to generate its build files for those components that consist\nof native C++ code.\n\nThe following build dependencies are required:\n\n*   [BinExport](https://github.com/google/binexport) 12, the companion plugin\n    to BinDiff that also contains a lot of shared code\n*   Boost 1.83.0 or higher (a partial copy of 1.83.0 ships with BinExport and\n    will be used automatically)\n*   [CMake](https://cmake.org/download/) 3.14 or higher\n*   [Ninja](https://ninja-build.org/) for speedy builds\n*   GCC 9 or a recent version of Clang on Linux/macOS. On Windows, use the\n    Visual Studio 2019 compiler and the Windows SDK for Windows 10.\n*   Git 1.8 or higher\n*   Dependencies that will be downloaded:\n    *   Abseil, GoogleTest, Protocol Buffers (3.14), and SQLite3\n    *   Binary Ninja SDK\n\nThe following build dependencies are optional:\n*   IDA Pro only: IDA SDK 8.2 or higher (unpack into `deps/idasdk`)\n\nThe general build steps are the same on Windows, Linux and macOS. The following\nshows the commands for Linux.\n\nDownload dependencies that won't be downloaded automatically:\n\n```bash\nmkdir -p build/out\ngit clone https://github.com/google/binexport build/binexport\nunzip -q \u003cpath/to/idasdk_pro80.zip\u003e -d build/idasdk\n```\n\nNext, configure the build directory and generate build files:\n\n```bash\ncmake -S . -B build/out -G Ninja \\\n  -DCMAKE_BUILD_TYPE=Release \\\n  -DCMAKE_INSTALL_PREFIX=build/out \\\n  -DBINDIFF_BINEXPORT_DIR=build/binexport \\\n  \"-DIdaSdk_ROOT_DIR=${PWD}build/idasdk\"\n```\n\nFinally, invoke the actual build. Binaries will be placed in\n`build/out/bindiff-prefix`:\n\n```bash\ncmake --build build/out --config Release\n(cd build/out; ctest --build-config Release --output-on-failure)\ncmake --install build/out --config Release\n```\n\n### Building without IDA\n\nTo build without IDA, simply change the above configuration step to\n\n```bash\ncmake -S . -B build/out -G Ninja \\\n  -DCMAKE_BUILD_TYPE=Release \\\n  -DCMAKE_INSTALL_PREFIX=build/out \\\n  -DBINDIFF_BINEXPORT_DIR=build/binexport \\\n  -DBINEXPORT_ENABLE_IDAPRO=OFF\n```\n\n### Java GUI and yFiles\n\nBuilding the Java based GUI requires the commercial third-party graph\nvisualisation library [yFiles](https://www.yworks.com/products/yfiles) for graph\ndisplay and layout. This library is immensely powerful, and not easily\nreplaceable.\n\nTo build, BinDiff uses Gradle 6.x and Java 11 LTS. Refer to its\n[installation guide](https://docs.gradle.org/6.8.3/userguide/installation.html)\nfor instructions on how to install.\n\nAssuming you are a yFiles license holder, set the `YFILES_DIR` environment\nvariable to a directory containing the yFiles `y.jar` and `ysvg.jar`.\n\nNote: BinDiff still uses the older 2.x branch of yFiles.\n\nThen invoke Gradle to download external dependencies and build:\n\nWindows:\n```\nset YFILES_DIR=\u003cpath\\to\\yfiles_2.17\u003e\ncd java\ngradle shadowJar\n```\n\nLinux or macOS:\n\n```\nexport YFILES_DIR=\u003cpath/to/yfiles_2.17\u003e\ncd java\ngradle shadowJar\n```\n\nAfterwards the directory `ui/build/libs` in the `java` sub-directory should\ncontain the self-contained `bindiff-ui-all.jar` artifact, which can be run\nusing the standard `java -jar` command.\n\n## Further reading / Similar tools\n\nThe original papers outlining the general ideas behind BinDiff:\n\n* Thomas Dullien and Rolf Rolles. *Graph-Based Comparison of Executable\n  Objects*. [bindiffsstic05-1.pdf](docs/papers/bindiffsstic05-1.pdf).\n  SSTIC ’05, Symposium sur la Sécurité des Technologies de l’Information et des\n  Communications. 2005.\n* Halvar Flake. *Structural Comparison of Executable Objects*.\n  [dimva_paper2.pdf](docs/papers/dimva_paper2.pdf). pp 161-173. Detection of\n  Intrusions and Malware \u0026 Vulnerability Assessment. 2004.3-88579-375-X.\n\nOther tools in the same problem space:\n\n* [Diaphora](https://github.com/joxeankoret/diaphora), an advanced program\n  diffing tool implementing many of the same ideas.\n* [TurboDiff](https://www.coresecurity.com/core-labs/open-source-tools/turbodiff-cs), a now-defunct program diffing plugin for IDA Pro.\n\nProjects using BinDiff:\n\n* [VxSig](https://github.com/google/vxsig), a tool to automatically generate\n  AV byte signatures from sets of similar binaries.\n\n## License\n\nBinDiff is licensed under the terms of the Apache license. See\n[LICENSE](LICENSE) for more information.\n\n## Getting Involved\n\nIf you want to contribute, please read [CONTRIBUTING.md](CONTRIBUTING.md)\nbefore sending pull requests. You can also report bugs or file feature\nrequests.\n","funding_links":[],"categories":["Java"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgoogle%2Fbindiff","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgoogle%2Fbindiff","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgoogle%2Fbindiff/lists"}